Documentation/Source/eric6.Helpviewer.GreaseMonkey.GreaseMonkeyManager.html

changeset 3673
e26d7d0c1088
child 5727
c8842a8d1167
equal deleted inserted replaced
3670:f0cb7579c0b4 3673:e26d7d0c1088
1 <!DOCTYPE html>
2 <html><head>
3 <title>eric6.Helpviewer.GreaseMonkey.GreaseMonkeyManager</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.Helpviewer.GreaseMonkey.GreaseMonkeyManager</h1>
23 <p>
24 Module implementing the manager for GreaseMonkey scripts.
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="#GreaseMonkeyManager">GreaseMonkeyManager</a></td>
34 <td>Class implementing the manager for GreaseMonkey scripts.</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="GreaseMonkeyManager" ID="GreaseMonkeyManager"></a>
43 <h2>GreaseMonkeyManager</h2>
44 <p>
45 Class implementing the manager for GreaseMonkey scripts.
46 </p>
47 <h3>Derived from</h3>
48 QObject
49 <h3>Class Attributes</h3>
50 <table>
51 <tr><td>None</td></tr>
52 </table>
53 <h3>Class Methods</h3>
54 <table>
55 <tr><td>None</td></tr>
56 </table>
57 <h3>Methods</h3>
58 <table>
59 <tr>
60 <td><a href="#GreaseMonkeyManager.__init__">GreaseMonkeyManager</a></td>
61 <td>Constructor</td>
62 </tr><tr>
63 <td><a href="#GreaseMonkeyManager.__downloaderFinished">__downloaderFinished</a></td>
64 <td>Private slot to handle the completion of a script download.</td>
65 </tr><tr>
66 <td><a href="#GreaseMonkeyManager.__load">__load</a></td>
67 <td>Private slot to load the available scripts into the manager.</td>
68 </tr><tr>
69 <td><a href="#GreaseMonkeyManager.addScript">addScript</a></td>
70 <td>Public method to add a script.</td>
71 </tr><tr>
72 <td><a href="#GreaseMonkeyManager.allScripts">allScripts</a></td>
73 <td>Public method to get a list of all scripts.</td>
74 </tr><tr>
75 <td><a href="#GreaseMonkeyManager.canRunOnScheme">canRunOnScheme</a></td>
76 <td>Public method to check, if scripts can be run on a scheme.</td>
77 </tr><tr>
78 <td><a href="#GreaseMonkeyManager.connectPage">connectPage</a></td>
79 <td>Public method to allow the GreaseMonkey manager to connect to the page.</td>
80 </tr><tr>
81 <td><a href="#GreaseMonkeyManager.containsScript">containsScript</a></td>
82 <td>Public method to check, if the given script exists.</td>
83 </tr><tr>
84 <td><a href="#GreaseMonkeyManager.createRequest">createRequest</a></td>
85 <td>Public method to create a request.</td>
86 </tr><tr>
87 <td><a href="#GreaseMonkeyManager.disableScript">disableScript</a></td>
88 <td>Public method to disable the given script.</td>
89 </tr><tr>
90 <td><a href="#GreaseMonkeyManager.downloadScript">downloadScript</a></td>
91 <td>Public method to download a GreaseMonkey script.</td>
92 </tr><tr>
93 <td><a href="#GreaseMonkeyManager.enableScript">enableScript</a></td>
94 <td>Public method to enable the given script.</td>
95 </tr><tr>
96 <td><a href="#GreaseMonkeyManager.pageLoadStarted">pageLoadStarted</a></td>
97 <td>Public slot to handle the start of loading a page.</td>
98 </tr><tr>
99 <td><a href="#GreaseMonkeyManager.removeScript">removeScript</a></td>
100 <td>Public method to remove a script.</td>
101 </tr><tr>
102 <td><a href="#GreaseMonkeyManager.requireScripts">requireScripts</a></td>
103 <td>Public method to get the sources of all required scripts.</td>
104 </tr><tr>
105 <td><a href="#GreaseMonkeyManager.requireScriptsDirectory">requireScriptsDirectory</a></td>
106 <td>Public method to get the path of the scripts directory.</td>
107 </tr><tr>
108 <td><a href="#GreaseMonkeyManager.saveConfiguration">saveConfiguration</a></td>
109 <td>Public method to save the configuration.</td>
110 </tr><tr>
111 <td><a href="#GreaseMonkeyManager.scriptsDirectory">scriptsDirectory</a></td>
112 <td>Public method to get the path of the scripts directory.</td>
113 </tr><tr>
114 <td><a href="#GreaseMonkeyManager.showConfigurationDialog">showConfigurationDialog</a></td>
115 <td>Public method to show the configuration dialog.</td>
116 </tr>
117 </table>
118 <h3>Static Methods</h3>
119 <table>
120 <tr><td>None</td></tr>
121 </table>
122 <a NAME="GreaseMonkeyManager.__init__" ID="GreaseMonkeyManager.__init__"></a>
123 <h4>GreaseMonkeyManager (Constructor)</h4>
124 <b>GreaseMonkeyManager</b>(<i>parent=None</i>)
125 <p>
126 Constructor
127 </p><dl>
128 <dt><i>parent</i></dt>
129 <dd>
130 reference to the parent object (QObject)
131 </dd>
132 </dl><a NAME="GreaseMonkeyManager.__downloaderFinished" ID="GreaseMonkeyManager.__downloaderFinished"></a>
133 <h4>GreaseMonkeyManager.__downloaderFinished</h4>
134 <b>__downloaderFinished</b>(<i></i>)
135 <p>
136 Private slot to handle the completion of a script download.
137 </p><a NAME="GreaseMonkeyManager.__load" ID="GreaseMonkeyManager.__load"></a>
138 <h4>GreaseMonkeyManager.__load</h4>
139 <b>__load</b>(<i></i>)
140 <p>
141 Private slot to load the available scripts into the manager.
142 </p><a NAME="GreaseMonkeyManager.addScript" ID="GreaseMonkeyManager.addScript"></a>
143 <h4>GreaseMonkeyManager.addScript</h4>
144 <b>addScript</b>(<i>script</i>)
145 <p>
146 Public method to add a script.
147 </p><dl>
148 <dt><i>script</i></dt>
149 <dd>
150 script to be added (GreaseMonkeyScript)
151 </dd>
152 </dl><dl>
153 <dt>Returns:</dt>
154 <dd>
155 flag indicating success (boolean)
156 </dd>
157 </dl><a NAME="GreaseMonkeyManager.allScripts" ID="GreaseMonkeyManager.allScripts"></a>
158 <h4>GreaseMonkeyManager.allScripts</h4>
159 <b>allScripts</b>(<i></i>)
160 <p>
161 Public method to get a list of all scripts.
162 </p><dl>
163 <dt>Returns:</dt>
164 <dd>
165 list of all scripts (list of GreaseMonkeyScript)
166 </dd>
167 </dl><a NAME="GreaseMonkeyManager.canRunOnScheme" ID="GreaseMonkeyManager.canRunOnScheme"></a>
168 <h4>GreaseMonkeyManager.canRunOnScheme</h4>
169 <b>canRunOnScheme</b>(<i>scheme</i>)
170 <p>
171 Public method to check, if scripts can be run on a scheme.
172 </p><dl>
173 <dt><i>scheme</i></dt>
174 <dd>
175 scheme to check (string)
176 </dd>
177 </dl><dl>
178 <dt>Returns:</dt>
179 <dd>
180 flag indicating, that scripts can be run (boolean)
181 </dd>
182 </dl><a NAME="GreaseMonkeyManager.connectPage" ID="GreaseMonkeyManager.connectPage"></a>
183 <h4>GreaseMonkeyManager.connectPage</h4>
184 <b>connectPage</b>(<i>page</i>)
185 <p>
186 Public method to allow the GreaseMonkey manager to connect to the page.
187 </p><dl>
188 <dt><i>page</i></dt>
189 <dd>
190 reference to the web page (HelpWebPage)
191 </dd>
192 </dl><a NAME="GreaseMonkeyManager.containsScript" ID="GreaseMonkeyManager.containsScript"></a>
193 <h4>GreaseMonkeyManager.containsScript</h4>
194 <b>containsScript</b>(<i>fullName</i>)
195 <p>
196 Public method to check, if the given script exists.
197 </p><dl>
198 <dt><i>fullName</i></dt>
199 <dd>
200 full name of the script (string)
201 </dd>
202 </dl><dl>
203 <dt>Returns:</dt>
204 <dd>
205 flag indicating the existence (boolean)
206 </dd>
207 </dl><a NAME="GreaseMonkeyManager.createRequest" ID="GreaseMonkeyManager.createRequest"></a>
208 <h4>GreaseMonkeyManager.createRequest</h4>
209 <b>createRequest</b>(<i>op, request, outgoingData=None</i>)
210 <p>
211 Public method to create a request.
212 </p><dl>
213 <dt><i>op</i></dt>
214 <dd>
215 the operation to be performed
216 (QNetworkAccessManager.Operation)
217 </dd><dt><i>request</i></dt>
218 <dd>
219 reference to the request object (QNetworkRequest)
220 </dd><dt><i>outgoingData</i></dt>
221 <dd>
222 reference to an IODevice containing data to be sent
223 (QIODevice)
224 </dd>
225 </dl><dl>
226 <dt>Returns:</dt>
227 <dd>
228 reference to the created reply object (QNetworkReply)
229 </dd>
230 </dl><a NAME="GreaseMonkeyManager.disableScript" ID="GreaseMonkeyManager.disableScript"></a>
231 <h4>GreaseMonkeyManager.disableScript</h4>
232 <b>disableScript</b>(<i>script</i>)
233 <p>
234 Public method to disable the given script.
235 </p><dl>
236 <dt><i>script</i></dt>
237 <dd>
238 script to be disabled (GreaseMonkeyScript)
239 </dd>
240 </dl><a NAME="GreaseMonkeyManager.downloadScript" ID="GreaseMonkeyManager.downloadScript"></a>
241 <h4>GreaseMonkeyManager.downloadScript</h4>
242 <b>downloadScript</b>(<i>request</i>)
243 <p>
244 Public method to download a GreaseMonkey script.
245 </p><dl>
246 <dt><i>request</i></dt>
247 <dd>
248 reference to the request (QNetworkRequest)
249 </dd>
250 </dl><a NAME="GreaseMonkeyManager.enableScript" ID="GreaseMonkeyManager.enableScript"></a>
251 <h4>GreaseMonkeyManager.enableScript</h4>
252 <b>enableScript</b>(<i>script</i>)
253 <p>
254 Public method to enable the given script.
255 </p><dl>
256 <dt><i>script</i></dt>
257 <dd>
258 script to be enabled (GreaseMonkeyScript)
259 </dd>
260 </dl><a NAME="GreaseMonkeyManager.pageLoadStarted" ID="GreaseMonkeyManager.pageLoadStarted"></a>
261 <h4>GreaseMonkeyManager.pageLoadStarted</h4>
262 <b>pageLoadStarted</b>(<i></i>)
263 <p>
264 Public slot to handle the start of loading a page.
265 </p><a NAME="GreaseMonkeyManager.removeScript" ID="GreaseMonkeyManager.removeScript"></a>
266 <h4>GreaseMonkeyManager.removeScript</h4>
267 <b>removeScript</b>(<i>script</i>)
268 <p>
269 Public method to remove a script.
270 </p><dl>
271 <dt><i>script</i></dt>
272 <dd>
273 script to be removed (GreaseMonkeyScript)
274 </dd>
275 </dl><dl>
276 <dt>Returns:</dt>
277 <dd>
278 flag indicating success (boolean)
279 </dd>
280 </dl><a NAME="GreaseMonkeyManager.requireScripts" ID="GreaseMonkeyManager.requireScripts"></a>
281 <h4>GreaseMonkeyManager.requireScripts</h4>
282 <b>requireScripts</b>(<i>urlList</i>)
283 <p>
284 Public method to get the sources of all required scripts.
285 </p><dl>
286 <dt><i>urlList</i></dt>
287 <dd>
288 list of URLs (list of string)
289 </dd>
290 </dl><dl>
291 <dt>Returns:</dt>
292 <dd>
293 sources of all required scripts (string)
294 </dd>
295 </dl><a NAME="GreaseMonkeyManager.requireScriptsDirectory" ID="GreaseMonkeyManager.requireScriptsDirectory"></a>
296 <h4>GreaseMonkeyManager.requireScriptsDirectory</h4>
297 <b>requireScriptsDirectory</b>(<i></i>)
298 <p>
299 Public method to get the path of the scripts directory.
300 </p><dl>
301 <dt>Returns:</dt>
302 <dd>
303 path of the scripts directory (string)
304 </dd>
305 </dl><a NAME="GreaseMonkeyManager.saveConfiguration" ID="GreaseMonkeyManager.saveConfiguration"></a>
306 <h4>GreaseMonkeyManager.saveConfiguration</h4>
307 <b>saveConfiguration</b>(<i></i>)
308 <p>
309 Public method to save the configuration.
310 </p><a NAME="GreaseMonkeyManager.scriptsDirectory" ID="GreaseMonkeyManager.scriptsDirectory"></a>
311 <h4>GreaseMonkeyManager.scriptsDirectory</h4>
312 <b>scriptsDirectory</b>(<i></i>)
313 <p>
314 Public method to get the path of the scripts directory.
315 </p><dl>
316 <dt>Returns:</dt>
317 <dd>
318 path of the scripts directory (string)
319 </dd>
320 </dl><a NAME="GreaseMonkeyManager.showConfigurationDialog" ID="GreaseMonkeyManager.showConfigurationDialog"></a>
321 <h4>GreaseMonkeyManager.showConfigurationDialog</h4>
322 <b>showConfigurationDialog</b>(<i>parent=None</i>)
323 <p>
324 Public method to show the configuration dialog.
325 </p><dl>
326 <dt><i>parent</i></dt>
327 <dd>
328 reference to the parent widget (QWidget)
329 </dd>
330 </dl>
331 <div align="right"><a href="#top">Up</a></div>
332 <hr />
333 </body></html>

eric ide

mercurial