|
1 <!DOCTYPE html> |
|
2 <html><head> |
|
3 <title>eric6.UI.PixmapCache</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.UI.PixmapCache</h1> |
|
23 <p> |
|
24 Module implementing a pixmap cache for icons. |
|
25 </p> |
|
26 <h3>Global Attributes</h3> |
|
27 <table> |
|
28 <tr><td>pixCache</td></tr> |
|
29 </table> |
|
30 <h3>Classes</h3> |
|
31 <table> |
|
32 <tr> |
|
33 <td><a href="#PixmapCache">PixmapCache</a></td> |
|
34 <td>Class implementing a pixmap cache for icons.</td> |
|
35 </tr> |
|
36 </table> |
|
37 <h3>Functions</h3> |
|
38 <table> |
|
39 <tr> |
|
40 <td><a href="#addSearchPath">addSearchPath</a></td> |
|
41 <td>Module function to add a path to the search path.</td> |
|
42 </tr><tr> |
|
43 <td><a href="#getCombinedIcon">getCombinedIcon</a></td> |
|
44 <td>Module function to retrieve a symbolic link icon.</td> |
|
45 </tr><tr> |
|
46 <td><a href="#getIcon">getIcon</a></td> |
|
47 <td>Module function to retrieve an icon.</td> |
|
48 </tr><tr> |
|
49 <td><a href="#getPixmap">getPixmap</a></td> |
|
50 <td>Module function to retrieve a pixmap.</td> |
|
51 </tr><tr> |
|
52 <td><a href="#getSymlinkIcon">getSymlinkIcon</a></td> |
|
53 <td>Module function to retrieve a symbolic link icon.</td> |
|
54 </tr> |
|
55 </table> |
|
56 <hr /><hr /> |
|
57 <a NAME="PixmapCache" ID="PixmapCache"></a> |
|
58 <h2>PixmapCache</h2> |
|
59 <p> |
|
60 Class implementing a pixmap cache for icons. |
|
61 </p> |
|
62 <h3>Derived from</h3> |
|
63 object |
|
64 <h3>Class Attributes</h3> |
|
65 <table> |
|
66 <tr><td>SupportedExtensions</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="#PixmapCache.__init__">PixmapCache</a></td> |
|
76 <td>Constructor</td> |
|
77 </tr><tr> |
|
78 <td><a href="#PixmapCache.addSearchPath">addSearchPath</a></td> |
|
79 <td>Public method to add a path to the search path.</td> |
|
80 </tr><tr> |
|
81 <td><a href="#PixmapCache.getPixmap">getPixmap</a></td> |
|
82 <td>Public method to retrieve a pixmap.</td> |
|
83 </tr> |
|
84 </table> |
|
85 <h3>Static Methods</h3> |
|
86 <table> |
|
87 <tr><td>None</td></tr> |
|
88 </table> |
|
89 <a NAME="PixmapCache.__init__" ID="PixmapCache.__init__"></a> |
|
90 <h4>PixmapCache (Constructor)</h4> |
|
91 <b>PixmapCache</b>(<i></i>) |
|
92 <p> |
|
93 Constructor |
|
94 </p><a NAME="PixmapCache.addSearchPath" ID="PixmapCache.addSearchPath"></a> |
|
95 <h4>PixmapCache.addSearchPath</h4> |
|
96 <b>addSearchPath</b>(<i>path</i>) |
|
97 <p> |
|
98 Public method to add a path to the search path. |
|
99 </p><dl> |
|
100 <dt><i>path</i></dt> |
|
101 <dd> |
|
102 path to add (string) |
|
103 </dd> |
|
104 </dl><a NAME="PixmapCache.getPixmap" ID="PixmapCache.getPixmap"></a> |
|
105 <h4>PixmapCache.getPixmap</h4> |
|
106 <b>getPixmap</b>(<i>key, size=None</i>) |
|
107 <p> |
|
108 Public method to retrieve a pixmap. |
|
109 </p><dl> |
|
110 <dt><i>key</i> (str)</dt> |
|
111 <dd> |
|
112 name of the wanted pixmap |
|
113 </dd><dt><i>size</i> (QSize)</dt> |
|
114 <dd> |
|
115 requested size |
|
116 </dd> |
|
117 </dl><dl> |
|
118 <dt>Returns:</dt> |
|
119 <dd> |
|
120 the requested pixmap |
|
121 </dd> |
|
122 </dl><dl> |
|
123 <dt>Return Type:</dt> |
|
124 <dd> |
|
125 QPixmap |
|
126 </dd> |
|
127 </dl> |
|
128 <div align="right"><a href="#top">Up</a></div> |
|
129 <hr /><hr /> |
|
130 <a NAME="addSearchPath" ID="addSearchPath"></a> |
|
131 <h2>addSearchPath</h2> |
|
132 <b>addSearchPath</b>(<i>path, cache=pixCache</i>) |
|
133 <p> |
|
134 Module function to add a path to the search path. |
|
135 </p><dl> |
|
136 <dt><i>path</i></dt> |
|
137 <dd> |
|
138 path to add (string) |
|
139 </dd><dt><i>cache</i></dt> |
|
140 <dd> |
|
141 reference to the pixmap cache object (PixmapCache) |
|
142 </dd> |
|
143 </dl> |
|
144 <div align="right"><a href="#top">Up</a></div> |
|
145 <hr /><hr /> |
|
146 <a NAME="getCombinedIcon" ID="getCombinedIcon"></a> |
|
147 <h2>getCombinedIcon</h2> |
|
148 <b>getCombinedIcon</b>(<i>keys, size=None, cache=pixCache</i>) |
|
149 <p> |
|
150 Module function to retrieve a symbolic link icon. |
|
151 </p><dl> |
|
152 <dt><i>keys</i> (list of str)</dt> |
|
153 <dd> |
|
154 list of names of icons |
|
155 </dd><dt><i>size</i> (QSize)</dt> |
|
156 <dd> |
|
157 requested size of individual icons |
|
158 </dd><dt><i>cache</i> (PixmapCache)</dt> |
|
159 <dd> |
|
160 reference to the pixmap cache object |
|
161 </dd> |
|
162 </dl><dl> |
|
163 <dt>Returns:</dt> |
|
164 <dd> |
|
165 the requested icon |
|
166 </dd> |
|
167 </dl><dl> |
|
168 <dt>Return Type:</dt> |
|
169 <dd> |
|
170 QIcon |
|
171 </dd> |
|
172 </dl> |
|
173 <div align="right"><a href="#top">Up</a></div> |
|
174 <hr /><hr /> |
|
175 <a NAME="getIcon" ID="getIcon"></a> |
|
176 <h2>getIcon</h2> |
|
177 <b>getIcon</b>(<i>key, size=None, cache=pixCache</i>) |
|
178 <p> |
|
179 Module function to retrieve an icon. |
|
180 </p><dl> |
|
181 <dt><i>key</i> (str)</dt> |
|
182 <dd> |
|
183 name of the wanted pixmap |
|
184 </dd><dt><i>size</i> (QSize)</dt> |
|
185 <dd> |
|
186 requested size |
|
187 </dd><dt><i>cache</i> (PixmapCache)</dt> |
|
188 <dd> |
|
189 reference to the pixmap cache object |
|
190 </dd> |
|
191 </dl><dl> |
|
192 <dt>Returns:</dt> |
|
193 <dd> |
|
194 the requested icon |
|
195 </dd> |
|
196 </dl><dl> |
|
197 <dt>Return Type:</dt> |
|
198 <dd> |
|
199 QIcon |
|
200 </dd> |
|
201 </dl> |
|
202 <div align="right"><a href="#top">Up</a></div> |
|
203 <hr /><hr /> |
|
204 <a NAME="getPixmap" ID="getPixmap"></a> |
|
205 <h2>getPixmap</h2> |
|
206 <b>getPixmap</b>(<i>key, size=None, cache=pixCache</i>) |
|
207 <p> |
|
208 Module function to retrieve a pixmap. |
|
209 </p><dl> |
|
210 <dt><i>key</i> (str)</dt> |
|
211 <dd> |
|
212 name of the wanted pixmap |
|
213 </dd><dt><i>size</i> (QSize)</dt> |
|
214 <dd> |
|
215 requested size |
|
216 </dd><dt><i>cache</i> (PixmapCache)</dt> |
|
217 <dd> |
|
218 reference to the pixmap cache object |
|
219 </dd> |
|
220 </dl><dl> |
|
221 <dt>Returns:</dt> |
|
222 <dd> |
|
223 the requested pixmap |
|
224 </dd> |
|
225 </dl><dl> |
|
226 <dt>Return Type:</dt> |
|
227 <dd> |
|
228 QPixmap |
|
229 </dd> |
|
230 </dl> |
|
231 <div align="right"><a href="#top">Up</a></div> |
|
232 <hr /><hr /> |
|
233 <a NAME="getSymlinkIcon" ID="getSymlinkIcon"></a> |
|
234 <h2>getSymlinkIcon</h2> |
|
235 <b>getSymlinkIcon</b>(<i>key, size=None, cache=pixCache</i>) |
|
236 <p> |
|
237 Module function to retrieve a symbolic link icon. |
|
238 </p><dl> |
|
239 <dt><i>key</i> (str)</dt> |
|
240 <dd> |
|
241 name of the wanted pixmap |
|
242 </dd><dt><i>size</i> (QSize)</dt> |
|
243 <dd> |
|
244 requested size |
|
245 </dd><dt><i>cache</i> (PixmapCache)</dt> |
|
246 <dd> |
|
247 reference to the pixmap cache object |
|
248 </dd> |
|
249 </dl><dl> |
|
250 <dt>Returns:</dt> |
|
251 <dd> |
|
252 the requested icon |
|
253 </dd> |
|
254 </dl><dl> |
|
255 <dt>Return Type:</dt> |
|
256 <dd> |
|
257 QIcon |
|
258 </dd> |
|
259 </dl> |
|
260 <div align="right"><a href="#top">Up</a></div> |
|
261 <hr /> |
|
262 </body></html> |