Documentation/Source/eric6.WebBrowser.SpeedDial.SpeedDial.html

changeset 4918
71caf42a13d8
child 4954
36e92a908f3f
equal deleted inserted replaced
4917:682750cc7bd5 4918:71caf42a13d8
1 <!DOCTYPE html>
2 <html><head>
3 <title>eric6.WebBrowser.SpeedDial.SpeedDial</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.WebBrowser.SpeedDial.SpeedDial</h1>
23 <p>
24 Module implementing the speed dial.
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="#SpeedDial">SpeedDial</a></td>
34 <td>Class implementing the speed dial.</td>
35 </tr>
36 </table>
37 <h3>Functions</h3>
38 <table>
39 <tr><td>None</td></tr>
40 </table>
41 <hr /><hr />
42 <a NAME="SpeedDial" ID="SpeedDial"></a>
43 <h2>SpeedDial</h2>
44 <p>
45 Class implementing the speed dial.
46 </p><h3>Signals</h3>
47 <dl>
48 <dt>pagesChanged()</dt>
49 <dd>
50 emitted after the list of pages changed
51 </dd><dt>speedDialSaved()</dt>
52 <dd>
53 emitted after the speed dial data was saved
54 </dd><dt>thumbnailLoaded(url, src)</dt>
55 <dd>
56 emitted after a thumbnail was loaded
57 </dd><dt>titleLoaded(url, title)</dt>
58 <dd>
59 emitted after a title was loaded
60 </dd>
61 </dl>
62 <h3>Derived from</h3>
63 QObject
64 <h3>Class Attributes</h3>
65 <table>
66 <tr><td>None</td></tr>
67 </table>
68 <h3>Class Methods</h3>
69 <table>
70 <tr><td>None</td></tr>
71 </table>
72 <h3>Methods</h3>
73 <table>
74 <tr>
75 <td><a href="#SpeedDial.__init__">SpeedDial</a></td>
76 <td>Constructor</td>
77 </tr><tr>
78 <td><a href="#SpeedDial.__escapeTitle">__escapeTitle</a></td>
79 <td>Private method to escape a title string.</td>
80 </tr><tr>
81 <td><a href="#SpeedDial.__escapeUrl">__escapeUrl</a></td>
82 <td>Private method to escape an URL string.</td>
83 </tr><tr>
84 <td><a href="#SpeedDial.__imageFileName">__imageFileName</a></td>
85 <td>Private method to generate the image file name for a URL.</td>
86 </tr><tr>
87 <td><a href="#SpeedDial.__initialize">__initialize</a></td>
88 <td>Private method to initialize the speed dial.</td>
89 </tr><tr>
90 <td><a href="#SpeedDial.__load">__load</a></td>
91 <td>Private method to load the speed dial configuration.</td>
92 </tr><tr>
93 <td><a href="#SpeedDial.__thumbnailCreated">__thumbnailCreated</a></td>
94 <td>Private slot to handle the creation of a thumbnail image.</td>
95 </tr><tr>
96 <td><a href="#SpeedDial.addPage">addPage</a></td>
97 <td>Public method to add a page for the given data.</td>
98 </tr><tr>
99 <td><a href="#SpeedDial.changed">changed</a></td>
100 <td>Public slot to react on changed pages.</td>
101 </tr><tr>
102 <td><a href="#SpeedDial.close">close</a></td>
103 <td>Public method to close the user agents manager.</td>
104 </tr><tr>
105 <td><a href="#SpeedDial.getFileName">getFileName</a></td>
106 <td>Public method to get the file name of the user agents file.</td>
107 </tr><tr>
108 <td><a href="#SpeedDial.initialScript">initialScript</a></td>
109 <td>Public method to get the 'initial' JavaScript script.</td>
110 </tr><tr>
111 <td><a href="#SpeedDial.loadThumbnail">loadThumbnail</a></td>
112 <td>Public slot to load a thumbnail of the given URL.</td>
113 </tr><tr>
114 <td><a href="#SpeedDial.pageForUrl">pageForUrl</a></td>
115 <td>Public method to get the page for the given URL.</td>
116 </tr><tr>
117 <td><a href="#SpeedDial.pagesInRow">pagesInRow</a></td>
118 <td>Public method to get the number of dials per row.</td>
119 </tr><tr>
120 <td><a href="#SpeedDial.reload">reload</a></td>
121 <td>Public method to reload the speed dial data.</td>
122 </tr><tr>
123 <td><a href="#SpeedDial.removeImageForUrl">removeImageForUrl</a></td>
124 <td>Public slot to remove the image for a URL.</td>
125 </tr><tr>
126 <td><a href="#SpeedDial.removePage">removePage</a></td>
127 <td>Public method to remove a page.</td>
128 </tr><tr>
129 <td><a href="#SpeedDial.save">save</a></td>
130 <td>Public method to save the speed dial configuration.</td>
131 </tr><tr>
132 <td><a href="#SpeedDial.sdSize">sdSize</a></td>
133 <td>Public method to get the speed dial size.</td>
134 </tr><tr>
135 <td><a href="#SpeedDial.setPagesInRow">setPagesInRow</a></td>
136 <td>Public slot to set the number of pages per row.</td>
137 </tr><tr>
138 <td><a href="#SpeedDial.setSdSize">setSdSize</a></td>
139 <td>Public slot to set the size of the speed dial.</td>
140 </tr><tr>
141 <td><a href="#SpeedDial.urlForShortcut">urlForShortcut</a></td>
142 <td>Public method to get the URL for the given shortcut key.</td>
143 </tr><tr>
144 <td><a href="#SpeedDial.urlFromUserInput">urlFromUserInput</a></td>
145 <td>Public slot to get the URL from user input.</td>
146 </tr>
147 </table>
148 <h3>Static Methods</h3>
149 <table>
150 <tr><td>None</td></tr>
151 </table>
152 <a NAME="SpeedDial.__init__" ID="SpeedDial.__init__"></a>
153 <h4>SpeedDial (Constructor)</h4>
154 <b>SpeedDial</b>(<i>parent=None</i>)
155 <p>
156 Constructor
157 </p><dl>
158 <dt><i>parent</i></dt>
159 <dd>
160 reference to the parent object (QObject)
161 </dd>
162 </dl><a NAME="SpeedDial.__escapeTitle" ID="SpeedDial.__escapeTitle"></a>
163 <h4>SpeedDial.__escapeTitle</h4>
164 <b>__escapeTitle</b>(<i>title</i>)
165 <p>
166 Private method to escape a title string.
167 </p><dl>
168 <dt><i>title</i> (str)</dt>
169 <dd>
170 title string to be escaped
171 </dd>
172 </dl><dl>
173 <dt>Returns:</dt>
174 <dd>
175 escaped title string
176 </dd>
177 </dl><dl>
178 <dt>Return Type:</dt>
179 <dd>
180 str
181 </dd>
182 </dl><a NAME="SpeedDial.__escapeUrl" ID="SpeedDial.__escapeUrl"></a>
183 <h4>SpeedDial.__escapeUrl</h4>
184 <b>__escapeUrl</b>(<i>url</i>)
185 <p>
186 Private method to escape an URL string.
187 </p><dl>
188 <dt><i>url</i> (str)</dt>
189 <dd>
190 URL to be escaped
191 </dd>
192 </dl><dl>
193 <dt>Returns:</dt>
194 <dd>
195 escaped URL string
196 </dd>
197 </dl><dl>
198 <dt>Return Type:</dt>
199 <dd>
200 str
201 </dd>
202 </dl><a NAME="SpeedDial.__imageFileName" ID="SpeedDial.__imageFileName"></a>
203 <h4>SpeedDial.__imageFileName</h4>
204 <b>__imageFileName</b>(<i>url</i>)
205 <p>
206 Private method to generate the image file name for a URL.
207 </p><dl>
208 <dt><i>url</i></dt>
209 <dd>
210 URL to generate the file name from (string)
211 </dd>
212 </dl><dl>
213 <dt>Returns:</dt>
214 <dd>
215 name of the image file (string)
216 </dd>
217 </dl><a NAME="SpeedDial.__initialize" ID="SpeedDial.__initialize"></a>
218 <h4>SpeedDial.__initialize</h4>
219 <b>__initialize</b>(<i></i>)
220 <p>
221 Private method to initialize the speed dial.
222 </p><a NAME="SpeedDial.__load" ID="SpeedDial.__load"></a>
223 <h4>SpeedDial.__load</h4>
224 <b>__load</b>(<i></i>)
225 <p>
226 Private method to load the speed dial configuration.
227 </p><a NAME="SpeedDial.__thumbnailCreated" ID="SpeedDial.__thumbnailCreated"></a>
228 <h4>SpeedDial.__thumbnailCreated</h4>
229 <b>__thumbnailCreated</b>(<i>image</i>)
230 <p>
231 Private slot to handle the creation of a thumbnail image.
232 </p><dl>
233 <dt><i>image</i></dt>
234 <dd>
235 thumbnail image (QPixmap)
236 </dd>
237 </dl><a NAME="SpeedDial.addPage" ID="SpeedDial.addPage"></a>
238 <h4>SpeedDial.addPage</h4>
239 <b>addPage</b>(<i>url, title</i>)
240 <p>
241 Public method to add a page for the given data.
242 </p><dl>
243 <dt><i>url</i></dt>
244 <dd>
245 URL of the page (QUrl)
246 </dd><dt><i>title</i></dt>
247 <dd>
248 title of the page (string)
249 </dd>
250 </dl><a NAME="SpeedDial.changed" ID="SpeedDial.changed"></a>
251 <h4>SpeedDial.changed</h4>
252 <b>changed</b>(<i>allPages</i>)
253 <p>
254 Public slot to react on changed pages.
255 </p><dl>
256 <dt><i>allPages</i></dt>
257 <dd>
258 string giving all pages (string)
259 </dd>
260 </dl><a NAME="SpeedDial.close" ID="SpeedDial.close"></a>
261 <h4>SpeedDial.close</h4>
262 <b>close</b>(<i></i>)
263 <p>
264 Public method to close the user agents manager.
265 </p><a NAME="SpeedDial.getFileName" ID="SpeedDial.getFileName"></a>
266 <h4>SpeedDial.getFileName</h4>
267 <b>getFileName</b>(<i></i>)
268 <p>
269 Public method to get the file name of the user agents file.
270 </p><dl>
271 <dt>Returns:</dt>
272 <dd>
273 name of the user agents file (string)
274 </dd>
275 </dl><a NAME="SpeedDial.initialScript" ID="SpeedDial.initialScript"></a>
276 <h4>SpeedDial.initialScript</h4>
277 <b>initialScript</b>(<i></i>)
278 <p>
279 Public method to get the 'initial' JavaScript script.
280 </p><dl>
281 <dt>Returns:</dt>
282 <dd>
283 initial JavaScript script (string)
284 </dd>
285 </dl><a NAME="SpeedDial.loadThumbnail" ID="SpeedDial.loadThumbnail"></a>
286 <h4>SpeedDial.loadThumbnail</h4>
287 <b>loadThumbnail</b>(<i>url, loadTitle</i>)
288 <p>
289 Public slot to load a thumbnail of the given URL.
290 </p><dl>
291 <dt><i>url</i></dt>
292 <dd>
293 URL of the thumbnail (string)
294 </dd><dt><i>loadTitle</i></dt>
295 <dd>
296 flag indicating to get the title for the thumbnail
297 from the site (boolean)
298 </dd>
299 </dl><a NAME="SpeedDial.pageForUrl" ID="SpeedDial.pageForUrl"></a>
300 <h4>SpeedDial.pageForUrl</h4>
301 <b>pageForUrl</b>(<i>url</i>)
302 <p>
303 Public method to get the page for the given URL.
304 </p><dl>
305 <dt><i>url</i></dt>
306 <dd>
307 URL to be searched for (QUrl)
308 </dd>
309 </dl><dl>
310 <dt>Returns:</dt>
311 <dd>
312 page for the URL (Page)
313 </dd>
314 </dl><a NAME="SpeedDial.pagesInRow" ID="SpeedDial.pagesInRow"></a>
315 <h4>SpeedDial.pagesInRow</h4>
316 <b>pagesInRow</b>(<i></i>)
317 <p>
318 Public method to get the number of dials per row.
319 </p><dl>
320 <dt>Returns:</dt>
321 <dd>
322 number of dials per row (integer)
323 </dd>
324 </dl><a NAME="SpeedDial.reload" ID="SpeedDial.reload"></a>
325 <h4>SpeedDial.reload</h4>
326 <b>reload</b>(<i></i>)
327 <p>
328 Public method to reload the speed dial data.
329 </p><a NAME="SpeedDial.removeImageForUrl" ID="SpeedDial.removeImageForUrl"></a>
330 <h4>SpeedDial.removeImageForUrl</h4>
331 <b>removeImageForUrl</b>(<i>url</i>)
332 <p>
333 Public slot to remove the image for a URL.
334 </p><dl>
335 <dt><i>url</i></dt>
336 <dd>
337 URL to remove the image for (string)
338 </dd>
339 </dl><a NAME="SpeedDial.removePage" ID="SpeedDial.removePage"></a>
340 <h4>SpeedDial.removePage</h4>
341 <b>removePage</b>(<i>url</i>)
342 <p>
343 Public method to remove a page.
344 </p><dl>
345 <dt><i>url</i></dt>
346 <dd>
347 URL of the page (QUrl)
348 </dd>
349 </dl><a NAME="SpeedDial.save" ID="SpeedDial.save"></a>
350 <h4>SpeedDial.save</h4>
351 <b>save</b>(<i></i>)
352 <p>
353 Public method to save the speed dial configuration.
354 </p><a NAME="SpeedDial.sdSize" ID="SpeedDial.sdSize"></a>
355 <h4>SpeedDial.sdSize</h4>
356 <b>sdSize</b>(<i></i>)
357 <p>
358 Public method to get the speed dial size.
359 </p><dl>
360 <dt>Returns:</dt>
361 <dd>
362 speed dial size (integer)
363 </dd>
364 </dl><a NAME="SpeedDial.setPagesInRow" ID="SpeedDial.setPagesInRow"></a>
365 <h4>SpeedDial.setPagesInRow</h4>
366 <b>setPagesInRow</b>(<i>count</i>)
367 <p>
368 Public slot to set the number of pages per row.
369 </p><dl>
370 <dt><i>count</i></dt>
371 <dd>
372 number of pages per row (integer)
373 </dd>
374 </dl><a NAME="SpeedDial.setSdSize" ID="SpeedDial.setSdSize"></a>
375 <h4>SpeedDial.setSdSize</h4>
376 <b>setSdSize</b>(<i>size</i>)
377 <p>
378 Public slot to set the size of the speed dial.
379 </p><dl>
380 <dt><i>size</i></dt>
381 <dd>
382 size of the speed dial (integer)
383 </dd>
384 </dl><a NAME="SpeedDial.urlForShortcut" ID="SpeedDial.urlForShortcut"></a>
385 <h4>SpeedDial.urlForShortcut</h4>
386 <b>urlForShortcut</b>(<i>key</i>)
387 <p>
388 Public method to get the URL for the given shortcut key.
389 </p><dl>
390 <dt><i>key</i></dt>
391 <dd>
392 shortcut key (integer)
393 </dd>
394 </dl><dl>
395 <dt>Returns:</dt>
396 <dd>
397 URL for the key (QUrl)
398 </dd>
399 </dl><a NAME="SpeedDial.urlFromUserInput" ID="SpeedDial.urlFromUserInput"></a>
400 <h4>SpeedDial.urlFromUserInput</h4>
401 <b>urlFromUserInput</b>(<i>url</i>)
402 <p>
403 Public slot to get the URL from user input.
404 </p><dl>
405 <dt><i>url</i></dt>
406 <dd>
407 URL entered by the user (string)
408 </dd>
409 </dl><dl>
410 <dt>Returns:</dt>
411 <dd>
412 sanitized URL (string)
413 </dd>
414 </dl>
415 <div align="right"><a href="#top">Up</a></div>
416 <hr />
417 </body></html>

eric ide

mercurial