ProjectDjangoTagsMenu/MultiLineInputDialog.py

branch
eric7
changeset 63
85418cf03fdb
parent 60
85d3931419d3
child 69
9acb6987ce60
equal deleted inserted replaced
62:dba433b4f3d6 63:85418cf03fdb
14 14
15 class MultiLineInputDialog(QDialog, Ui_MultiLineInputDialog): 15 class MultiLineInputDialog(QDialog, Ui_MultiLineInputDialog):
16 """ 16 """
17 Class implementing a dialog for the input of multi line text. 17 Class implementing a dialog for the input of multi line text.
18 """ 18 """
19
19 def __init__(self, label, default, parent=None): 20 def __init__(self, label, default, parent=None):
20 """ 21 """
21 Constructor 22 Constructor
22 23
23 @param label label for the entry field 24 @param label label for the entry field
24 @type str 25 @type str
25 @param default default value for the entry field 26 @param default default value for the entry field
26 @type str 27 @type str
27 @param parent reference to the parent widget 28 @param parent reference to the parent widget
28 @type QWidget 29 @type QWidget
29 """ 30 """
30 super().__init__(parent) 31 super().__init__(parent)
31 self.setupUi(self) 32 self.setupUi(self)
32 33
33 def getData(self): 34 def getData(self):
34 """ 35 """
35 Public method to retrieve the multi line text. 36 Public method to retrieve the multi line text.
36 37
37 @return multi line text 38 @return multi line text
38 @rtype str 39 @rtype str
39 """ 40 """
40 return self.multiLineEdit.toPlainText() 41 return self.multiLineEdit.toPlainText()
41 42
42 @staticmethod 43 @staticmethod
43 def getText(parent, title, label, default=""): 44 def getText(parent, title, label, default=""):
44 """ 45 """
45 Public static method to create the dialog and return the multi line 46 Public static method to create the dialog and return the multi line
46 text. 47 text.
47 48
48 @param parent reference to the parent widget 49 @param parent reference to the parent widget
49 @type QWidget 50 @type QWidget
50 @param title title of the dialog 51 @param title title of the dialog
51 @type str 52 @type str
52 @param label label for the entry field 53 @param label label for the entry field

eric ide

mercurial