|
1 <!DOCTYPE html> |
|
2 <html><head> |
|
3 <title>eric7.EricWidgets.EricListSelectionDialog</title> |
|
4 <meta charset="UTF-8"> |
|
5 <link rel="stylesheet" href="styles.css"> |
|
6 </head> |
|
7 <body> |
|
8 <a NAME="top" ID="top"></a> |
|
9 <h1>eric7.EricWidgets.EricListSelectionDialog</h1> |
|
10 |
|
11 <p> |
|
12 Module implementing a dialog to select from a list of strings. |
|
13 </p> |
|
14 <h3>Global Attributes</h3> |
|
15 |
|
16 <table> |
|
17 <tr><td>None</td></tr> |
|
18 </table> |
|
19 <h3>Classes</h3> |
|
20 |
|
21 <table> |
|
22 |
|
23 <tr> |
|
24 <td><a href="#EricListSelectionDialog">EricListSelectionDialog</a></td> |
|
25 <td>Class implementing a dialog to select from a list of strings.</td> |
|
26 </tr> |
|
27 </table> |
|
28 <h3>Functions</h3> |
|
29 |
|
30 <table> |
|
31 <tr><td>None</td></tr> |
|
32 </table> |
|
33 <hr /> |
|
34 <hr /> |
|
35 <a NAME="EricListSelectionDialog" ID="EricListSelectionDialog"></a> |
|
36 <h2>EricListSelectionDialog</h2> |
|
37 |
|
38 <p> |
|
39 Class implementing a dialog to select from a list of strings. |
|
40 </p> |
|
41 <h3>Derived from</h3> |
|
42 QDialog, Ui_EricListSelectionDialog |
|
43 <h3>Class Attributes</h3> |
|
44 |
|
45 <table> |
|
46 <tr><td>None</td></tr> |
|
47 </table> |
|
48 <h3>Class Methods</h3> |
|
49 |
|
50 <table> |
|
51 <tr><td>None</td></tr> |
|
52 </table> |
|
53 <h3>Methods</h3> |
|
54 |
|
55 <table> |
|
56 |
|
57 <tr> |
|
58 <td><a href="#EricListSelectionDialog.__init__">EricListSelectionDialog</a></td> |
|
59 <td>Constructor</td> |
|
60 </tr> |
|
61 <tr> |
|
62 <td><a href="#EricListSelectionDialog.getSelection">getSelection</a></td> |
|
63 <td>Public method to retrieve the selected items.</td> |
|
64 </tr> |
|
65 <tr> |
|
66 <td><a href="#EricListSelectionDialog.on_selectionList_itemChanged">on_selectionList_itemChanged</a></td> |
|
67 <td>Private slot handling a change of an item.</td> |
|
68 </tr> |
|
69 <tr> |
|
70 <td><a href="#EricListSelectionDialog.on_selectionList_itemDoubleClicked">on_selectionList_itemDoubleClicked</a></td> |
|
71 <td>Private slot handling double clicking an item.</td> |
|
72 </tr> |
|
73 <tr> |
|
74 <td><a href="#EricListSelectionDialog.on_selectionList_itemSelectionChanged">on_selectionList_itemSelectionChanged</a></td> |
|
75 <td>Private slot handling a change of the selection.</td> |
|
76 </tr> |
|
77 </table> |
|
78 <h3>Static Methods</h3> |
|
79 |
|
80 <table> |
|
81 <tr><td>None</td></tr> |
|
82 </table> |
|
83 |
|
84 <a NAME="EricListSelectionDialog.__init__" ID="EricListSelectionDialog.__init__"></a> |
|
85 <h4>EricListSelectionDialog (Constructor)</h4> |
|
86 <b>EricListSelectionDialog</b>(<i>entries, selectionMode=QAbstractItemView.SelectionMode |
|
87 .ExtendedSelection, title="", message="", checkBoxSelection=False, doubleClickOk=False, parent=None</i>) |
|
88 |
|
89 <p> |
|
90 Constructor |
|
91 </p> |
|
92 <dl> |
|
93 |
|
94 <dt><i>entries</i> (list of str)</dt> |
|
95 <dd> |
|
96 list of entries to select from |
|
97 </dd> |
|
98 <dt><i>selectionMode</i> (QAbstractItemView.SelectionMode)</dt> |
|
99 <dd> |
|
100 selection mode for the list |
|
101 </dd> |
|
102 <dt><i>title</i> (str)</dt> |
|
103 <dd> |
|
104 title of the dialog |
|
105 </dd> |
|
106 <dt><i>message</i> (str)</dt> |
|
107 <dd> |
|
108 message to be show in the dialog |
|
109 </dd> |
|
110 <dt><i>checkBoxSelection</i> (bool)</dt> |
|
111 <dd> |
|
112 flag indicating to select items via their |
|
113 checkbox |
|
114 </dd> |
|
115 <dt><i>doubleClickOk</i> (bool)</dt> |
|
116 <dd> |
|
117 flag indicating to accept the dialog upon a |
|
118 double click of an item (single selection only) |
|
119 </dd> |
|
120 <dt><i>parent</i> (QWidget)</dt> |
|
121 <dd> |
|
122 reference to the parent widget |
|
123 </dd> |
|
124 </dl> |
|
125 <a NAME="EricListSelectionDialog.getSelection" ID="EricListSelectionDialog.getSelection"></a> |
|
126 <h4>EricListSelectionDialog.getSelection</h4> |
|
127 <b>getSelection</b>(<i></i>) |
|
128 |
|
129 <p> |
|
130 Public method to retrieve the selected items. |
|
131 </p> |
|
132 <dl> |
|
133 <dt>Return:</dt> |
|
134 <dd> |
|
135 selected entries |
|
136 </dd> |
|
137 </dl> |
|
138 <dl> |
|
139 <dt>Return Type:</dt> |
|
140 <dd> |
|
141 list of str |
|
142 </dd> |
|
143 </dl> |
|
144 <a NAME="EricListSelectionDialog.on_selectionList_itemChanged" ID="EricListSelectionDialog.on_selectionList_itemChanged"></a> |
|
145 <h4>EricListSelectionDialog.on_selectionList_itemChanged</h4> |
|
146 <b>on_selectionList_itemChanged</b>(<i>itm</i>) |
|
147 |
|
148 <p> |
|
149 Private slot handling a change of an item. |
|
150 </p> |
|
151 <dl> |
|
152 |
|
153 <dt><i>itm</i> (QListWidgetItem)</dt> |
|
154 <dd> |
|
155 reference to the changed item |
|
156 </dd> |
|
157 </dl> |
|
158 <a NAME="EricListSelectionDialog.on_selectionList_itemDoubleClicked" ID="EricListSelectionDialog.on_selectionList_itemDoubleClicked"></a> |
|
159 <h4>EricListSelectionDialog.on_selectionList_itemDoubleClicked</h4> |
|
160 <b>on_selectionList_itemDoubleClicked</b>(<i>item</i>) |
|
161 |
|
162 <p> |
|
163 Private slot handling double clicking an item. |
|
164 </p> |
|
165 <dl> |
|
166 |
|
167 <dt><i>item</i> (QListWidgetItem)</dt> |
|
168 <dd> |
|
169 double clicked item |
|
170 </dd> |
|
171 </dl> |
|
172 <a NAME="EricListSelectionDialog.on_selectionList_itemSelectionChanged" ID="EricListSelectionDialog.on_selectionList_itemSelectionChanged"></a> |
|
173 <h4>EricListSelectionDialog.on_selectionList_itemSelectionChanged</h4> |
|
174 <b>on_selectionList_itemSelectionChanged</b>(<i></i>) |
|
175 |
|
176 <p> |
|
177 Private slot handling a change of the selection. |
|
178 </p> |
|
179 <div align="right"><a href="#top">Up</a></div> |
|
180 <hr /> |
|
181 </body></html> |