|
1 <?xml version="1.0" encoding="utf-8"?> |
|
2 <!DOCTYPE html PUBLIC '-//W3C//DTD XHTML 1.0 Strict//EN' |
|
3 'http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd'> |
|
4 <html><head> |
|
5 <title>eric5.Helpviewer.Bookmarks.AddBookmarkDialog</title> |
|
6 <style> |
|
7 b'body {\n background:white;\n margin: 0em 1em 10em 1em;\n color: black;\n}\n\nh1 { color: white; background: #4FA4FF; }\nh2 { color: white; background: #4FA4FF; }\nh3 { color: white; background: #00557F; }\nh4 { color: white; background: #00557F; }\n \na { color: #AA5500; }\n' |
|
8 </style> |
|
9 </head> |
|
10 <body><a NAME="top" ID="top"></a> |
|
11 <h1>eric5.Helpviewer.Bookmarks.AddBookmarkDialog</h1> |
|
12 <p> |
|
13 Module implementing a dialog to add a bookmark or a bookmark folder. |
|
14 </p> |
|
15 <h3>Global Attributes</h3> |
|
16 <table> |
|
17 <tr><td>None</td></tr> |
|
18 </table> |
|
19 <h3>Classes</h3> |
|
20 <table> |
|
21 <tr> |
|
22 <td><a href="#AddBookmarkDialog">AddBookmarkDialog</a></td> |
|
23 <td>Class implementing a dialog to add a bookmark or a bookmark folder.</td> |
|
24 </tr><tr> |
|
25 <td><a href="#AddBookmarkProxyModel">AddBookmarkProxyModel</a></td> |
|
26 <td>Class implementing a proxy model used by the AddBookmarkDialog dialog.</td> |
|
27 </tr> |
|
28 </table> |
|
29 <h3>Functions</h3> |
|
30 <table> |
|
31 <tr><td>None</td></tr> |
|
32 </table> |
|
33 <hr /><hr /> |
|
34 <a NAME="AddBookmarkDialog" ID="AddBookmarkDialog"></a> |
|
35 <h2>AddBookmarkDialog</h2> |
|
36 <p> |
|
37 Class implementing a dialog to add a bookmark or a bookmark folder. |
|
38 </p> |
|
39 <h3>Derived from</h3> |
|
40 QDialog, Ui_AddBookmarkDialog |
|
41 <h3>Class Attributes</h3> |
|
42 <table> |
|
43 <tr><td>None</td></tr> |
|
44 </table> |
|
45 <h3>Methods</h3> |
|
46 <table> |
|
47 <tr> |
|
48 <td><a href="#AddBookmarkDialog.__init__">AddBookmarkDialog</a></td> |
|
49 <td>Constructor</td> |
|
50 </tr><tr> |
|
51 <td><a href="#AddBookmarkDialog.accept">accept</a></td> |
|
52 <td>Public slot handling the acceptance of the dialog.</td> |
|
53 </tr><tr> |
|
54 <td><a href="#AddBookmarkDialog.addedNode">addedNode</a></td> |
|
55 <td>Public method to get a reference to the added bookmark node.</td> |
|
56 </tr><tr> |
|
57 <td><a href="#AddBookmarkDialog.currentIndex">currentIndex</a></td> |
|
58 <td>Public method to get the current index.</td> |
|
59 </tr><tr> |
|
60 <td><a href="#AddBookmarkDialog.isFolder">isFolder</a></td> |
|
61 <td>Public method to test, if the dialog is in "Add Folder" mode.</td> |
|
62 </tr><tr> |
|
63 <td><a href="#AddBookmarkDialog.setCurrentIndex">setCurrentIndex</a></td> |
|
64 <td>Public method to set the current index.</td> |
|
65 </tr><tr> |
|
66 <td><a href="#AddBookmarkDialog.setFolder">setFolder</a></td> |
|
67 <td>Public method to set the dialog to "Add Folder" mode.</td> |
|
68 </tr><tr> |
|
69 <td><a href="#AddBookmarkDialog.setTitle">setTitle</a></td> |
|
70 <td>Public method to set the title of the new bookmark.</td> |
|
71 </tr><tr> |
|
72 <td><a href="#AddBookmarkDialog.setUrl">setUrl</a></td> |
|
73 <td>Public slot to set the URL of the new bookmark.</td> |
|
74 </tr><tr> |
|
75 <td><a href="#AddBookmarkDialog.title">title</a></td> |
|
76 <td>Public method to get the title of the bookmark.</td> |
|
77 </tr><tr> |
|
78 <td><a href="#AddBookmarkDialog.url">url</a></td> |
|
79 <td>Public method to get the URL of the bookmark.</td> |
|
80 </tr> |
|
81 </table> |
|
82 <a NAME="AddBookmarkDialog.__init__" ID="AddBookmarkDialog.__init__"></a> |
|
83 <h4>AddBookmarkDialog (Constructor)</h4> |
|
84 <b>AddBookmarkDialog</b>(<i>parent = None, bookmarksManager = None</i>) |
|
85 <p> |
|
86 Constructor |
|
87 </p><dl> |
|
88 <dt><i>parent</i></dt> |
|
89 <dd> |
|
90 reference to the parent widget (QWidget) |
|
91 </dd><dt><i>bookmarksManager</i></dt> |
|
92 <dd> |
|
93 reference to the bookmarks manager |
|
94 object (BookmarksManager) |
|
95 </dd> |
|
96 </dl><a NAME="AddBookmarkDialog.accept" ID="AddBookmarkDialog.accept"></a> |
|
97 <h4>AddBookmarkDialog.accept</h4> |
|
98 <b>accept</b>(<i></i>) |
|
99 <p> |
|
100 Public slot handling the acceptance of the dialog. |
|
101 </p><a NAME="AddBookmarkDialog.addedNode" ID="AddBookmarkDialog.addedNode"></a> |
|
102 <h4>AddBookmarkDialog.addedNode</h4> |
|
103 <b>addedNode</b>(<i></i>) |
|
104 <p> |
|
105 Public method to get a reference to the added bookmark node. |
|
106 </p><dl> |
|
107 <dt>Returns:</dt> |
|
108 <dd> |
|
109 reference to the added bookmark node (BookmarkNode) |
|
110 </dd> |
|
111 </dl><a NAME="AddBookmarkDialog.currentIndex" ID="AddBookmarkDialog.currentIndex"></a> |
|
112 <h4>AddBookmarkDialog.currentIndex</h4> |
|
113 <b>currentIndex</b>(<i></i>) |
|
114 <p> |
|
115 Public method to get the current index. |
|
116 </p><dl> |
|
117 <dt>Returns:</dt> |
|
118 <dd> |
|
119 current index (QModelIndex) |
|
120 </dd> |
|
121 </dl><a NAME="AddBookmarkDialog.isFolder" ID="AddBookmarkDialog.isFolder"></a> |
|
122 <h4>AddBookmarkDialog.isFolder</h4> |
|
123 <b>isFolder</b>(<i></i>) |
|
124 <p> |
|
125 Public method to test, if the dialog is in "Add Folder" mode. |
|
126 </p><dl> |
|
127 <dt>Returns:</dt> |
|
128 <dd> |
|
129 flag indicating "Add Folder" mode (boolean) |
|
130 </dd> |
|
131 </dl><a NAME="AddBookmarkDialog.setCurrentIndex" ID="AddBookmarkDialog.setCurrentIndex"></a> |
|
132 <h4>AddBookmarkDialog.setCurrentIndex</h4> |
|
133 <b>setCurrentIndex</b>(<i>idx</i>) |
|
134 <p> |
|
135 Public method to set the current index. |
|
136 </p><dl> |
|
137 <dt><i>idx</i></dt> |
|
138 <dd> |
|
139 current index to be set (QModelIndex) |
|
140 </dd> |
|
141 </dl><a NAME="AddBookmarkDialog.setFolder" ID="AddBookmarkDialog.setFolder"></a> |
|
142 <h4>AddBookmarkDialog.setFolder</h4> |
|
143 <b>setFolder</b>(<i>folder</i>) |
|
144 <p> |
|
145 Public method to set the dialog to "Add Folder" mode. |
|
146 </p><dl> |
|
147 <dt><i>folder</i></dt> |
|
148 <dd> |
|
149 flag indicating "Add Folder" mode (boolean) |
|
150 </dd> |
|
151 </dl><a NAME="AddBookmarkDialog.setTitle" ID="AddBookmarkDialog.setTitle"></a> |
|
152 <h4>AddBookmarkDialog.setTitle</h4> |
|
153 <b>setTitle</b>(<i>title</i>) |
|
154 <p> |
|
155 Public method to set the title of the new bookmark. |
|
156 </p><dl> |
|
157 <dt><i>title</i></dt> |
|
158 <dd> |
|
159 title of the bookmark (string) |
|
160 </dd> |
|
161 </dl><a NAME="AddBookmarkDialog.setUrl" ID="AddBookmarkDialog.setUrl"></a> |
|
162 <h4>AddBookmarkDialog.setUrl</h4> |
|
163 <b>setUrl</b>(<i>url</i>) |
|
164 <p> |
|
165 Public slot to set the URL of the new bookmark. |
|
166 </p><dl> |
|
167 <dt><i>url</i></dt> |
|
168 <dd> |
|
169 URL of the bookmark (string) |
|
170 </dd> |
|
171 </dl><a NAME="AddBookmarkDialog.title" ID="AddBookmarkDialog.title"></a> |
|
172 <h4>AddBookmarkDialog.title</h4> |
|
173 <b>title</b>(<i></i>) |
|
174 <p> |
|
175 Public method to get the title of the bookmark. |
|
176 </p><dl> |
|
177 <dt>Returns:</dt> |
|
178 <dd> |
|
179 title of the bookmark (string) |
|
180 </dd> |
|
181 </dl><a NAME="AddBookmarkDialog.url" ID="AddBookmarkDialog.url"></a> |
|
182 <h4>AddBookmarkDialog.url</h4> |
|
183 <b>url</b>(<i></i>) |
|
184 <p> |
|
185 Public method to get the URL of the bookmark. |
|
186 </p><dl> |
|
187 <dt>Returns:</dt> |
|
188 <dd> |
|
189 URL of the bookmark (string) |
|
190 </dd> |
|
191 </dl> |
|
192 <div align="right"><a href="#top">Up</a></div> |
|
193 <hr /><hr /> |
|
194 <a NAME="AddBookmarkProxyModel" ID="AddBookmarkProxyModel"></a> |
|
195 <h2>AddBookmarkProxyModel</h2> |
|
196 <p> |
|
197 Class implementing a proxy model used by the AddBookmarkDialog dialog. |
|
198 </p> |
|
199 <h3>Derived from</h3> |
|
200 QSortFilterProxyModel |
|
201 <h3>Class Attributes</h3> |
|
202 <table> |
|
203 <tr><td>None</td></tr> |
|
204 </table> |
|
205 <h3>Methods</h3> |
|
206 <table> |
|
207 <tr> |
|
208 <td><a href="#AddBookmarkProxyModel.__init__">AddBookmarkProxyModel</a></td> |
|
209 <td>Constructor</td> |
|
210 </tr><tr> |
|
211 <td><a href="#AddBookmarkProxyModel.columnCount">columnCount</a></td> |
|
212 <td>Public method to return the number of columns.</td> |
|
213 </tr><tr> |
|
214 <td><a href="#AddBookmarkProxyModel.filterAcceptsColumn">filterAcceptsColumn</a></td> |
|
215 <td>Protected method to determine, if the column is acceptable.</td> |
|
216 </tr><tr> |
|
217 <td><a href="#AddBookmarkProxyModel.filterAcceptsRow">filterAcceptsRow</a></td> |
|
218 <td>Protected method to determine, if the row is acceptable.</td> |
|
219 </tr><tr> |
|
220 <td><a href="#AddBookmarkProxyModel.hasChildren">hasChildren</a></td> |
|
221 <td>Public method to check, if a parent node has some children.</td> |
|
222 </tr> |
|
223 </table> |
|
224 <a NAME="AddBookmarkProxyModel.__init__" ID="AddBookmarkProxyModel.__init__"></a> |
|
225 <h4>AddBookmarkProxyModel (Constructor)</h4> |
|
226 <b>AddBookmarkProxyModel</b>(<i>parent = None</i>) |
|
227 <p> |
|
228 Constructor |
|
229 </p><dl> |
|
230 <dt><i>parent</i></dt> |
|
231 <dd> |
|
232 reference to the parent object (QObject) |
|
233 </dd> |
|
234 </dl><a NAME="AddBookmarkProxyModel.columnCount" ID="AddBookmarkProxyModel.columnCount"></a> |
|
235 <h4>AddBookmarkProxyModel.columnCount</h4> |
|
236 <b>columnCount</b>(<i>parent</i>) |
|
237 <p> |
|
238 Public method to return the number of columns. |
|
239 </p><dl> |
|
240 <dt><i>parent</i></dt> |
|
241 <dd> |
|
242 index of the parent (QModelIndex) |
|
243 </dd> |
|
244 </dl><dl> |
|
245 <dt>Returns:</dt> |
|
246 <dd> |
|
247 number of columns (integer) |
|
248 </dd> |
|
249 </dl><a NAME="AddBookmarkProxyModel.filterAcceptsColumn" ID="AddBookmarkProxyModel.filterAcceptsColumn"></a> |
|
250 <h4>AddBookmarkProxyModel.filterAcceptsColumn</h4> |
|
251 <b>filterAcceptsColumn</b>(<i>sourceColumn, sourceParent</i>) |
|
252 <p> |
|
253 Protected method to determine, if the column is acceptable. |
|
254 </p><dl> |
|
255 <dt><i>sourceColumn</i></dt> |
|
256 <dd> |
|
257 column number in the source model (integer) |
|
258 </dd><dt><i>sourceParent</i></dt> |
|
259 <dd> |
|
260 index of the source item (QModelIndex) |
|
261 </dd> |
|
262 </dl><dl> |
|
263 <dt>Returns:</dt> |
|
264 <dd> |
|
265 flag indicating acceptance (boolean) |
|
266 </dd> |
|
267 </dl><a NAME="AddBookmarkProxyModel.filterAcceptsRow" ID="AddBookmarkProxyModel.filterAcceptsRow"></a> |
|
268 <h4>AddBookmarkProxyModel.filterAcceptsRow</h4> |
|
269 <b>filterAcceptsRow</b>(<i>sourceRow, sourceParent</i>) |
|
270 <p> |
|
271 Protected method to determine, if the row is acceptable. |
|
272 </p><dl> |
|
273 <dt><i>sourceRow</i></dt> |
|
274 <dd> |
|
275 row number in the source model (integer) |
|
276 </dd><dt><i>sourceParent</i></dt> |
|
277 <dd> |
|
278 index of the source item (QModelIndex) |
|
279 </dd> |
|
280 </dl><dl> |
|
281 <dt>Returns:</dt> |
|
282 <dd> |
|
283 flag indicating acceptance (boolean) |
|
284 </dd> |
|
285 </dl><a NAME="AddBookmarkProxyModel.hasChildren" ID="AddBookmarkProxyModel.hasChildren"></a> |
|
286 <h4>AddBookmarkProxyModel.hasChildren</h4> |
|
287 <b>hasChildren</b>(<i>parent = QModelIndex()</i>) |
|
288 <p> |
|
289 Public method to check, if a parent node has some children. |
|
290 </p><dl> |
|
291 <dt><i>parent</i></dt> |
|
292 <dd> |
|
293 index of the parent node (QModelIndex) |
|
294 </dd> |
|
295 </dl><dl> |
|
296 <dt>Returns:</dt> |
|
297 <dd> |
|
298 flag indicating the presence of children (boolean) |
|
299 </dd> |
|
300 </dl> |
|
301 <div align="right"><a href="#top">Up</a></div> |
|
302 <hr /> |
|
303 </body></html> |