eric7/Documentation/Source/eric7.EricWidgets.EricDirFileDialog.html

branch
eric7
changeset 8403
d9fd02e8c28b
child 8596
d64760b2da50
equal deleted inserted replaced
8399:0a80c37a868a 8403:d9fd02e8c28b
1 <!DOCTYPE html>
2 <html><head>
3 <title>eric7.EricWidgets.EricDirFileDialog</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>
22 <a NAME="top" ID="top"></a>
23 <h1>eric7.EricWidgets.EricDirFileDialog</h1>
24
25 <p>
26 Module implementing a dialog to select files and directories simultaneously.
27 </p>
28 <h3>Global Attributes</h3>
29
30 <table>
31 <tr><td>None</td></tr>
32 </table>
33 <h3>Classes</h3>
34
35 <table>
36
37 <tr>
38 <td><a href="#EricDirFileDialog">EricDirFileDialog</a></td>
39 <td>Derived QFileDialog to select files and directories simultaneously.</td>
40 </tr>
41 </table>
42 <h3>Functions</h3>
43
44 <table>
45 <tr><td>None</td></tr>
46 </table>
47 <hr />
48 <hr />
49 <a NAME="EricDirFileDialog" ID="EricDirFileDialog"></a>
50 <h2>EricDirFileDialog</h2>
51
52 <p>
53 Derived QFileDialog to select files and directories simultaneously.
54 </p>
55 <p>
56 For this purpose the none native file dialog is used.
57 </p>
58 <h3>Derived from</h3>
59 QFileDialog
60 <h3>Class Attributes</h3>
61
62 <table>
63 <tr><td>None</td></tr>
64 </table>
65 <h3>Class Methods</h3>
66
67 <table>
68 <tr><td>None</td></tr>
69 </table>
70 <h3>Methods</h3>
71
72 <table>
73
74 <tr>
75 <td><a href="#EricDirFileDialog.__init__">EricDirFileDialog</a></td>
76 <td>Constructor</td>
77 </tr>
78 <tr>
79 <td><a href="#EricDirFileDialog.accept">accept</a></td>
80 <td>Public slot to update the list with the selected files and folders.</td>
81 </tr>
82 <tr>
83 <td><a href="#EricDirFileDialog.exec">exec</a></td>
84 <td>Public slot to finalize initialization and start the event loop.</td>
85 </tr>
86 <tr>
87 <td><a href="#EricDirFileDialog.on_directoryEntered">on_directoryEntered</a></td>
88 <td>Private slot to reset selections if another directory was entered.</td>
89 </tr>
90 <tr>
91 <td><a href="#EricDirFileDialog.on_selectionChanged">on_selectionChanged</a></td>
92 <td>Private method to determine the selected files and folders and update the line edit.</td>
93 </tr>
94 </table>
95 <h3>Static Methods</h3>
96
97 <table>
98
99 <tr>
100 <td><a href="#EricDirFileDialog.getOpenFileAndDirNames">getOpenFileAndDirNames</a></td>
101 <td>Static method to get the names of files and directories for opening it.</td>
102 </tr>
103 </table>
104
105 <a NAME="EricDirFileDialog.__init__" ID="EricDirFileDialog.__init__"></a>
106 <h4>EricDirFileDialog (Constructor)</h4>
107 <b>EricDirFileDialog</b>(<i>parent=None, caption="", directory="", filterStr=""</i>)
108
109 <p>
110 Constructor
111 </p>
112 <dl>
113
114 <dt><i>parent</i> (QWidget)</dt>
115 <dd>
116 parent widget of the dialog
117 </dd>
118 <dt><i>caption</i> (str)</dt>
119 <dd>
120 window title of the dialog
121 </dd>
122 <dt><i>directory</i> (str)</dt>
123 <dd>
124 working directory of the dialog
125 </dd>
126 <dt><i>filterStr</i> (str)</dt>
127 <dd>
128 filter string for the dialog
129 </dd>
130 </dl>
131 <a NAME="EricDirFileDialog.accept" ID="EricDirFileDialog.accept"></a>
132 <h4>EricDirFileDialog.accept</h4>
133 <b>accept</b>(<i></i>)
134
135 <p>
136 Public slot to update the list with the selected files and folders.
137 </p>
138 <a NAME="EricDirFileDialog.exec" ID="EricDirFileDialog.exec"></a>
139 <h4>EricDirFileDialog.exec</h4>
140 <b>exec</b>(<i></i>)
141
142 <p>
143 Public slot to finalize initialization and start the event loop.
144 </p>
145 <dl>
146 <dt>Return:</dt>
147 <dd>
148 accepted or rejected
149 </dd>
150 </dl>
151 <dl>
152 <dt>Return Type:</dt>
153 <dd>
154 QDialog.DialogCode
155 </dd>
156 </dl>
157 <a NAME="EricDirFileDialog.on_directoryEntered" ID="EricDirFileDialog.on_directoryEntered"></a>
158 <h4>EricDirFileDialog.on_directoryEntered</h4>
159 <b>on_directoryEntered</b>(<i>directory</i>)
160
161 <p>
162 Private slot to reset selections if another directory was entered.
163 </p>
164 <dl>
165
166 <dt><i>directory</i> (str)</dt>
167 <dd>
168 name of the directory entered
169 </dd>
170 </dl>
171 <a NAME="EricDirFileDialog.on_selectionChanged" ID="EricDirFileDialog.on_selectionChanged"></a>
172 <h4>EricDirFileDialog.on_selectionChanged</h4>
173 <b>on_selectionChanged</b>(<i>selected, deselected</i>)
174
175 <p>
176 Private method to determine the selected files and folders and update
177 the line edit.
178 </p>
179 <dl>
180
181 <dt><i>selected</i> (QItemSelection)</dt>
182 <dd>
183 newly selected entries
184 </dd>
185 <dt><i>deselected</i> (QItemSelection)</dt>
186 <dd>
187 deselected entries
188 </dd>
189 </dl>
190 <a NAME="EricDirFileDialog.getOpenFileAndDirNames" ID="EricDirFileDialog.getOpenFileAndDirNames"></a>
191 <h4>EricDirFileDialog.getOpenFileAndDirNames (static)</h4>
192 <b>getOpenFileAndDirNames</b>(<i>caption="", directory="", filterStr="", options=None</i>)
193
194 <p>
195 Static method to get the names of files and directories for opening it.
196 </p>
197 <dl>
198
199 <dt><i>parent</i> (QWidget)</dt>
200 <dd>
201 parent widget of the dialog
202 </dd>
203 <dt><i>caption</i> (str)</dt>
204 <dd>
205 window title of the dialog
206 </dd>
207 <dt><i>directory</i> (str)</dt>
208 <dd>
209 working directory of the dialog
210 </dd>
211 <dt><i>filterStr</i> (str)</dt>
212 <dd>
213 filter string for the dialog
214 </dd>
215 <dt><i>options</i> (QFileDialog.Options)</dt>
216 <dd>
217 various options for the dialog
218 </dd>
219 </dl>
220 <dl>
221 <dt>Return:</dt>
222 <dd>
223 names of the selected files and folders
224 </dd>
225 </dl>
226 <dl>
227 <dt>Return Type:</dt>
228 <dd>
229 list of str
230 </dd>
231 </dl>
232 <div align="right"><a href="#top">Up</a></div>
233 <hr />
234 </body></html>

eric ide

mercurial