|
1 <!DOCTYPE html> |
|
2 <html><head> |
|
3 <title>eric6.E5Gui.E5TextInputDialog</title> |
|
4 <meta charset="UTF-8"> |
|
5 <style> |
|
6 body { |
|
7 background: #EDECE6; |
|
8 margin: 0em 1em 10em 1em; |
|
9 color: black; |
|
10 } |
|
11 |
|
12 h1 { color: white; background: #85774A; } |
|
13 h2 { color: white; background: #85774A; } |
|
14 h3 { color: white; background: #9D936E; } |
|
15 h4 { color: white; background: #9D936E; } |
|
16 |
|
17 a { color: #BA6D36; } |
|
18 |
|
19 </style> |
|
20 </head> |
|
21 <body><a NAME="top" ID="top"></a> |
|
22 <h1>eric6.E5Gui.E5TextInputDialog</h1> |
|
23 <p> |
|
24 Module implementing a dialog to enter some text. |
|
25 </p> |
|
26 <h3>Global Attributes</h3> |
|
27 <table> |
|
28 <tr><td>None</td></tr> |
|
29 </table> |
|
30 <h3>Classes</h3> |
|
31 <table> |
|
32 <tr> |
|
33 <td><a href="#E5TextInputDialog">E5TextInputDialog</a></td> |
|
34 <td>Class implementing a dialog to enter some text.</td> |
|
35 </tr> |
|
36 </table> |
|
37 <h3>Functions</h3> |
|
38 <table> |
|
39 <tr> |
|
40 <td><a href="#getText">getText</a></td> |
|
41 <td>Function to get create a dialog to enter some text and return it.</td> |
|
42 </tr> |
|
43 </table> |
|
44 <hr /><hr /> |
|
45 <a NAME="E5TextInputDialog" ID="E5TextInputDialog"></a> |
|
46 <h2>E5TextInputDialog</h2> |
|
47 <p> |
|
48 Class implementing a dialog to enter some text. |
|
49 </p> |
|
50 <h3>Derived from</h3> |
|
51 QDialog |
|
52 <h3>Class Attributes</h3> |
|
53 <table> |
|
54 <tr><td>None</td></tr> |
|
55 </table> |
|
56 <h3>Class Methods</h3> |
|
57 <table> |
|
58 <tr><td>None</td></tr> |
|
59 </table> |
|
60 <h3>Methods</h3> |
|
61 <table> |
|
62 <tr> |
|
63 <td><a href="#E5TextInputDialog.__init__">E5TextInputDialog</a></td> |
|
64 <td>Constructor</td> |
|
65 </tr><tr> |
|
66 <td><a href="#E5TextInputDialog.labelText">labelText</a></td> |
|
67 <td>Public method to get the current label text.</td> |
|
68 </tr><tr> |
|
69 <td><a href="#E5TextInputDialog.setLabelText">setLabelText</a></td> |
|
70 <td>Public method to set the label text.</td> |
|
71 </tr><tr> |
|
72 <td><a href="#E5TextInputDialog.setTextEchoMode">setTextEchoMode</a></td> |
|
73 <td>Public method to set the echo mode of the line edit.</td> |
|
74 </tr><tr> |
|
75 <td><a href="#E5TextInputDialog.setTextValue">setTextValue</a></td> |
|
76 <td>Public method to set the text of the line edit.</td> |
|
77 </tr><tr> |
|
78 <td><a href="#E5TextInputDialog.textEchoMode">textEchoMode</a></td> |
|
79 <td>Public method to get the current echo mode of the line edit.</td> |
|
80 </tr><tr> |
|
81 <td><a href="#E5TextInputDialog.textValue">textValue</a></td> |
|
82 <td>Public method to get the text of the line edit.</td> |
|
83 </tr> |
|
84 </table> |
|
85 <h3>Static Methods</h3> |
|
86 <table> |
|
87 <tr><td>None</td></tr> |
|
88 </table> |
|
89 <a NAME="E5TextInputDialog.__init__" ID="E5TextInputDialog.__init__"></a> |
|
90 <h4>E5TextInputDialog (Constructor)</h4> |
|
91 <b>E5TextInputDialog</b>(<i>parent=None</i>) |
|
92 <p> |
|
93 Constructor |
|
94 </p><dl> |
|
95 <dt><i>parent</i> (QWidget)</dt> |
|
96 <dd> |
|
97 reference to the parent widget |
|
98 </dd> |
|
99 </dl><a NAME="E5TextInputDialog.labelText" ID="E5TextInputDialog.labelText"></a> |
|
100 <h4>E5TextInputDialog.labelText</h4> |
|
101 <b>labelText</b>(<i></i>) |
|
102 <p> |
|
103 Public method to get the current label text. |
|
104 </p><dl> |
|
105 <dt>Returns:</dt> |
|
106 <dd> |
|
107 current label text |
|
108 </dd> |
|
109 </dl><dl> |
|
110 <dt>Return Type:</dt> |
|
111 <dd> |
|
112 str |
|
113 </dd> |
|
114 </dl><a NAME="E5TextInputDialog.setLabelText" ID="E5TextInputDialog.setLabelText"></a> |
|
115 <h4>E5TextInputDialog.setLabelText</h4> |
|
116 <b>setLabelText</b>(<i>text</i>) |
|
117 <p> |
|
118 Public method to set the label text. |
|
119 </p><dl> |
|
120 <dt><i>text</i> (str)</dt> |
|
121 <dd> |
|
122 label text |
|
123 </dd> |
|
124 </dl><a NAME="E5TextInputDialog.setTextEchoMode" ID="E5TextInputDialog.setTextEchoMode"></a> |
|
125 <h4>E5TextInputDialog.setTextEchoMode</h4> |
|
126 <b>setTextEchoMode</b>(<i>echoMode</i>) |
|
127 <p> |
|
128 Public method to set the echo mode of the line edit. |
|
129 </p><dl> |
|
130 <dt><i>echoMode</i> (QLineEdit.EchoMode)</dt> |
|
131 <dd> |
|
132 echo mode of the line edit |
|
133 </dd> |
|
134 </dl><a NAME="E5TextInputDialog.setTextValue" ID="E5TextInputDialog.setTextValue"></a> |
|
135 <h4>E5TextInputDialog.setTextValue</h4> |
|
136 <b>setTextValue</b>(<i>text</i>) |
|
137 <p> |
|
138 Public method to set the text of the line edit. |
|
139 </p><dl> |
|
140 <dt><i>text</i> (str)</dt> |
|
141 <dd> |
|
142 text for the line edit |
|
143 </dd> |
|
144 </dl><a NAME="E5TextInputDialog.textEchoMode" ID="E5TextInputDialog.textEchoMode"></a> |
|
145 <h4>E5TextInputDialog.textEchoMode</h4> |
|
146 <b>textEchoMode</b>(<i></i>) |
|
147 <p> |
|
148 Public method to get the current echo mode of the line edit. |
|
149 </p><dl> |
|
150 <dt>Returns:</dt> |
|
151 <dd> |
|
152 echo mode of the line edit |
|
153 </dd> |
|
154 </dl><dl> |
|
155 <dt>Return Type:</dt> |
|
156 <dd> |
|
157 QLineEdit.EchoMode |
|
158 </dd> |
|
159 </dl><a NAME="E5TextInputDialog.textValue" ID="E5TextInputDialog.textValue"></a> |
|
160 <h4>E5TextInputDialog.textValue</h4> |
|
161 <b>textValue</b>(<i></i>) |
|
162 <p> |
|
163 Public method to get the text of the line edit. |
|
164 </p><dl> |
|
165 <dt>Returns:</dt> |
|
166 <dd> |
|
167 text of the line edit |
|
168 </dd> |
|
169 </dl><dl> |
|
170 <dt>Return Type:</dt> |
|
171 <dd> |
|
172 str |
|
173 </dd> |
|
174 </dl> |
|
175 <div align="right"><a href="#top">Up</a></div> |
|
176 <hr /><hr /> |
|
177 <a NAME="getText" ID="getText"></a> |
|
178 <h2>getText</h2> |
|
179 <b>getText</b>(<i>parent, title, label, mode=QLineEdit.Normal, text="", minimumWidth=300</i>) |
|
180 <p> |
|
181 Function to get create a dialog to enter some text and return it. |
|
182 </p><dl> |
|
183 <dt><i>parent</i> (QWidget)</dt> |
|
184 <dd> |
|
185 reference to the parent widget |
|
186 </dd><dt><i>title</i> (str)</dt> |
|
187 <dd> |
|
188 title of the dialog |
|
189 </dd><dt><i>label</i> (str)</dt> |
|
190 <dd> |
|
191 label of the dialog |
|
192 </dd><dt><i>mode</i> (QLineEdit.EchoMode)</dt> |
|
193 <dd> |
|
194 echo mode of the line edit |
|
195 </dd><dt><i>text</i> (str)</dt> |
|
196 <dd> |
|
197 initial text of the line edit |
|
198 </dd><dt><i>minimumWidth</i> (int)</dt> |
|
199 <dd> |
|
200 minimum width of the dialog |
|
201 </dd> |
|
202 </dl><dl> |
|
203 <dt>Returns:</dt> |
|
204 <dd> |
|
205 tuple containing a flag indicating the dialog was accepted and the |
|
206 entered text |
|
207 </dd> |
|
208 </dl><dl> |
|
209 <dt>Return Type:</dt> |
|
210 <dd> |
|
211 tuple of (bool, str) |
|
212 </dd> |
|
213 </dl> |
|
214 <div align="right"><a href="#top">Up</a></div> |
|
215 <hr /> |
|
216 </body></html> |