]>
Commit | Line | Data |
---|---|---|
1 | # This file was created automatically by SWIG. | |
2 | import gdic | |
3 | ||
4 | from misc import * | |
5 | ||
6 | from fonts import * | |
7 | import wx | |
8 | class wxGDIObjectPtr(wxObjectPtr): | |
9 | def __init__(self,this): | |
10 | self.this = this | |
11 | self.thisown = 0 | |
12 | def __del__(self, delfunc=gdic.delete_wxGDIObject): | |
13 | if self.thisown == 1: | |
14 | try: | |
15 | delfunc(self) | |
16 | except: | |
17 | pass | |
18 | def GetVisible(self, *_args, **_kwargs): | |
19 | val = apply(gdic.wxGDIObject_GetVisible,(self,) + _args, _kwargs) | |
20 | return val | |
21 | def SetVisible(self, *_args, **_kwargs): | |
22 | val = apply(gdic.wxGDIObject_SetVisible,(self,) + _args, _kwargs) | |
23 | return val | |
24 | def IsNull(self, *_args, **_kwargs): | |
25 | val = apply(gdic.wxGDIObject_IsNull,(self,) + _args, _kwargs) | |
26 | return val | |
27 | def __repr__(self): | |
28 | return "<C wxGDIObject instance at %s>" % (self.this,) | |
29 | class wxGDIObject(wxGDIObjectPtr): | |
30 | def __init__(self,*_args,**_kwargs): | |
31 | self.this = apply(gdic.new_wxGDIObject,_args,_kwargs) | |
32 | self.thisown = 1 | |
33 | ||
34 | ||
35 | ||
36 | ||
37 | class wxBitmapPtr(wxGDIObjectPtr): | |
38 | def __init__(self,this): | |
39 | self.this = this | |
40 | self.thisown = 0 | |
41 | def __del__(self, delfunc=gdic.delete_wxBitmap): | |
42 | if self.thisown == 1: | |
43 | try: | |
44 | delfunc(self) | |
45 | except: | |
46 | pass | |
47 | def GetPalette(self, *_args, **_kwargs): | |
48 | val = apply(gdic.wxBitmap_GetPalette,(self,) + _args, _kwargs) | |
49 | if val: val = wxPalettePtr(val) | |
50 | return val | |
51 | def GetMask(self, *_args, **_kwargs): | |
52 | val = apply(gdic.wxBitmap_GetMask,(self,) + _args, _kwargs) | |
53 | if val: val = wxMaskPtr(val) | |
54 | return val | |
55 | def LoadFile(self, *_args, **_kwargs): | |
56 | val = apply(gdic.wxBitmap_LoadFile,(self,) + _args, _kwargs) | |
57 | return val | |
58 | def SaveFile(self, *_args, **_kwargs): | |
59 | val = apply(gdic.wxBitmap_SaveFile,(self,) + _args, _kwargs) | |
60 | return val | |
61 | def SetMask(self, *_args, **_kwargs): | |
62 | val = apply(gdic.wxBitmap_SetMask,(self,) + _args, _kwargs) | |
63 | return val | |
64 | def SetPalette(self, *_args, **_kwargs): | |
65 | val = apply(gdic.wxBitmap_SetPalette,(self,) + _args, _kwargs) | |
66 | return val | |
67 | def GetHandle(self, *_args, **_kwargs): | |
68 | val = apply(gdic.wxBitmap_GetHandle,(self,) + _args, _kwargs) | |
69 | return val | |
70 | def SetHandle(self, *_args, **_kwargs): | |
71 | val = apply(gdic.wxBitmap_SetHandle,(self,) + _args, _kwargs) | |
72 | return val | |
73 | def Ok(self, *_args, **_kwargs): | |
74 | val = apply(gdic.wxBitmap_Ok,(self,) + _args, _kwargs) | |
75 | return val | |
76 | def GetWidth(self, *_args, **_kwargs): | |
77 | val = apply(gdic.wxBitmap_GetWidth,(self,) + _args, _kwargs) | |
78 | return val | |
79 | def GetHeight(self, *_args, **_kwargs): | |
80 | val = apply(gdic.wxBitmap_GetHeight,(self,) + _args, _kwargs) | |
81 | return val | |
82 | def GetDepth(self, *_args, **_kwargs): | |
83 | val = apply(gdic.wxBitmap_GetDepth,(self,) + _args, _kwargs) | |
84 | return val | |
85 | def SetWidth(self, *_args, **_kwargs): | |
86 | val = apply(gdic.wxBitmap_SetWidth,(self,) + _args, _kwargs) | |
87 | return val | |
88 | def SetHeight(self, *_args, **_kwargs): | |
89 | val = apply(gdic.wxBitmap_SetHeight,(self,) + _args, _kwargs) | |
90 | return val | |
91 | def SetDepth(self, *_args, **_kwargs): | |
92 | val = apply(gdic.wxBitmap_SetDepth,(self,) + _args, _kwargs) | |
93 | return val | |
94 | def SetSize(self, *_args, **_kwargs): | |
95 | val = apply(gdic.wxBitmap_SetSize,(self,) + _args, _kwargs) | |
96 | return val | |
97 | def GetSubBitmap(self, *_args, **_kwargs): | |
98 | val = apply(gdic.wxBitmap_GetSubBitmap,(self,) + _args, _kwargs) | |
99 | if val: val = wxBitmapPtr(val) ; val.thisown = 1 | |
100 | return val | |
101 | def CopyFromIcon(self, *_args, **_kwargs): | |
102 | val = apply(gdic.wxBitmap_CopyFromIcon,(self,) + _args, _kwargs) | |
103 | return val | |
104 | def CopyFromCursor(self, *_args, **_kwargs): | |
105 | val = apply(gdic.wxBitmap_CopyFromCursor,(self,) + _args, _kwargs) | |
106 | return val | |
107 | def GetQuality(self, *_args, **_kwargs): | |
108 | val = apply(gdic.wxBitmap_GetQuality,(self,) + _args, _kwargs) | |
109 | return val | |
110 | def SetQuality(self, *_args, **_kwargs): | |
111 | val = apply(gdic.wxBitmap_SetQuality,(self,) + _args, _kwargs) | |
112 | return val | |
113 | def __repr__(self): | |
114 | return "<C wxBitmap instance at %s>" % (self.this,) | |
115 | ||
116 | def SetMaskColour(self, colour): | |
117 | mask = wxMaskColour(self, colour) | |
118 | self.SetMask(mask) | |
119 | ||
120 | class wxBitmap(wxBitmapPtr): | |
121 | def __init__(self,*_args,**_kwargs): | |
122 | self.this = apply(gdic.new_wxBitmap,_args,_kwargs) | |
123 | self.thisown = 1 | |
124 | ||
125 | ||
126 | ||
127 | ||
128 | class wxMaskPtr(wxObjectPtr): | |
129 | def __init__(self,this): | |
130 | self.this = this | |
131 | self.thisown = 0 | |
132 | def Destroy(self, *_args, **_kwargs): | |
133 | val = apply(gdic.wxMask_Destroy,(self,) + _args, _kwargs) | |
134 | return val | |
135 | def __repr__(self): | |
136 | return "<C wxMask instance at %s>" % (self.this,) | |
137 | class wxMask(wxMaskPtr): | |
138 | def __init__(self,*_args,**_kwargs): | |
139 | self.this = apply(gdic.new_wxMask,_args,_kwargs) | |
140 | self.thisown = 1 | |
141 | ||
142 | ||
143 | ||
144 | ||
145 | class wxIconPtr(wxGDIObjectPtr): | |
146 | def __init__(self,this): | |
147 | self.this = this | |
148 | self.thisown = 0 | |
149 | def __del__(self, delfunc=gdic.delete_wxIcon): | |
150 | if self.thisown == 1: | |
151 | try: | |
152 | delfunc(self) | |
153 | except: | |
154 | pass | |
155 | def LoadFile(self, *_args, **_kwargs): | |
156 | val = apply(gdic.wxIcon_LoadFile,(self,) + _args, _kwargs) | |
157 | return val | |
158 | def GetHandle(self, *_args, **_kwargs): | |
159 | val = apply(gdic.wxIcon_GetHandle,(self,) + _args, _kwargs) | |
160 | return val | |
161 | def SetHandle(self, *_args, **_kwargs): | |
162 | val = apply(gdic.wxIcon_SetHandle,(self,) + _args, _kwargs) | |
163 | return val | |
164 | def Ok(self, *_args, **_kwargs): | |
165 | val = apply(gdic.wxIcon_Ok,(self,) + _args, _kwargs) | |
166 | return val | |
167 | def GetWidth(self, *_args, **_kwargs): | |
168 | val = apply(gdic.wxIcon_GetWidth,(self,) + _args, _kwargs) | |
169 | return val | |
170 | def GetHeight(self, *_args, **_kwargs): | |
171 | val = apply(gdic.wxIcon_GetHeight,(self,) + _args, _kwargs) | |
172 | return val | |
173 | def GetDepth(self, *_args, **_kwargs): | |
174 | val = apply(gdic.wxIcon_GetDepth,(self,) + _args, _kwargs) | |
175 | return val | |
176 | def SetWidth(self, *_args, **_kwargs): | |
177 | val = apply(gdic.wxIcon_SetWidth,(self,) + _args, _kwargs) | |
178 | return val | |
179 | def SetHeight(self, *_args, **_kwargs): | |
180 | val = apply(gdic.wxIcon_SetHeight,(self,) + _args, _kwargs) | |
181 | return val | |
182 | def SetDepth(self, *_args, **_kwargs): | |
183 | val = apply(gdic.wxIcon_SetDepth,(self,) + _args, _kwargs) | |
184 | return val | |
185 | def SetSize(self, *_args, **_kwargs): | |
186 | val = apply(gdic.wxIcon_SetSize,(self,) + _args, _kwargs) | |
187 | return val | |
188 | def CopyFromBitmap(self, *_args, **_kwargs): | |
189 | val = apply(gdic.wxIcon_CopyFromBitmap,(self,) + _args, _kwargs) | |
190 | return val | |
191 | def __repr__(self): | |
192 | return "<C wxIcon instance at %s>" % (self.this,) | |
193 | class wxIcon(wxIconPtr): | |
194 | def __init__(self,*_args,**_kwargs): | |
195 | self.this = apply(gdic.new_wxIcon,_args,_kwargs) | |
196 | self.thisown = 1 | |
197 | ||
198 | ||
199 | ||
200 | ||
201 | class wxIconBundlePtr : | |
202 | def __init__(self,this): | |
203 | self.this = this | |
204 | self.thisown = 0 | |
205 | def __del__(self, delfunc=gdic.delete_wxIconBundle): | |
206 | if self.thisown == 1: | |
207 | try: | |
208 | delfunc(self) | |
209 | except: | |
210 | pass | |
211 | def AddIcon(self, *_args, **_kwargs): | |
212 | val = apply(gdic.wxIconBundle_AddIcon,(self,) + _args, _kwargs) | |
213 | return val | |
214 | def AddIconFromFile(self, *_args, **_kwargs): | |
215 | val = apply(gdic.wxIconBundle_AddIconFromFile,(self,) + _args, _kwargs) | |
216 | return val | |
217 | def GetIcon(self, *_args, **_kwargs): | |
218 | val = apply(gdic.wxIconBundle_GetIcon,(self,) + _args, _kwargs) | |
219 | if val: val = wxIconPtr(val) | |
220 | return val | |
221 | def __repr__(self): | |
222 | return "<C wxIconBundle instance at %s>" % (self.this,) | |
223 | class wxIconBundle(wxIconBundlePtr): | |
224 | def __init__(self,*_args,**_kwargs): | |
225 | self.this = apply(gdic.new_wxIconBundle,_args,_kwargs) | |
226 | self.thisown = 1 | |
227 | ||
228 | ||
229 | ||
230 | def wxIconBundleFromFile(*_args,**_kwargs): | |
231 | val = wxIconBundlePtr(apply(gdic.new_wxIconBundleFromFile,_args,_kwargs)) | |
232 | val.thisown = 1 | |
233 | return val | |
234 | ||
235 | def wxIconBundleFromIcon(*_args,**_kwargs): | |
236 | val = wxIconBundlePtr(apply(gdic.new_wxIconBundleFromIcon,_args,_kwargs)) | |
237 | val.thisown = 1 | |
238 | return val | |
239 | ||
240 | ||
241 | class wxCursorPtr(wxGDIObjectPtr): | |
242 | def __init__(self,this): | |
243 | self.this = this | |
244 | self.thisown = 0 | |
245 | def __del__(self, delfunc=gdic.delete_wxCursor): | |
246 | if self.thisown == 1: | |
247 | try: | |
248 | delfunc(self) | |
249 | except: | |
250 | pass | |
251 | def GetHandle(self, *_args, **_kwargs): | |
252 | val = apply(gdic.wxCursor_GetHandle,(self,) + _args, _kwargs) | |
253 | return val | |
254 | def SetHandle(self, *_args, **_kwargs): | |
255 | val = apply(gdic.wxCursor_SetHandle,(self,) + _args, _kwargs) | |
256 | return val | |
257 | def Ok(self, *_args, **_kwargs): | |
258 | val = apply(gdic.wxCursor_Ok,(self,) + _args, _kwargs) | |
259 | return val | |
260 | def GetWidth(self, *_args, **_kwargs): | |
261 | val = apply(gdic.wxCursor_GetWidth,(self,) + _args, _kwargs) | |
262 | return val | |
263 | def GetHeight(self, *_args, **_kwargs): | |
264 | val = apply(gdic.wxCursor_GetHeight,(self,) + _args, _kwargs) | |
265 | return val | |
266 | def GetDepth(self, *_args, **_kwargs): | |
267 | val = apply(gdic.wxCursor_GetDepth,(self,) + _args, _kwargs) | |
268 | return val | |
269 | def SetWidth(self, *_args, **_kwargs): | |
270 | val = apply(gdic.wxCursor_SetWidth,(self,) + _args, _kwargs) | |
271 | return val | |
272 | def SetHeight(self, *_args, **_kwargs): | |
273 | val = apply(gdic.wxCursor_SetHeight,(self,) + _args, _kwargs) | |
274 | return val | |
275 | def SetDepth(self, *_args, **_kwargs): | |
276 | val = apply(gdic.wxCursor_SetDepth,(self,) + _args, _kwargs) | |
277 | return val | |
278 | def SetSize(self, *_args, **_kwargs): | |
279 | val = apply(gdic.wxCursor_SetSize,(self,) + _args, _kwargs) | |
280 | return val | |
281 | def __repr__(self): | |
282 | return "<C wxCursor instance at %s>" % (self.this,) | |
283 | class wxCursor(wxCursorPtr): | |
284 | def __init__(self,*_args,**_kwargs): | |
285 | self.this = apply(gdic.new_wxCursor,_args,_kwargs) | |
286 | self.thisown = 1 | |
287 | ||
288 | ||
289 | ||
290 | ||
291 | class wxColourPtr(wxObjectPtr): | |
292 | def __init__(self,this): | |
293 | self.this = this | |
294 | self.thisown = 0 | |
295 | def __del__(self, delfunc=gdic.delete_wxColour): | |
296 | if self.thisown == 1: | |
297 | try: | |
298 | delfunc(self) | |
299 | except: | |
300 | pass | |
301 | def Red(self, *_args, **_kwargs): | |
302 | val = apply(gdic.wxColour_Red,(self,) + _args, _kwargs) | |
303 | return val | |
304 | def Green(self, *_args, **_kwargs): | |
305 | val = apply(gdic.wxColour_Green,(self,) + _args, _kwargs) | |
306 | return val | |
307 | def Blue(self, *_args, **_kwargs): | |
308 | val = apply(gdic.wxColour_Blue,(self,) + _args, _kwargs) | |
309 | return val | |
310 | def Ok(self, *_args, **_kwargs): | |
311 | val = apply(gdic.wxColour_Ok,(self,) + _args, _kwargs) | |
312 | return val | |
313 | def Set(self, *_args, **_kwargs): | |
314 | val = apply(gdic.wxColour_Set,(self,) + _args, _kwargs) | |
315 | return val | |
316 | def Get(self, *_args, **_kwargs): | |
317 | val = apply(gdic.wxColour_Get,(self,) + _args, _kwargs) | |
318 | return val | |
319 | def __eq__(self, *_args, **_kwargs): | |
320 | val = apply(gdic.wxColour___eq__,(self,) + _args, _kwargs) | |
321 | return val | |
322 | def __ne__(self, *_args, **_kwargs): | |
323 | val = apply(gdic.wxColour___ne__,(self,) + _args, _kwargs) | |
324 | return val | |
325 | def __repr__(self): | |
326 | return "<C wxColour instance at %s>" % (self.this,) | |
327 | asTuple = Get | |
328 | def __str__(self): return str(self.asTuple()) | |
329 | def __repr__(self): return 'wxColour:' + str(self.asTuple()) | |
330 | def __nonzero__(self): return self.Ok() | |
331 | def __getinitargs__(self): return () | |
332 | def __getstate__(self): return self.asTuple() | |
333 | def __setstate__(self, state): self.Set(*state) | |
334 | ||
335 | class wxColour(wxColourPtr): | |
336 | def __init__(self,*_args,**_kwargs): | |
337 | self.this = apply(gdic.new_wxColour,_args,_kwargs) | |
338 | self.thisown = 1 | |
339 | ||
340 | ||
341 | ||
342 | ||
343 | class wxColourDatabasePtr(wxObjectPtr): | |
344 | def __init__(self,this): | |
345 | self.this = this | |
346 | self.thisown = 0 | |
347 | def FindColour(self, *_args, **_kwargs): | |
348 | val = apply(gdic.wxColourDatabase_FindColour,(self,) + _args, _kwargs) | |
349 | if val: val = wxColourPtr(val) | |
350 | return val | |
351 | def FindName(self, *_args, **_kwargs): | |
352 | val = apply(gdic.wxColourDatabase_FindName,(self,) + _args, _kwargs) | |
353 | return val | |
354 | def Append(self, *_args, **_kwargs): | |
355 | val = apply(gdic.wxColourDatabase_Append,(self,) + _args, _kwargs) | |
356 | return val | |
357 | def __repr__(self): | |
358 | return "<C wxColourDatabase instance at %s>" % (self.this,) | |
359 | class wxColourDatabase(wxColourDatabasePtr): | |
360 | def __init__(self,this): | |
361 | self.this = this | |
362 | ||
363 | ||
364 | ||
365 | ||
366 | class wxPenPtr(wxGDIObjectPtr): | |
367 | def __init__(self,this): | |
368 | self.this = this | |
369 | self.thisown = 0 | |
370 | def __del__(self, delfunc=gdic.delete_wxPen): | |
371 | if self.thisown == 1: | |
372 | try: | |
373 | delfunc(self) | |
374 | except: | |
375 | pass | |
376 | def GetCap(self, *_args, **_kwargs): | |
377 | val = apply(gdic.wxPen_GetCap,(self,) + _args, _kwargs) | |
378 | return val | |
379 | def GetColour(self, *_args, **_kwargs): | |
380 | val = apply(gdic.wxPen_GetColour,(self,) + _args, _kwargs) | |
381 | if val: val = wxColourPtr(val) ; val.thisown = 1 | |
382 | return val | |
383 | def GetJoin(self, *_args, **_kwargs): | |
384 | val = apply(gdic.wxPen_GetJoin,(self,) + _args, _kwargs) | |
385 | return val | |
386 | def GetStyle(self, *_args, **_kwargs): | |
387 | val = apply(gdic.wxPen_GetStyle,(self,) + _args, _kwargs) | |
388 | return val | |
389 | def GetWidth(self, *_args, **_kwargs): | |
390 | val = apply(gdic.wxPen_GetWidth,(self,) + _args, _kwargs) | |
391 | return val | |
392 | def Ok(self, *_args, **_kwargs): | |
393 | val = apply(gdic.wxPen_Ok,(self,) + _args, _kwargs) | |
394 | return val | |
395 | def SetCap(self, *_args, **_kwargs): | |
396 | val = apply(gdic.wxPen_SetCap,(self,) + _args, _kwargs) | |
397 | return val | |
398 | def SetColour(self, *_args, **_kwargs): | |
399 | val = apply(gdic.wxPen_SetColour,(self,) + _args, _kwargs) | |
400 | return val | |
401 | def SetJoin(self, *_args, **_kwargs): | |
402 | val = apply(gdic.wxPen_SetJoin,(self,) + _args, _kwargs) | |
403 | return val | |
404 | def SetStyle(self, *_args, **_kwargs): | |
405 | val = apply(gdic.wxPen_SetStyle,(self,) + _args, _kwargs) | |
406 | return val | |
407 | def SetWidth(self, *_args, **_kwargs): | |
408 | val = apply(gdic.wxPen_SetWidth,(self,) + _args, _kwargs) | |
409 | return val | |
410 | def SetDashes(self, *_args, **_kwargs): | |
411 | val = apply(gdic.wxPen_SetDashes,(self,) + _args, _kwargs) | |
412 | return val | |
413 | def GetDashes(self, *_args, **_kwargs): | |
414 | val = apply(gdic.wxPen_GetDashes,(self,) + _args, _kwargs) | |
415 | return val | |
416 | def GetStipple(self, *_args, **_kwargs): | |
417 | val = apply(gdic.wxPen_GetStipple,(self,) + _args, _kwargs) | |
418 | if val: val = wxBitmapPtr(val) | |
419 | return val | |
420 | def SetStipple(self, *_args, **_kwargs): | |
421 | val = apply(gdic.wxPen_SetStipple,(self,) + _args, _kwargs) | |
422 | return val | |
423 | def __repr__(self): | |
424 | return "<C wxPen instance at %s>" % (self.this,) | |
425 | class wxPen(wxPenPtr): | |
426 | def __init__(self,*_args,**_kwargs): | |
427 | self.this = apply(gdic.new_wxPen,_args,_kwargs) | |
428 | self.thisown = 1 | |
429 | ||
430 | ||
431 | ||
432 | ||
433 | class wxPyPenPtr(wxPenPtr): | |
434 | def __init__(self,this): | |
435 | self.this = this | |
436 | self.thisown = 0 | |
437 | def __del__(self, delfunc=gdic.delete_wxPyPen): | |
438 | if self.thisown == 1: | |
439 | try: | |
440 | delfunc(self) | |
441 | except: | |
442 | pass | |
443 | def SetDashes(self, *_args, **_kwargs): | |
444 | val = apply(gdic.wxPyPen_SetDashes,(self,) + _args, _kwargs) | |
445 | return val | |
446 | def __repr__(self): | |
447 | return "<C wxPyPen instance at %s>" % (self.this,) | |
448 | class wxPyPen(wxPyPenPtr): | |
449 | def __init__(self,*_args,**_kwargs): | |
450 | self.this = apply(gdic.new_wxPyPen,_args,_kwargs) | |
451 | self.thisown = 1 | |
452 | ||
453 | ||
454 | ||
455 | ||
456 | class wxPenListPtr(wxObjectPtr): | |
457 | def __init__(self,this): | |
458 | self.this = this | |
459 | self.thisown = 0 | |
460 | def AddPen(self, *_args, **_kwargs): | |
461 | val = apply(gdic.wxPenList_AddPen,(self,) + _args, _kwargs) | |
462 | return val | |
463 | def FindOrCreatePen(self, *_args, **_kwargs): | |
464 | val = apply(gdic.wxPenList_FindOrCreatePen,(self,) + _args, _kwargs) | |
465 | if val: val = wxPenPtr(val) | |
466 | return val | |
467 | def RemovePen(self, *_args, **_kwargs): | |
468 | val = apply(gdic.wxPenList_RemovePen,(self,) + _args, _kwargs) | |
469 | return val | |
470 | def GetCount(self, *_args, **_kwargs): | |
471 | val = apply(gdic.wxPenList_GetCount,(self,) + _args, _kwargs) | |
472 | return val | |
473 | def __repr__(self): | |
474 | return "<C wxPenList instance at %s>" % (self.this,) | |
475 | class wxPenList(wxPenListPtr): | |
476 | def __init__(self,this): | |
477 | self.this = this | |
478 | ||
479 | ||
480 | ||
481 | ||
482 | class wxBrushPtr(wxGDIObjectPtr): | |
483 | def __init__(self,this): | |
484 | self.this = this | |
485 | self.thisown = 0 | |
486 | def __del__(self, delfunc=gdic.delete_wxBrush): | |
487 | if self.thisown == 1: | |
488 | try: | |
489 | delfunc(self) | |
490 | except: | |
491 | pass | |
492 | def GetColour(self, *_args, **_kwargs): | |
493 | val = apply(gdic.wxBrush_GetColour,(self,) + _args, _kwargs) | |
494 | if val: val = wxColourPtr(val) ; val.thisown = 1 | |
495 | return val | |
496 | def GetStipple(self, *_args, **_kwargs): | |
497 | val = apply(gdic.wxBrush_GetStipple,(self,) + _args, _kwargs) | |
498 | if val: val = wxBitmapPtr(val) | |
499 | return val | |
500 | def GetStyle(self, *_args, **_kwargs): | |
501 | val = apply(gdic.wxBrush_GetStyle,(self,) + _args, _kwargs) | |
502 | return val | |
503 | def Ok(self, *_args, **_kwargs): | |
504 | val = apply(gdic.wxBrush_Ok,(self,) + _args, _kwargs) | |
505 | return val | |
506 | def SetColour(self, *_args, **_kwargs): | |
507 | val = apply(gdic.wxBrush_SetColour,(self,) + _args, _kwargs) | |
508 | return val | |
509 | def SetStipple(self, *_args, **_kwargs): | |
510 | val = apply(gdic.wxBrush_SetStipple,(self,) + _args, _kwargs) | |
511 | return val | |
512 | def SetStyle(self, *_args, **_kwargs): | |
513 | val = apply(gdic.wxBrush_SetStyle,(self,) + _args, _kwargs) | |
514 | return val | |
515 | def __repr__(self): | |
516 | return "<C wxBrush instance at %s>" % (self.this,) | |
517 | class wxBrush(wxBrushPtr): | |
518 | def __init__(self,*_args,**_kwargs): | |
519 | self.this = apply(gdic.new_wxBrush,_args,_kwargs) | |
520 | self.thisown = 1 | |
521 | ||
522 | ||
523 | ||
524 | ||
525 | class wxBrushListPtr(wxObjectPtr): | |
526 | def __init__(self,this): | |
527 | self.this = this | |
528 | self.thisown = 0 | |
529 | def AddBrush(self, *_args, **_kwargs): | |
530 | val = apply(gdic.wxBrushList_AddBrush,(self,) + _args, _kwargs) | |
531 | return val | |
532 | def FindOrCreateBrush(self, *_args, **_kwargs): | |
533 | val = apply(gdic.wxBrushList_FindOrCreateBrush,(self,) + _args, _kwargs) | |
534 | if val: val = wxBrushPtr(val) | |
535 | return val | |
536 | def RemoveBrush(self, *_args, **_kwargs): | |
537 | val = apply(gdic.wxBrushList_RemoveBrush,(self,) + _args, _kwargs) | |
538 | return val | |
539 | def GetCount(self, *_args, **_kwargs): | |
540 | val = apply(gdic.wxBrushList_GetCount,(self,) + _args, _kwargs) | |
541 | return val | |
542 | def __repr__(self): | |
543 | return "<C wxBrushList instance at %s>" % (self.this,) | |
544 | class wxBrushList(wxBrushListPtr): | |
545 | def __init__(self,this): | |
546 | self.this = this | |
547 | ||
548 | ||
549 | ||
550 | ||
551 | class wxDCPtr(wxObjectPtr): | |
552 | def __init__(self,this): | |
553 | self.this = this | |
554 | self.thisown = 0 | |
555 | def __del__(self, delfunc=gdic.delete_wxDC): | |
556 | if self.thisown == 1: | |
557 | try: | |
558 | delfunc(self) | |
559 | except: | |
560 | pass | |
561 | def BeginDrawing(self, *_args, **_kwargs): | |
562 | val = apply(gdic.wxDC_BeginDrawing,(self,) + _args, _kwargs) | |
563 | return val | |
564 | def Blit(self, *_args, **_kwargs): | |
565 | val = apply(gdic.wxDC_Blit,(self,) + _args, _kwargs) | |
566 | return val | |
567 | def Clear(self, *_args, **_kwargs): | |
568 | val = apply(gdic.wxDC_Clear,(self,) + _args, _kwargs) | |
569 | return val | |
570 | def CrossHair(self, *_args, **_kwargs): | |
571 | val = apply(gdic.wxDC_CrossHair,(self,) + _args, _kwargs) | |
572 | return val | |
573 | def DestroyClippingRegion(self, *_args, **_kwargs): | |
574 | val = apply(gdic.wxDC_DestroyClippingRegion,(self,) + _args, _kwargs) | |
575 | return val | |
576 | def DeviceToLogicalX(self, *_args, **_kwargs): | |
577 | val = apply(gdic.wxDC_DeviceToLogicalX,(self,) + _args, _kwargs) | |
578 | return val | |
579 | def DeviceToLogicalXRel(self, *_args, **_kwargs): | |
580 | val = apply(gdic.wxDC_DeviceToLogicalXRel,(self,) + _args, _kwargs) | |
581 | return val | |
582 | def DeviceToLogicalY(self, *_args, **_kwargs): | |
583 | val = apply(gdic.wxDC_DeviceToLogicalY,(self,) + _args, _kwargs) | |
584 | return val | |
585 | def DeviceToLogicalYRel(self, *_args, **_kwargs): | |
586 | val = apply(gdic.wxDC_DeviceToLogicalYRel,(self,) + _args, _kwargs) | |
587 | return val | |
588 | def DrawArc(self, *_args, **_kwargs): | |
589 | val = apply(gdic.wxDC_DrawArc,(self,) + _args, _kwargs) | |
590 | return val | |
591 | def DrawCircle(self, *_args, **_kwargs): | |
592 | val = apply(gdic.wxDC_DrawCircle,(self,) + _args, _kwargs) | |
593 | return val | |
594 | def DrawEllipse(self, *_args, **_kwargs): | |
595 | val = apply(gdic.wxDC_DrawEllipse,(self,) + _args, _kwargs) | |
596 | return val | |
597 | def DrawEllipticArc(self, *_args, **_kwargs): | |
598 | val = apply(gdic.wxDC_DrawEllipticArc,(self,) + _args, _kwargs) | |
599 | return val | |
600 | def DrawIcon(self, *_args, **_kwargs): | |
601 | val = apply(gdic.wxDC_DrawIcon,(self,) + _args, _kwargs) | |
602 | return val | |
603 | def DrawLabel(self, *_args, **_kwargs): | |
604 | val = apply(gdic.wxDC_DrawLabel,(self,) + _args, _kwargs) | |
605 | return val | |
606 | def DrawImageLabel(self, *_args, **_kwargs): | |
607 | val = apply(gdic.wxDC_DrawImageLabel,(self,) + _args, _kwargs) | |
608 | if val: val = wxRectPtr(val) ; val.thisown = 1 | |
609 | return val | |
610 | def DrawLine(self, *_args, **_kwargs): | |
611 | val = apply(gdic.wxDC_DrawLine,(self,) + _args, _kwargs) | |
612 | return val | |
613 | def DrawLines(self, *_args, **_kwargs): | |
614 | val = apply(gdic.wxDC_DrawLines,(self,) + _args, _kwargs) | |
615 | return val | |
616 | def DrawPolygon(self, *_args, **_kwargs): | |
617 | val = apply(gdic.wxDC_DrawPolygon,(self,) + _args, _kwargs) | |
618 | return val | |
619 | def DrawPoint(self, *_args, **_kwargs): | |
620 | val = apply(gdic.wxDC_DrawPoint,(self,) + _args, _kwargs) | |
621 | return val | |
622 | def DrawRectangle(self, *_args, **_kwargs): | |
623 | val = apply(gdic.wxDC_DrawRectangle,(self,) + _args, _kwargs) | |
624 | return val | |
625 | def DrawRectangleRect(self, *_args, **_kwargs): | |
626 | val = apply(gdic.wxDC_DrawRectangleRect,(self,) + _args, _kwargs) | |
627 | return val | |
628 | def DrawRotatedText(self, *_args, **_kwargs): | |
629 | val = apply(gdic.wxDC_DrawRotatedText,(self,) + _args, _kwargs) | |
630 | return val | |
631 | def DrawRoundedRectangle(self, *_args, **_kwargs): | |
632 | val = apply(gdic.wxDC_DrawRoundedRectangle,(self,) + _args, _kwargs) | |
633 | return val | |
634 | def DrawSpline(self, *_args, **_kwargs): | |
635 | val = apply(gdic.wxDC_DrawSpline,(self,) + _args, _kwargs) | |
636 | return val | |
637 | def DrawText(self, *_args, **_kwargs): | |
638 | val = apply(gdic.wxDC_DrawText,(self,) + _args, _kwargs) | |
639 | return val | |
640 | def EndDoc(self, *_args, **_kwargs): | |
641 | val = apply(gdic.wxDC_EndDoc,(self,) + _args, _kwargs) | |
642 | return val | |
643 | def EndDrawing(self, *_args, **_kwargs): | |
644 | val = apply(gdic.wxDC_EndDrawing,(self,) + _args, _kwargs) | |
645 | return val | |
646 | def EndPage(self, *_args, **_kwargs): | |
647 | val = apply(gdic.wxDC_EndPage,(self,) + _args, _kwargs) | |
648 | return val | |
649 | def FloodFill(self, *_args, **_kwargs): | |
650 | val = apply(gdic.wxDC_FloodFill,(self,) + _args, _kwargs) | |
651 | return val | |
652 | def GetBackground(self, *_args, **_kwargs): | |
653 | val = apply(gdic.wxDC_GetBackground,(self,) + _args, _kwargs) | |
654 | if val: val = wxBrushPtr(val) ; val.thisown = 1 | |
655 | return val | |
656 | def GetBrush(self, *_args, **_kwargs): | |
657 | val = apply(gdic.wxDC_GetBrush,(self,) + _args, _kwargs) | |
658 | if val: val = wxBrushPtr(val) ; val.thisown = 1 | |
659 | return val | |
660 | def GetCharHeight(self, *_args, **_kwargs): | |
661 | val = apply(gdic.wxDC_GetCharHeight,(self,) + _args, _kwargs) | |
662 | return val | |
663 | def GetCharWidth(self, *_args, **_kwargs): | |
664 | val = apply(gdic.wxDC_GetCharWidth,(self,) + _args, _kwargs) | |
665 | return val | |
666 | def GetClippingBox(self, *_args, **_kwargs): | |
667 | val = apply(gdic.wxDC_GetClippingBox,(self,) + _args, _kwargs) | |
668 | return val | |
669 | def GetFont(self, *_args, **_kwargs): | |
670 | val = apply(gdic.wxDC_GetFont,(self,) + _args, _kwargs) | |
671 | if val: val = wxFontPtr(val) ; val.thisown = 1 | |
672 | return val | |
673 | def GetLogicalFunction(self, *_args, **_kwargs): | |
674 | val = apply(gdic.wxDC_GetLogicalFunction,(self,) + _args, _kwargs) | |
675 | return val | |
676 | def GetLogicalScale(self, *_args, **_kwargs): | |
677 | val = apply(gdic.wxDC_GetLogicalScale,(self,) + _args, _kwargs) | |
678 | return val | |
679 | def GetMapMode(self, *_args, **_kwargs): | |
680 | val = apply(gdic.wxDC_GetMapMode,(self,) + _args, _kwargs) | |
681 | return val | |
682 | def GetOptimization(self, *_args, **_kwargs): | |
683 | val = apply(gdic.wxDC_GetOptimization,(self,) + _args, _kwargs) | |
684 | return val | |
685 | def GetPen(self, *_args, **_kwargs): | |
686 | val = apply(gdic.wxDC_GetPen,(self,) + _args, _kwargs) | |
687 | if val: val = wxPenPtr(val) ; val.thisown = 1 | |
688 | return val | |
689 | def GetPixel(self, *_args, **_kwargs): | |
690 | val = apply(gdic.wxDC_GetPixel,(self,) + _args, _kwargs) | |
691 | if val: val = wxColourPtr(val) ; val.thisown = 1 | |
692 | return val | |
693 | def GetSizeTuple(self, *_args, **_kwargs): | |
694 | val = apply(gdic.wxDC_GetSizeTuple,(self,) + _args, _kwargs) | |
695 | return val | |
696 | def GetSize(self, *_args, **_kwargs): | |
697 | val = apply(gdic.wxDC_GetSize,(self,) + _args, _kwargs) | |
698 | if val: val = wxSizePtr(val) ; val.thisown = 1 | |
699 | return val | |
700 | def GetSizeMM(self, *_args, **_kwargs): | |
701 | val = apply(gdic.wxDC_GetSizeMM,(self,) + _args, _kwargs) | |
702 | if val: val = wxSizePtr(val) ; val.thisown = 1 | |
703 | return val | |
704 | def GetTextBackground(self, *_args, **_kwargs): | |
705 | val = apply(gdic.wxDC_GetTextBackground,(self,) + _args, _kwargs) | |
706 | if val: val = wxColourPtr(val) ; val.thisown = 1 | |
707 | return val | |
708 | def GetTextExtent(self, *_args, **_kwargs): | |
709 | val = apply(gdic.wxDC_GetTextExtent,(self,) + _args, _kwargs) | |
710 | return val | |
711 | def GetFullTextExtent(self, *_args, **_kwargs): | |
712 | val = apply(gdic.wxDC_GetFullTextExtent,(self,) + _args, _kwargs) | |
713 | return val | |
714 | def GetMultiLineTextExtent(self, *_args, **_kwargs): | |
715 | val = apply(gdic.wxDC_GetMultiLineTextExtent,(self,) + _args, _kwargs) | |
716 | return val | |
717 | def GetTextForeground(self, *_args, **_kwargs): | |
718 | val = apply(gdic.wxDC_GetTextForeground,(self,) + _args, _kwargs) | |
719 | if val: val = wxColourPtr(val) ; val.thisown = 1 | |
720 | return val | |
721 | def GetUserScale(self, *_args, **_kwargs): | |
722 | val = apply(gdic.wxDC_GetUserScale,(self,) + _args, _kwargs) | |
723 | return val | |
724 | def LogicalToDeviceX(self, *_args, **_kwargs): | |
725 | val = apply(gdic.wxDC_LogicalToDeviceX,(self,) + _args, _kwargs) | |
726 | return val | |
727 | def LogicalToDeviceXRel(self, *_args, **_kwargs): | |
728 | val = apply(gdic.wxDC_LogicalToDeviceXRel,(self,) + _args, _kwargs) | |
729 | return val | |
730 | def LogicalToDeviceY(self, *_args, **_kwargs): | |
731 | val = apply(gdic.wxDC_LogicalToDeviceY,(self,) + _args, _kwargs) | |
732 | return val | |
733 | def LogicalToDeviceYRel(self, *_args, **_kwargs): | |
734 | val = apply(gdic.wxDC_LogicalToDeviceYRel,(self,) + _args, _kwargs) | |
735 | return val | |
736 | def MaxX(self, *_args, **_kwargs): | |
737 | val = apply(gdic.wxDC_MaxX,(self,) + _args, _kwargs) | |
738 | return val | |
739 | def MaxY(self, *_args, **_kwargs): | |
740 | val = apply(gdic.wxDC_MaxY,(self,) + _args, _kwargs) | |
741 | return val | |
742 | def MinX(self, *_args, **_kwargs): | |
743 | val = apply(gdic.wxDC_MinX,(self,) + _args, _kwargs) | |
744 | return val | |
745 | def MinY(self, *_args, **_kwargs): | |
746 | val = apply(gdic.wxDC_MinY,(self,) + _args, _kwargs) | |
747 | return val | |
748 | def Ok(self, *_args, **_kwargs): | |
749 | val = apply(gdic.wxDC_Ok,(self,) + _args, _kwargs) | |
750 | return val | |
751 | def SetDeviceOrigin(self, *_args, **_kwargs): | |
752 | val = apply(gdic.wxDC_SetDeviceOrigin,(self,) + _args, _kwargs) | |
753 | return val | |
754 | def SetBackground(self, *_args, **_kwargs): | |
755 | val = apply(gdic.wxDC_SetBackground,(self,) + _args, _kwargs) | |
756 | return val | |
757 | def SetBackgroundMode(self, *_args, **_kwargs): | |
758 | val = apply(gdic.wxDC_SetBackgroundMode,(self,) + _args, _kwargs) | |
759 | return val | |
760 | def SetClippingRegion(self, *_args, **_kwargs): | |
761 | val = apply(gdic.wxDC_SetClippingRegion,(self,) + _args, _kwargs) | |
762 | return val | |
763 | def SetClippingRegionAsRegion(self, *_args, **_kwargs): | |
764 | val = apply(gdic.wxDC_SetClippingRegionAsRegion,(self,) + _args, _kwargs) | |
765 | return val | |
766 | def SetClippingRect(self, *_args, **_kwargs): | |
767 | val = apply(gdic.wxDC_SetClippingRect,(self,) + _args, _kwargs) | |
768 | return val | |
769 | def SetPalette(self, *_args, **_kwargs): | |
770 | val = apply(gdic.wxDC_SetPalette,(self,) + _args, _kwargs) | |
771 | return val | |
772 | def SetBrush(self, *_args, **_kwargs): | |
773 | val = apply(gdic.wxDC_SetBrush,(self,) + _args, _kwargs) | |
774 | return val | |
775 | def SetFont(self, *_args, **_kwargs): | |
776 | val = apply(gdic.wxDC_SetFont,(self,) + _args, _kwargs) | |
777 | return val | |
778 | def SetLogicalFunction(self, *_args, **_kwargs): | |
779 | val = apply(gdic.wxDC_SetLogicalFunction,(self,) + _args, _kwargs) | |
780 | return val | |
781 | def SetLogicalScale(self, *_args, **_kwargs): | |
782 | val = apply(gdic.wxDC_SetLogicalScale,(self,) + _args, _kwargs) | |
783 | return val | |
784 | def SetMapMode(self, *_args, **_kwargs): | |
785 | val = apply(gdic.wxDC_SetMapMode,(self,) + _args, _kwargs) | |
786 | return val | |
787 | def SetOptimization(self, *_args, **_kwargs): | |
788 | val = apply(gdic.wxDC_SetOptimization,(self,) + _args, _kwargs) | |
789 | return val | |
790 | def SetPen(self, *_args, **_kwargs): | |
791 | val = apply(gdic.wxDC_SetPen,(self,) + _args, _kwargs) | |
792 | return val | |
793 | def SetTextBackground(self, *_args, **_kwargs): | |
794 | val = apply(gdic.wxDC_SetTextBackground,(self,) + _args, _kwargs) | |
795 | return val | |
796 | def SetTextForeground(self, *_args, **_kwargs): | |
797 | val = apply(gdic.wxDC_SetTextForeground,(self,) + _args, _kwargs) | |
798 | return val | |
799 | def SetUserScale(self, *_args, **_kwargs): | |
800 | val = apply(gdic.wxDC_SetUserScale,(self,) + _args, _kwargs) | |
801 | return val | |
802 | def StartDoc(self, *_args, **_kwargs): | |
803 | val = apply(gdic.wxDC_StartDoc,(self,) + _args, _kwargs) | |
804 | return val | |
805 | def StartPage(self, *_args, **_kwargs): | |
806 | val = apply(gdic.wxDC_StartPage,(self,) + _args, _kwargs) | |
807 | return val | |
808 | def DrawBitmap(self, *_args, **_kwargs): | |
809 | val = apply(gdic.wxDC_DrawBitmap,(self,) + _args, _kwargs) | |
810 | return val | |
811 | def CanDrawBitmap(self, *_args, **_kwargs): | |
812 | val = apply(gdic.wxDC_CanDrawBitmap,(self,) + _args, _kwargs) | |
813 | return val | |
814 | def CanGetTextExtent(self, *_args, **_kwargs): | |
815 | val = apply(gdic.wxDC_CanGetTextExtent,(self,) + _args, _kwargs) | |
816 | return val | |
817 | def GetDepth(self, *_args, **_kwargs): | |
818 | val = apply(gdic.wxDC_GetDepth,(self,) + _args, _kwargs) | |
819 | return val | |
820 | def GetPPI(self, *_args, **_kwargs): | |
821 | val = apply(gdic.wxDC_GetPPI,(self,) + _args, _kwargs) | |
822 | if val: val = wxSizePtr(val) ; val.thisown = 1 | |
823 | return val | |
824 | def GetLogicalOrigin(self, *_args, **_kwargs): | |
825 | val = apply(gdic.wxDC_GetLogicalOrigin,(self,) + _args, _kwargs) | |
826 | return val | |
827 | def SetLogicalOrigin(self, *_args, **_kwargs): | |
828 | val = apply(gdic.wxDC_SetLogicalOrigin,(self,) + _args, _kwargs) | |
829 | return val | |
830 | def GetDeviceOrigin(self, *_args, **_kwargs): | |
831 | val = apply(gdic.wxDC_GetDeviceOrigin,(self,) + _args, _kwargs) | |
832 | return val | |
833 | def SetAxisOrientation(self, *_args, **_kwargs): | |
834 | val = apply(gdic.wxDC_SetAxisOrientation,(self,) + _args, _kwargs) | |
835 | return val | |
836 | def CalcBoundingBox(self, *_args, **_kwargs): | |
837 | val = apply(gdic.wxDC_CalcBoundingBox,(self,) + _args, _kwargs) | |
838 | return val | |
839 | def ResetBoundingBox(self, *_args, **_kwargs): | |
840 | val = apply(gdic.wxDC_ResetBoundingBox,(self,) + _args, _kwargs) | |
841 | return val | |
842 | def GetBoundingBox(self, *_args, **_kwargs): | |
843 | val = apply(gdic.wxDC_GetBoundingBox,(self,) + _args, _kwargs) | |
844 | return val | |
845 | def GetHDC(self, *_args, **_kwargs): | |
846 | val = apply(gdic.wxDC_GetHDC,(self,) + _args, _kwargs) | |
847 | return val | |
848 | def _DrawPointList(self, *_args, **_kwargs): | |
849 | val = apply(gdic.wxDC__DrawPointList,(self,) + _args, _kwargs) | |
850 | return val | |
851 | def _DrawLineList(self, *_args, **_kwargs): | |
852 | val = apply(gdic.wxDC__DrawLineList,(self,) + _args, _kwargs) | |
853 | return val | |
854 | def _DrawRectangleList(self, *_args, **_kwargs): | |
855 | val = apply(gdic.wxDC__DrawRectangleList,(self,) + _args, _kwargs) | |
856 | return val | |
857 | def _DrawEllipseList(self, *_args, **_kwargs): | |
858 | val = apply(gdic.wxDC__DrawEllipseList,(self,) + _args, _kwargs) | |
859 | return val | |
860 | def _DrawPolygonList(self, *_args, **_kwargs): | |
861 | val = apply(gdic.wxDC__DrawPolygonList,(self,) + _args, _kwargs) | |
862 | return val | |
863 | def _DrawTextList(self, *_args, **_kwargs): | |
864 | val = apply(gdic.wxDC__DrawTextList,(self,) + _args, _kwargs) | |
865 | return val | |
866 | def __repr__(self): | |
867 | return "<C wxDC instance at %s>" % (self.this,) | |
868 | ||
869 | def DrawPointList(self, points, pens=None): | |
870 | if pens is None: | |
871 | pens = [] | |
872 | elif isinstance(pens, wxPenPtr): | |
873 | pens = [pens] | |
874 | elif len(pens) != len(points): | |
875 | raise ValueError('points and pens must have same length') | |
876 | return self._DrawPointList(points, pens, []) | |
877 | ||
878 | ||
879 | def DrawLineList(self, lines, pens=None): | |
880 | if pens is None: | |
881 | pens = [] | |
882 | elif isinstance(pens, wxPenPtr): | |
883 | pens = [pens] | |
884 | elif len(pens) != len(lines): | |
885 | raise ValueError('lines and pens must have same length') | |
886 | return self._DrawLineList(lines, pens, []) | |
887 | ||
888 | ||
889 | def DrawRectangleList(self, rectangles, pens=None, brushes=None): | |
890 | if pens is None: | |
891 | pens = [] | |
892 | elif isinstance(pens, wxPenPtr): | |
893 | pens = [pens] | |
894 | elif len(pens) != len(rectangles): | |
895 | raise ValueError('rectangles and pens must have same length') | |
896 | if brushes is None: | |
897 | brushes = [] | |
898 | elif isinstance(brushes, wxBrushPtr): | |
899 | brushes = [brushes] | |
900 | elif len(brushes) != len(rectangles): | |
901 | raise ValueError('rectangles and brushes must have same length') | |
902 | return self._DrawRectangleList(rectangles, pens, brushes) | |
903 | ||
904 | ||
905 | def DrawEllipseList(self, ellipses, pens=None, brushes=None): | |
906 | if pens is None: | |
907 | pens = [] | |
908 | elif isinstance(pens, wxPenPtr): | |
909 | pens = [pens] | |
910 | elif len(pens) != len(ellipses): | |
911 | raise ValueError('ellipses and pens must have same length') | |
912 | if brushes is None: | |
913 | brushes = [] | |
914 | elif isinstance(brushes, wxBrushPtr): | |
915 | brushes = [brushes] | |
916 | elif len(brushes) != len(ellipses): | |
917 | raise ValueError('ellipses and brushes must have same length') | |
918 | return self._DrawEllipseList(ellipses, pens, brushes) | |
919 | ||
920 | ||
921 | def DrawPolygonList(self, polygons, pens=None, brushes=None): | |
922 | ## Note: This does not currently support fill style or offset | |
923 | ## you can always use the non-List version if need be. | |
924 | ## I really would like to support fill-style, however, | |
925 | ## but wxODDEVEN_RULE does not appear to be defined at the Python level | |
926 | ## [It's in wx.py... --Robin] | |
927 | if pens is None: | |
928 | pens = [] | |
929 | elif isinstance(pens, wxPenPtr): | |
930 | pens = [pens] | |
931 | elif len(pens) != len(polygons): | |
932 | raise ValueError('polygons and pens must have same length') | |
933 | if brushes is None: | |
934 | brushes = [] | |
935 | elif isinstance(brushes, wxBrushPtr): | |
936 | brushes = [brushes] | |
937 | elif len(brushes) != len(polygons): | |
938 | raise ValueError('polygons and brushes must have same length') | |
939 | return self._DrawPolygonList(polygons, pens, brushes) | |
940 | ||
941 | ||
942 | def DrawTextList(self, textList, coords, foregrounds = None, backgrounds = None, fonts = None): | |
943 | ## NOTE: this does not currently support changing the font | |
944 | ## Make sure you set Background mode to wxSolid (DC.SetBackgroundMode) | |
945 | ## If you want backgounds to do anything. | |
946 | if type(textList) == type(''): | |
947 | textList = [textList] | |
948 | elif len(textList) != len(coords): | |
949 | raise ValueError('textlist and coords must have same length') | |
950 | if foregrounds is None: | |
951 | foregrounds = [] | |
952 | elif isinstance(foregrounds, wxColourPtr): | |
953 | foregrounds = [foregrounds] | |
954 | elif len(foregrounds) != len(coords): | |
955 | raise ValueError('foregrounds and coords must have same length') | |
956 | if backgrounds is None: | |
957 | backgrounds = [] | |
958 | elif isinstance(backgrounds, wxColourPtr): | |
959 | backgrounds = [backgrounds] | |
960 | elif len(backgrounds) != len(coords): | |
961 | raise ValueError('backgrounds and coords must have same length') | |
962 | return self._DrawTextList(textList, coords, foregrounds, backgrounds) | |
963 | ||
964 | class wxDC(wxDCPtr): | |
965 | def __init__(self,this): | |
966 | self.this = this | |
967 | ||
968 | ||
969 | ||
970 | ||
971 | class wxMemoryDCPtr(wxDCPtr): | |
972 | def __init__(self,this): | |
973 | self.this = this | |
974 | self.thisown = 0 | |
975 | def SelectObject(self, *_args, **_kwargs): | |
976 | val = apply(gdic.wxMemoryDC_SelectObject,(self,) + _args, _kwargs) | |
977 | return val | |
978 | def __repr__(self): | |
979 | return "<C wxMemoryDC instance at %s>" % (self.this,) | |
980 | class wxMemoryDC(wxMemoryDCPtr): | |
981 | def __init__(self,*_args,**_kwargs): | |
982 | self.this = apply(gdic.new_wxMemoryDC,_args,_kwargs) | |
983 | self.thisown = 1 | |
984 | ||
985 | ||
986 | ||
987 | ||
988 | class wxBufferedDCPtr(wxMemoryDCPtr): | |
989 | def __init__(self,this): | |
990 | self.this = this | |
991 | self.thisown = 0 | |
992 | def UnMask(self, *_args, **_kwargs): | |
993 | val = apply(gdic.wxBufferedDC_UnMask,(self,) + _args, _kwargs) | |
994 | return val | |
995 | def __repr__(self): | |
996 | return "<C wxBufferedDC instance at %s>" % (self.this,) | |
997 | class wxBufferedDC(wxBufferedDCPtr): | |
998 | def __init__(self,*_args,**_kwargs): | |
999 | self.this = apply(gdic.new_wxBufferedDC,_args,_kwargs) | |
1000 | self.thisown = 1 | |
1001 | self._dc = _args[0] # save a ref so the other dc won't be deleted before self | |
1002 | ||
1003 | ||
1004 | ||
1005 | def wxBufferedDCInternalBuffer(*_args,**_kwargs): | |
1006 | val = wxBufferedDCPtr(apply(gdic.new_wxBufferedDCInternalBuffer,_args,_kwargs)) | |
1007 | val.thisown = 1 | |
1008 | val._dc = _args[0] # save a ref so the other dc won't be deleted before self | |
1009 | return val | |
1010 | ||
1011 | ||
1012 | class wxBufferedPaintDCPtr(wxBufferedDCPtr): | |
1013 | def __init__(self,this): | |
1014 | self.this = this | |
1015 | self.thisown = 0 | |
1016 | def __repr__(self): | |
1017 | return "<C wxBufferedPaintDC instance at %s>" % (self.this,) | |
1018 | class wxBufferedPaintDC(wxBufferedPaintDCPtr): | |
1019 | def __init__(self,*_args,**_kwargs): | |
1020 | self.this = apply(gdic.new_wxBufferedPaintDC,_args,_kwargs) | |
1021 | self.thisown = 1 | |
1022 | ||
1023 | ||
1024 | ||
1025 | ||
1026 | class wxScreenDCPtr(wxDCPtr): | |
1027 | def __init__(self,this): | |
1028 | self.this = this | |
1029 | self.thisown = 0 | |
1030 | def StartDrawingOnTopWin(self, *_args, **_kwargs): | |
1031 | val = apply(gdic.wxScreenDC_StartDrawingOnTopWin,(self,) + _args, _kwargs) | |
1032 | return val | |
1033 | def StartDrawingOnTop(self, *_args, **_kwargs): | |
1034 | val = apply(gdic.wxScreenDC_StartDrawingOnTop,(self,) + _args, _kwargs) | |
1035 | return val | |
1036 | def EndDrawingOnTop(self, *_args, **_kwargs): | |
1037 | val = apply(gdic.wxScreenDC_EndDrawingOnTop,(self,) + _args, _kwargs) | |
1038 | return val | |
1039 | def __repr__(self): | |
1040 | return "<C wxScreenDC instance at %s>" % (self.this,) | |
1041 | class wxScreenDC(wxScreenDCPtr): | |
1042 | def __init__(self,*_args,**_kwargs): | |
1043 | self.this = apply(gdic.new_wxScreenDC,_args,_kwargs) | |
1044 | self.thisown = 1 | |
1045 | ||
1046 | ||
1047 | ||
1048 | ||
1049 | class wxClientDCPtr(wxDCPtr): | |
1050 | def __init__(self,this): | |
1051 | self.this = this | |
1052 | self.thisown = 0 | |
1053 | def __repr__(self): | |
1054 | return "<C wxClientDC instance at %s>" % (self.this,) | |
1055 | class wxClientDC(wxClientDCPtr): | |
1056 | def __init__(self,*_args,**_kwargs): | |
1057 | self.this = apply(gdic.new_wxClientDC,_args,_kwargs) | |
1058 | self.thisown = 1 | |
1059 | ||
1060 | ||
1061 | ||
1062 | ||
1063 | class wxPaintDCPtr(wxDCPtr): | |
1064 | def __init__(self,this): | |
1065 | self.this = this | |
1066 | self.thisown = 0 | |
1067 | def __repr__(self): | |
1068 | return "<C wxPaintDC instance at %s>" % (self.this,) | |
1069 | class wxPaintDC(wxPaintDCPtr): | |
1070 | def __init__(self,*_args,**_kwargs): | |
1071 | self.this = apply(gdic.new_wxPaintDC,_args,_kwargs) | |
1072 | self.thisown = 1 | |
1073 | ||
1074 | ||
1075 | ||
1076 | ||
1077 | class wxWindowDCPtr(wxDCPtr): | |
1078 | def __init__(self,this): | |
1079 | self.this = this | |
1080 | self.thisown = 0 | |
1081 | def __repr__(self): | |
1082 | return "<C wxWindowDC instance at %s>" % (self.this,) | |
1083 | class wxWindowDC(wxWindowDCPtr): | |
1084 | def __init__(self,*_args,**_kwargs): | |
1085 | self.this = apply(gdic.new_wxWindowDC,_args,_kwargs) | |
1086 | self.thisown = 1 | |
1087 | ||
1088 | ||
1089 | ||
1090 | ||
1091 | class wxMetaFilePtr(wxObjectPtr): | |
1092 | def __init__(self,this): | |
1093 | self.this = this | |
1094 | self.thisown = 0 | |
1095 | def __del__(self, delfunc=gdic.delete_wxMetaFile): | |
1096 | if self.thisown == 1: | |
1097 | try: | |
1098 | delfunc(self) | |
1099 | except: | |
1100 | pass | |
1101 | def Ok(self, *_args, **_kwargs): | |
1102 | val = apply(gdic.wxMetaFile_Ok,(self,) + _args, _kwargs) | |
1103 | return val | |
1104 | def SetClipboard(self, *_args, **_kwargs): | |
1105 | val = apply(gdic.wxMetaFile_SetClipboard,(self,) + _args, _kwargs) | |
1106 | return val | |
1107 | def GetSize(self, *_args, **_kwargs): | |
1108 | val = apply(gdic.wxMetaFile_GetSize,(self,) + _args, _kwargs) | |
1109 | if val: val = wxSizePtr(val) ; val.thisown = 1 | |
1110 | return val | |
1111 | def GetWidth(self, *_args, **_kwargs): | |
1112 | val = apply(gdic.wxMetaFile_GetWidth,(self,) + _args, _kwargs) | |
1113 | return val | |
1114 | def GetHeight(self, *_args, **_kwargs): | |
1115 | val = apply(gdic.wxMetaFile_GetHeight,(self,) + _args, _kwargs) | |
1116 | return val | |
1117 | def GetFileName(self, *_args, **_kwargs): | |
1118 | val = apply(gdic.wxMetaFile_GetFileName,(self,) + _args, _kwargs) | |
1119 | return val | |
1120 | def __repr__(self): | |
1121 | return "<C wxMetaFile instance at %s>" % (self.this,) | |
1122 | class wxMetaFile(wxMetaFilePtr): | |
1123 | def __init__(self,*_args,**_kwargs): | |
1124 | self.this = apply(gdic.new_wxMetaFile,_args,_kwargs) | |
1125 | self.thisown = 1 | |
1126 | ||
1127 | ||
1128 | ||
1129 | ||
1130 | class wxMetaFileDCPtr(wxDCPtr): | |
1131 | def __init__(self,this): | |
1132 | self.this = this | |
1133 | self.thisown = 0 | |
1134 | def Close(self, *_args, **_kwargs): | |
1135 | val = apply(gdic.wxMetaFileDC_Close,(self,) + _args, _kwargs) | |
1136 | if val: val = wxMetaFilePtr(val) | |
1137 | return val | |
1138 | def __repr__(self): | |
1139 | return "<C wxMetaFileDC instance at %s>" % (self.this,) | |
1140 | class wxMetaFileDC(wxMetaFileDCPtr): | |
1141 | def __init__(self,*_args,**_kwargs): | |
1142 | self.this = apply(gdic.new_wxMetaFileDC,_args,_kwargs) | |
1143 | self.thisown = 1 | |
1144 | ||
1145 | ||
1146 | ||
1147 | ||
1148 | class wxPalettePtr(wxGDIObjectPtr): | |
1149 | def __init__(self,this): | |
1150 | self.this = this | |
1151 | self.thisown = 0 | |
1152 | def __del__(self, delfunc=gdic.delete_wxPalette): | |
1153 | if self.thisown == 1: | |
1154 | try: | |
1155 | delfunc(self) | |
1156 | except: | |
1157 | pass | |
1158 | def GetPixel(self, *_args, **_kwargs): | |
1159 | val = apply(gdic.wxPalette_GetPixel,(self,) + _args, _kwargs) | |
1160 | return val | |
1161 | def GetRGB(self, *_args, **_kwargs): | |
1162 | val = apply(gdic.wxPalette_GetRGB,(self,) + _args, _kwargs) | |
1163 | return val | |
1164 | def Ok(self, *_args, **_kwargs): | |
1165 | val = apply(gdic.wxPalette_Ok,(self,) + _args, _kwargs) | |
1166 | return val | |
1167 | def __repr__(self): | |
1168 | return "<C wxPalette instance at %s>" % (self.this,) | |
1169 | class wxPalette(wxPalettePtr): | |
1170 | def __init__(self,*_args,**_kwargs): | |
1171 | self.this = apply(gdic.new_wxPalette,_args,_kwargs) | |
1172 | self.thisown = 1 | |
1173 | ||
1174 | ||
1175 | ||
1176 | ||
1177 | class wxImageListPtr(wxObjectPtr): | |
1178 | def __init__(self,this): | |
1179 | self.this = this | |
1180 | self.thisown = 0 | |
1181 | def __del__(self, delfunc=gdic.delete_wxImageList): | |
1182 | if self.thisown == 1: | |
1183 | try: | |
1184 | delfunc(self) | |
1185 | except: | |
1186 | pass | |
1187 | def Add(self, *_args, **_kwargs): | |
1188 | val = apply(gdic.wxImageList_Add,(self,) + _args, _kwargs) | |
1189 | return val | |
1190 | def AddWithColourMask(self, *_args, **_kwargs): | |
1191 | val = apply(gdic.wxImageList_AddWithColourMask,(self,) + _args, _kwargs) | |
1192 | return val | |
1193 | def AddIcon(self, *_args, **_kwargs): | |
1194 | val = apply(gdic.wxImageList_AddIcon,(self,) + _args, _kwargs) | |
1195 | return val | |
1196 | def Replace(self, *_args, **_kwargs): | |
1197 | val = apply(gdic.wxImageList_Replace,(self,) + _args, _kwargs) | |
1198 | return val | |
1199 | def Draw(self, *_args, **_kwargs): | |
1200 | val = apply(gdic.wxImageList_Draw,(self,) + _args, _kwargs) | |
1201 | return val | |
1202 | def GetImageCount(self, *_args, **_kwargs): | |
1203 | val = apply(gdic.wxImageList_GetImageCount,(self,) + _args, _kwargs) | |
1204 | return val | |
1205 | def Remove(self, *_args, **_kwargs): | |
1206 | val = apply(gdic.wxImageList_Remove,(self,) + _args, _kwargs) | |
1207 | return val | |
1208 | def RemoveAll(self, *_args, **_kwargs): | |
1209 | val = apply(gdic.wxImageList_RemoveAll,(self,) + _args, _kwargs) | |
1210 | return val | |
1211 | def GetSize(self, *_args, **_kwargs): | |
1212 | val = apply(gdic.wxImageList_GetSize,(self,) + _args, _kwargs) | |
1213 | return val | |
1214 | def __repr__(self): | |
1215 | return "<C wxImageList instance at %s>" % (self.this,) | |
1216 | class wxImageList(wxImageListPtr): | |
1217 | def __init__(self,*_args,**_kwargs): | |
1218 | self.this = apply(gdic.new_wxImageList,_args,_kwargs) | |
1219 | self.thisown = 1 | |
1220 | ||
1221 | ||
1222 | ||
1223 | ||
1224 | class wxRegionPtr(wxGDIObjectPtr): | |
1225 | def __init__(self,this): | |
1226 | self.this = this | |
1227 | self.thisown = 0 | |
1228 | def __del__(self, delfunc=gdic.delete_wxRegion): | |
1229 | if self.thisown == 1: | |
1230 | try: | |
1231 | delfunc(self) | |
1232 | except: | |
1233 | pass | |
1234 | def Clear(self, *_args, **_kwargs): | |
1235 | val = apply(gdic.wxRegion_Clear,(self,) + _args, _kwargs) | |
1236 | return val | |
1237 | def Offset(self, *_args, **_kwargs): | |
1238 | val = apply(gdic.wxRegion_Offset,(self,) + _args, _kwargs) | |
1239 | return val | |
1240 | def Contains(self, *_args, **_kwargs): | |
1241 | val = apply(gdic.wxRegion_Contains,(self,) + _args, _kwargs) | |
1242 | return val | |
1243 | def ContainsPoint(self, *_args, **_kwargs): | |
1244 | val = apply(gdic.wxRegion_ContainsPoint,(self,) + _args, _kwargs) | |
1245 | return val | |
1246 | def ContainsRect(self, *_args, **_kwargs): | |
1247 | val = apply(gdic.wxRegion_ContainsRect,(self,) + _args, _kwargs) | |
1248 | return val | |
1249 | def ContainsRectDim(self, *_args, **_kwargs): | |
1250 | val = apply(gdic.wxRegion_ContainsRectDim,(self,) + _args, _kwargs) | |
1251 | return val | |
1252 | def GetBox(self, *_args, **_kwargs): | |
1253 | val = apply(gdic.wxRegion_GetBox,(self,) + _args, _kwargs) | |
1254 | if val: val = wxRectPtr(val) ; val.thisown = 1 | |
1255 | return val | |
1256 | def Intersect(self, *_args, **_kwargs): | |
1257 | val = apply(gdic.wxRegion_Intersect,(self,) + _args, _kwargs) | |
1258 | return val | |
1259 | def IntersectRect(self, *_args, **_kwargs): | |
1260 | val = apply(gdic.wxRegion_IntersectRect,(self,) + _args, _kwargs) | |
1261 | return val | |
1262 | def IntersectRegion(self, *_args, **_kwargs): | |
1263 | val = apply(gdic.wxRegion_IntersectRegion,(self,) + _args, _kwargs) | |
1264 | return val | |
1265 | def IsEmpty(self, *_args, **_kwargs): | |
1266 | val = apply(gdic.wxRegion_IsEmpty,(self,) + _args, _kwargs) | |
1267 | return val | |
1268 | def Union(self, *_args, **_kwargs): | |
1269 | val = apply(gdic.wxRegion_Union,(self,) + _args, _kwargs) | |
1270 | return val | |
1271 | def UnionRect(self, *_args, **_kwargs): | |
1272 | val = apply(gdic.wxRegion_UnionRect,(self,) + _args, _kwargs) | |
1273 | return val | |
1274 | def UnionRegion(self, *_args, **_kwargs): | |
1275 | val = apply(gdic.wxRegion_UnionRegion,(self,) + _args, _kwargs) | |
1276 | return val | |
1277 | def Subtract(self, *_args, **_kwargs): | |
1278 | val = apply(gdic.wxRegion_Subtract,(self,) + _args, _kwargs) | |
1279 | return val | |
1280 | def SubtractRect(self, *_args, **_kwargs): | |
1281 | val = apply(gdic.wxRegion_SubtractRect,(self,) + _args, _kwargs) | |
1282 | return val | |
1283 | def SubtractRegion(self, *_args, **_kwargs): | |
1284 | val = apply(gdic.wxRegion_SubtractRegion,(self,) + _args, _kwargs) | |
1285 | return val | |
1286 | def Xor(self, *_args, **_kwargs): | |
1287 | val = apply(gdic.wxRegion_Xor,(self,) + _args, _kwargs) | |
1288 | return val | |
1289 | def XorRect(self, *_args, **_kwargs): | |
1290 | val = apply(gdic.wxRegion_XorRect,(self,) + _args, _kwargs) | |
1291 | return val | |
1292 | def XorRegion(self, *_args, **_kwargs): | |
1293 | val = apply(gdic.wxRegion_XorRegion,(self,) + _args, _kwargs) | |
1294 | return val | |
1295 | def __repr__(self): | |
1296 | return "<C wxRegion instance at %s>" % (self.this,) | |
1297 | class wxRegion(wxRegionPtr): | |
1298 | def __init__(self,*_args,**_kwargs): | |
1299 | self.this = apply(gdic.new_wxRegion,_args,_kwargs) | |
1300 | self.thisown = 1 | |
1301 | ||
1302 | ||
1303 | ||
1304 | def wxRegionFromPoints(*_args,**_kwargs): | |
1305 | val = wxRegionPtr(apply(gdic.new_wxRegionFromPoints,_args,_kwargs)) | |
1306 | val.thisown = 1 | |
1307 | return val | |
1308 | ||
1309 | ||
1310 | class wxRegionIteratorPtr(wxObjectPtr): | |
1311 | def __init__(self,this): | |
1312 | self.this = this | |
1313 | self.thisown = 0 | |
1314 | def __del__(self, delfunc=gdic.delete_wxRegionIterator): | |
1315 | if self.thisown == 1: | |
1316 | try: | |
1317 | delfunc(self) | |
1318 | except: | |
1319 | pass | |
1320 | def GetX(self, *_args, **_kwargs): | |
1321 | val = apply(gdic.wxRegionIterator_GetX,(self,) + _args, _kwargs) | |
1322 | return val | |
1323 | def GetY(self, *_args, **_kwargs): | |
1324 | val = apply(gdic.wxRegionIterator_GetY,(self,) + _args, _kwargs) | |
1325 | return val | |
1326 | def GetW(self, *_args, **_kwargs): | |
1327 | val = apply(gdic.wxRegionIterator_GetW,(self,) + _args, _kwargs) | |
1328 | return val | |
1329 | def GetWidth(self, *_args, **_kwargs): | |
1330 | val = apply(gdic.wxRegionIterator_GetWidth,(self,) + _args, _kwargs) | |
1331 | return val | |
1332 | def GetH(self, *_args, **_kwargs): | |
1333 | val = apply(gdic.wxRegionIterator_GetH,(self,) + _args, _kwargs) | |
1334 | return val | |
1335 | def GetHeight(self, *_args, **_kwargs): | |
1336 | val = apply(gdic.wxRegionIterator_GetHeight,(self,) + _args, _kwargs) | |
1337 | return val | |
1338 | def GetRect(self, *_args, **_kwargs): | |
1339 | val = apply(gdic.wxRegionIterator_GetRect,(self,) + _args, _kwargs) | |
1340 | if val: val = wxRectPtr(val) ; val.thisown = 1 | |
1341 | return val | |
1342 | def HaveRects(self, *_args, **_kwargs): | |
1343 | val = apply(gdic.wxRegionIterator_HaveRects,(self,) + _args, _kwargs) | |
1344 | return val | |
1345 | def Reset(self, *_args, **_kwargs): | |
1346 | val = apply(gdic.wxRegionIterator_Reset,(self,) + _args, _kwargs) | |
1347 | return val | |
1348 | def Next(self, *_args, **_kwargs): | |
1349 | val = apply(gdic.wxRegionIterator_Next,(self,) + _args, _kwargs) | |
1350 | return val | |
1351 | def __repr__(self): | |
1352 | return "<C wxRegionIterator instance at %s>" % (self.this,) | |
1353 | class wxRegionIterator(wxRegionIteratorPtr): | |
1354 | def __init__(self,*_args,**_kwargs): | |
1355 | self.this = apply(gdic.new_wxRegionIterator,_args,_kwargs) | |
1356 | self.thisown = 1 | |
1357 | ||
1358 | ||
1359 | ||
1360 | ||
1361 | ||
1362 | ||
1363 | #-------------- FUNCTION WRAPPERS ------------------ | |
1364 | ||
1365 | def wxEmptyBitmap(*_args, **_kwargs): | |
1366 | val = apply(gdic.wxEmptyBitmap,_args,_kwargs) | |
1367 | if val: val = wxBitmapPtr(val); val.thisown = 1 | |
1368 | return val | |
1369 | ||
1370 | def wxBitmapFromXPMData(*_args, **_kwargs): | |
1371 | val = apply(gdic.wxBitmapFromXPMData,_args,_kwargs) | |
1372 | if val: val = wxBitmapPtr(val); val.thisown = 1 | |
1373 | return val | |
1374 | ||
1375 | def wxBitmapFromIcon(*_args, **_kwargs): | |
1376 | val = apply(gdic.wxBitmapFromIcon,_args,_kwargs) | |
1377 | if val: val = wxBitmapPtr(val); val.thisown = 1 | |
1378 | return val | |
1379 | ||
1380 | def wxBitmapFromBits(*_args, **_kwargs): | |
1381 | val = apply(gdic.wxBitmapFromBits,_args,_kwargs) | |
1382 | if val: val = wxBitmapPtr(val); val.thisown = 1 | |
1383 | return val | |
1384 | ||
1385 | def wxMaskColour(*_args, **_kwargs): | |
1386 | val = apply(gdic.wxMaskColour,_args,_kwargs) | |
1387 | if val: val = wxMaskPtr(val); val.thisown = 1 | |
1388 | return val | |
1389 | ||
1390 | def wxEmptyIcon(*_args, **_kwargs): | |
1391 | val = apply(gdic.wxEmptyIcon,_args,_kwargs) | |
1392 | if val: val = wxIconPtr(val); val.thisown = 1 | |
1393 | return val | |
1394 | ||
1395 | def wxIconFromXPMData(*_args, **_kwargs): | |
1396 | val = apply(gdic.wxIconFromXPMData,_args,_kwargs) | |
1397 | if val: val = wxIconPtr(val); val.thisown = 1 | |
1398 | return val | |
1399 | ||
1400 | def wxIconFromBitmap(*_args, **_kwargs): | |
1401 | val = apply(gdic.wxIconFromBitmap,_args,_kwargs) | |
1402 | if val: val = wxIconPtr(val); val.thisown = 1 | |
1403 | return val | |
1404 | ||
1405 | def wxStockCursor(*_args, **_kwargs): | |
1406 | val = apply(gdic.wxStockCursor,_args,_kwargs) | |
1407 | if val: val = wxCursorPtr(val); val.thisown = 1 | |
1408 | return val | |
1409 | ||
1410 | def wxCursorFromImage(*_args, **_kwargs): | |
1411 | val = apply(gdic.wxCursorFromImage,_args,_kwargs) | |
1412 | if val: val = wxCursorPtr(val); val.thisown = 1 | |
1413 | return val | |
1414 | ||
1415 | def wxNamedColour(*_args, **_kwargs): | |
1416 | val = apply(gdic.wxNamedColour,_args,_kwargs) | |
1417 | if val: val = wxColourPtr(val); val.thisown = 1 | |
1418 | return val | |
1419 | ||
1420 | def wxMemoryDCFromDC(*_args, **_kwargs): | |
1421 | val = apply(gdic.wxMemoryDCFromDC,_args,_kwargs) | |
1422 | if val: val = wxMemoryDCPtr(val); val.thisown = 1 | |
1423 | return val | |
1424 | ||
1425 | ||
1426 | ||
1427 | #-------------- VARIABLE WRAPPERS ------------------ | |
1428 | ||
1429 | wxIMAGELIST_DRAW_NORMAL = gdic.wxIMAGELIST_DRAW_NORMAL | |
1430 | wxIMAGELIST_DRAW_TRANSPARENT = gdic.wxIMAGELIST_DRAW_TRANSPARENT | |
1431 | wxIMAGELIST_DRAW_SELECTED = gdic.wxIMAGELIST_DRAW_SELECTED | |
1432 | wxIMAGELIST_DRAW_FOCUSED = gdic.wxIMAGELIST_DRAW_FOCUSED | |
1433 | wxIMAGE_LIST_NORMAL = gdic.wxIMAGE_LIST_NORMAL | |
1434 | wxIMAGE_LIST_SMALL = gdic.wxIMAGE_LIST_SMALL | |
1435 | wxIMAGE_LIST_STATE = gdic.wxIMAGE_LIST_STATE | |
1436 | wxOutRegion = gdic.wxOutRegion | |
1437 | wxPartRegion = gdic.wxPartRegion | |
1438 | wxInRegion = gdic.wxInRegion | |
1439 | cvar = gdic.cvar | |
1440 | wxNORMAL_FONT = wxFontPtr(gdic.cvar.wxNORMAL_FONT) | |
1441 | wxSMALL_FONT = wxFontPtr(gdic.cvar.wxSMALL_FONT) | |
1442 | wxITALIC_FONT = wxFontPtr(gdic.cvar.wxITALIC_FONT) | |
1443 | wxSWISS_FONT = wxFontPtr(gdic.cvar.wxSWISS_FONT) | |
1444 | wxRED_PEN = wxPenPtr(gdic.cvar.wxRED_PEN) | |
1445 | wxCYAN_PEN = wxPenPtr(gdic.cvar.wxCYAN_PEN) | |
1446 | wxGREEN_PEN = wxPenPtr(gdic.cvar.wxGREEN_PEN) | |
1447 | wxBLACK_PEN = wxPenPtr(gdic.cvar.wxBLACK_PEN) | |
1448 | wxWHITE_PEN = wxPenPtr(gdic.cvar.wxWHITE_PEN) | |
1449 | wxTRANSPARENT_PEN = wxPenPtr(gdic.cvar.wxTRANSPARENT_PEN) | |
1450 | wxBLACK_DASHED_PEN = wxPenPtr(gdic.cvar.wxBLACK_DASHED_PEN) | |
1451 | wxGREY_PEN = wxPenPtr(gdic.cvar.wxGREY_PEN) | |
1452 | wxMEDIUM_GREY_PEN = wxPenPtr(gdic.cvar.wxMEDIUM_GREY_PEN) | |
1453 | wxLIGHT_GREY_PEN = wxPenPtr(gdic.cvar.wxLIGHT_GREY_PEN) | |
1454 | wxBLUE_BRUSH = wxBrushPtr(gdic.cvar.wxBLUE_BRUSH) | |
1455 | wxGREEN_BRUSH = wxBrushPtr(gdic.cvar.wxGREEN_BRUSH) | |
1456 | wxWHITE_BRUSH = wxBrushPtr(gdic.cvar.wxWHITE_BRUSH) | |
1457 | wxBLACK_BRUSH = wxBrushPtr(gdic.cvar.wxBLACK_BRUSH) | |
1458 | wxTRANSPARENT_BRUSH = wxBrushPtr(gdic.cvar.wxTRANSPARENT_BRUSH) | |
1459 | wxCYAN_BRUSH = wxBrushPtr(gdic.cvar.wxCYAN_BRUSH) | |
1460 | wxRED_BRUSH = wxBrushPtr(gdic.cvar.wxRED_BRUSH) | |
1461 | wxGREY_BRUSH = wxBrushPtr(gdic.cvar.wxGREY_BRUSH) | |
1462 | wxMEDIUM_GREY_BRUSH = wxBrushPtr(gdic.cvar.wxMEDIUM_GREY_BRUSH) | |
1463 | wxLIGHT_GREY_BRUSH = wxBrushPtr(gdic.cvar.wxLIGHT_GREY_BRUSH) | |
1464 | wxBLACK = wxColourPtr(gdic.cvar.wxBLACK) | |
1465 | wxWHITE = wxColourPtr(gdic.cvar.wxWHITE) | |
1466 | wxRED = wxColourPtr(gdic.cvar.wxRED) | |
1467 | wxBLUE = wxColourPtr(gdic.cvar.wxBLUE) | |
1468 | wxGREEN = wxColourPtr(gdic.cvar.wxGREEN) | |
1469 | wxCYAN = wxColourPtr(gdic.cvar.wxCYAN) | |
1470 | wxLIGHT_GREY = wxColourPtr(gdic.cvar.wxLIGHT_GREY) | |
1471 | wxSTANDARD_CURSOR = wxCursorPtr(gdic.cvar.wxSTANDARD_CURSOR) | |
1472 | wxHOURGLASS_CURSOR = wxCursorPtr(gdic.cvar.wxHOURGLASS_CURSOR) | |
1473 | wxCROSS_CURSOR = wxCursorPtr(gdic.cvar.wxCROSS_CURSOR) | |
1474 | wxNullBitmap = wxBitmapPtr(gdic.cvar.wxNullBitmap) | |
1475 | wxNullIcon = wxIconPtr(gdic.cvar.wxNullIcon) | |
1476 | wxNullCursor = wxCursorPtr(gdic.cvar.wxNullCursor) | |
1477 | wxNullPen = wxPenPtr(gdic.cvar.wxNullPen) | |
1478 | wxNullBrush = wxBrushPtr(gdic.cvar.wxNullBrush) | |
1479 | wxNullPalette = wxPalettePtr(gdic.cvar.wxNullPalette) | |
1480 | wxNullFont = wxFontPtr(gdic.cvar.wxNullFont) | |
1481 | wxNullColour = wxColourPtr(gdic.cvar.wxNullColour) | |
1482 | wxTheFontList = wxFontListPtr(gdic.cvar.wxTheFontList) | |
1483 | wxThePenList = wxPenListPtr(gdic.cvar.wxThePenList) | |
1484 | wxTheBrushList = wxBrushListPtr(gdic.cvar.wxTheBrushList) | |
1485 | wxTheColourDatabase = wxColourDatabasePtr(gdic.cvar.wxTheColourDatabase) |