]> git.saurik.com Git - wxWidgets.git/blame - wxPython/src/msw/gdi.py
Trim trailing spaces from key names when parsing
[wxWidgets.git] / wxPython / src / msw / gdi.py
CommitLineData
8ab979d7 1# This file was created automatically by SWIG.
d14a1e28 2# Don't modify this file, modify the SWIG interface instead.
8ab979d7 3
d14a1e28 4import _gdi
68bc8549 5
d14a1e28
RD
6import core
7wx = core
8#---------------------------------------------------------------------------
9
10class GDIObject(core.Object):
423f194a
RD
11 def __repr__(self):
12 return "<%s.%s; proxy of C++ wxGDIObject instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 13 def __init__(self, *args, **kwargs):
423f194a 14 """__init__() -> GDIObject"""
d14a1e28
RD
15 newobj = _gdi.new_GDIObject(*args, **kwargs)
16 self.this = newobj.this
9416aa89 17 self.thisown = 1
d14a1e28
RD
18 del newobj.thisown
19 def __del__(self, destroy=_gdi.delete_GDIObject):
423f194a 20 """__del__()"""
d14a1e28
RD
21 try:
22 if self.thisown: destroy(self)
23 except: pass
423f194a
RD
24
25 def GetVisible(*args, **kwargs):
26 """GetVisible() -> bool"""
27 return _gdi.GDIObject_GetVisible(*args, **kwargs)
28
29 def SetVisible(*args, **kwargs):
30 """SetVisible(bool visible)"""
31 return _gdi.GDIObject_SetVisible(*args, **kwargs)
32
33 def IsNull(*args, **kwargs):
34 """IsNull() -> bool"""
35 return _gdi.GDIObject_IsNull(*args, **kwargs)
36
d14a1e28
RD
37
38class GDIObjectPtr(GDIObject):
39 def __init__(self, this):
40 self.this = this
41 if not hasattr(self,"thisown"): self.thisown = 0
42 self.__class__ = GDIObject
43_gdi.GDIObject_swigregister(GDIObjectPtr)
9416aa89 44
d14a1e28 45#---------------------------------------------------------------------------
9416aa89 46
d14a1e28 47class Colour(core.Object):
328fcd84
RD
48 """
49 A colour is an object representing a combination of Red, Green, and Blue (RGB)
50 intensity values, and is used to determine drawing colours, window colours,
51 etc. Valid RGB values are in the range 0 to 255.
52
53 In wxPython there are typemaps that will automatically convert from a colour
54 name, or from a "#RRGGBB" colour hex value string to a wx.Colour object when
55 calling C++ methods that expect a wxColour. This means that the following are
56 all equivallent:
57
58 win.SetBackgroundColour(wxColour(0,0,255))
59 win.SetBackgroundColour("BLUE")
60 win.SetBackgroundColour("#0000FF")
61
62 You can retrieve the various current system colour settings with
63 wx.SystemSettings.GetColour.
64 """
423f194a
RD
65 def __repr__(self):
66 return "<%s.%s; proxy of C++ wxColour instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 67 def __init__(self, *args, **kwargs):
328fcd84
RD
68 """
69 __init__(unsigned char red=0, unsigned char green=0, unsigned char blue=0) -> Colour
70
71 Constructs a colour from red, green and blue values.
72 """
d14a1e28
RD
73 newobj = _gdi.new_Colour(*args, **kwargs)
74 self.this = newobj.this
75 self.thisown = 1
76 del newobj.thisown
77 def __del__(self, destroy=_gdi.delete_Colour):
423f194a 78 """__del__()"""
d14a1e28
RD
79 try:
80 if self.thisown: destroy(self)
81 except: pass
423f194a
RD
82
83 def Red(*args, **kwargs):
328fcd84
RD
84 """
85 Red() -> unsigned char
86
87 Returns the red intensity.
88 """
423f194a
RD
89 return _gdi.Colour_Red(*args, **kwargs)
90
91 def Green(*args, **kwargs):
328fcd84
RD
92 """
93 Green() -> unsigned char
94
95 Returns the green intensity.
96 """
423f194a
RD
97 return _gdi.Colour_Green(*args, **kwargs)
98
99 def Blue(*args, **kwargs):
328fcd84
RD
100 """
101 Blue() -> unsigned char
102
103 Returns the blue intensity.
104 """
423f194a
RD
105 return _gdi.Colour_Blue(*args, **kwargs)
106
107 def Ok(*args, **kwargs):
328fcd84
RD
108 """
109 Ok() -> bool
110
111 Returns True if the colour object is valid (the colour has been
112 initialised with RGB values).
113 """
423f194a
RD
114 return _gdi.Colour_Ok(*args, **kwargs)
115
116 def Set(*args, **kwargs):
328fcd84
RD
117 """
118 Set(unsigned char red, unsigned char green, unsigned char blue)
119
120 Sets the RGB intensity values.
121 """
423f194a
RD
122 return _gdi.Colour_Set(*args, **kwargs)
123
9fd4be55 124 def SetRGB(*args, **kwargs):
328fcd84
RD
125 """
126 SetRGB(unsigned long colRGB)
127
128 Sets the RGB intensity values from a packed RGB value.
129 """
9fd4be55 130 return _gdi.Colour_SetRGB(*args, **kwargs)
423f194a 131
328fcd84
RD
132 def SetFromName(*args, **kwargs):
133 """
134 SetFromName(String colourName)
135
136 Sets the RGB intensity values using a colour name listed in wx.TheColourDatabase.
137 """
138 return _gdi.Colour_SetFromName(*args, **kwargs)
139
140 def GetPixel(*args, **kwargs):
141 """
142 GetPixel() -> long
143
144 Returns a pixel value which is platform-dependent. On Windows, a
145 COLORREF is returned. On X, an allocated pixel value is returned.
146 -1 is returned if the pixel is invalid (on X, unallocated).
147 """
148 return _gdi.Colour_GetPixel(*args, **kwargs)
149
423f194a 150 def __eq__(*args, **kwargs):
328fcd84
RD
151 """
152 __eq__(Colour colour) -> bool
153
154 Compare colours for equality
155 """
423f194a
RD
156 return _gdi.Colour___eq__(*args, **kwargs)
157
158 def __ne__(*args, **kwargs):
328fcd84
RD
159 """
160 __ne__(Colour colour) -> bool
423f194a 161
328fcd84
RD
162 Compare colours for inequality
163 """
164 return _gdi.Colour___ne__(*args, **kwargs)
9fd4be55 165
423f194a 166 def Get(*args, **kwargs):
328fcd84
RD
167 """
168 Get() -> (r, g, b)
169
170 Returns the RGB intensity values as a tuple.
171 """
423f194a
RD
172 return _gdi.Colour_Get(*args, **kwargs)
173
328fcd84
RD
174 def GetRGB(*args, **kwargs):
175 """
176 GetRGB() -> unsigned long
177
178 Return the colour as a packed RGB value
179 """
180 return _gdi.Colour_GetRGB(*args, **kwargs)
181
d14a1e28
RD
182 asTuple = Get
183 def __str__(self): return str(self.asTuple())
d03fd34d 184 def __repr__(self): return 'wx.Colour' + str(self.asTuple())
d14a1e28 185 def __nonzero__(self): return self.Ok()
74e96f3d
RD
186 __safe_for_unpickling__ = True
187 def __reduce__(self): return (Colour, self.Get())
9416aa89
RD
188
189
d14a1e28
RD
190class ColourPtr(Colour):
191 def __init__(self, this):
6999b0d8 192 self.this = this
d14a1e28
RD
193 if not hasattr(self,"thisown"): self.thisown = 0
194 self.__class__ = Colour
195_gdi.Colour_swigregister(ColourPtr)
8ab979d7 196
d14a1e28 197def NamedColour(*args, **kwargs):
328fcd84
RD
198 """
199 NamedColour(String colorName) -> Colour
200
201 Constructs a colour object using a colour name listed in wx.TheColourDatabase.
202 """
d14a1e28
RD
203 val = _gdi.new_NamedColour(*args, **kwargs)
204 val.thisown = 1
205 return val
8ab979d7 206
d14a1e28 207def ColourRGB(*args, **kwargs):
328fcd84
RD
208 """
209 ColourRGB(unsigned long colRGB) -> Colour
210
211 Constructs a colour from a packed RGB value.
212 """
d14a1e28
RD
213 val = _gdi.new_ColourRGB(*args, **kwargs)
214 val.thisown = 1
215 return val
8ab979d7 216
8edf1c75
RD
217Color = Colour
218NamedColor = NamedColour
219ColorRGB = ColourRGB
220
d14a1e28 221class Palette(GDIObject):
423f194a
RD
222 def __repr__(self):
223 return "<%s.%s; proxy of C++ wxPalette instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 224 def __init__(self, *args, **kwargs):
423f194a 225 """__init__(int n, unsigned char red, unsigned char green, unsigned char blue) -> Palette"""
d14a1e28
RD
226 newobj = _gdi.new_Palette(*args, **kwargs)
227 self.this = newobj.this
228 self.thisown = 1
229 del newobj.thisown
230 def __del__(self, destroy=_gdi.delete_Palette):
423f194a 231 """__del__()"""
d14a1e28
RD
232 try:
233 if self.thisown: destroy(self)
234 except: pass
423f194a
RD
235
236 def GetPixel(*args, **kwargs):
237 """GetPixel(byte red, byte green, byte blue) -> int"""
238 return _gdi.Palette_GetPixel(*args, **kwargs)
239
240 def GetRGB(*args, **kwargs):
44127b65 241 """GetRGB(int pixel) -> (R,G,B)"""
423f194a
RD
242 return _gdi.Palette_GetRGB(*args, **kwargs)
243
244 def Ok(*args, **kwargs):
245 """Ok() -> bool"""
246 return _gdi.Palette_Ok(*args, **kwargs)
247
44127b65 248 def __nonzero__(self): return self.Ok()
8ab979d7 249
d14a1e28
RD
250class PalettePtr(Palette):
251 def __init__(self, this):
8ab979d7 252 self.this = this
d14a1e28
RD
253 if not hasattr(self,"thisown"): self.thisown = 0
254 self.__class__ = Palette
255_gdi.Palette_swigregister(PalettePtr)
256
257#---------------------------------------------------------------------------
258
259class Pen(GDIObject):
423f194a
RD
260 def __repr__(self):
261 return "<%s.%s; proxy of C++ wxPen instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 262 def __init__(self, *args, **kwargs):
423f194a 263 """__init__(Colour colour, int width=1, int style=SOLID) -> Pen"""
d14a1e28
RD
264 newobj = _gdi.new_Pen(*args, **kwargs)
265 self.this = newobj.this
266 self.thisown = 1
267 del newobj.thisown
268 def __del__(self, destroy=_gdi.delete_Pen):
423f194a 269 """__del__()"""
d14a1e28
RD
270 try:
271 if self.thisown: destroy(self)
272 except: pass
423f194a
RD
273
274 def GetCap(*args, **kwargs):
275 """GetCap() -> int"""
276 return _gdi.Pen_GetCap(*args, **kwargs)
277
278 def GetColour(*args, **kwargs):
279 """GetColour() -> Colour"""
280 return _gdi.Pen_GetColour(*args, **kwargs)
281
282 def GetJoin(*args, **kwargs):
283 """GetJoin() -> int"""
284 return _gdi.Pen_GetJoin(*args, **kwargs)
285
286 def GetStyle(*args, **kwargs):
287 """GetStyle() -> int"""
288 return _gdi.Pen_GetStyle(*args, **kwargs)
289
290 def GetWidth(*args, **kwargs):
291 """GetWidth() -> int"""
292 return _gdi.Pen_GetWidth(*args, **kwargs)
293
294 def Ok(*args, **kwargs):
295 """Ok() -> bool"""
296 return _gdi.Pen_Ok(*args, **kwargs)
297
298 def SetCap(*args, **kwargs):
299 """SetCap(int cap_style)"""
300 return _gdi.Pen_SetCap(*args, **kwargs)
301
302 def SetColour(*args, **kwargs):
303 """SetColour(Colour colour)"""
304 return _gdi.Pen_SetColour(*args, **kwargs)
305
306 def SetJoin(*args, **kwargs):
307 """SetJoin(int join_style)"""
308 return _gdi.Pen_SetJoin(*args, **kwargs)
309
310 def SetStyle(*args, **kwargs):
311 """SetStyle(int style)"""
312 return _gdi.Pen_SetStyle(*args, **kwargs)
313
314 def SetWidth(*args, **kwargs):
315 """SetWidth(int width)"""
316 return _gdi.Pen_SetWidth(*args, **kwargs)
317
318 def SetDashes(*args, **kwargs):
319 """SetDashes(int dashes, wxDash dashes_array)"""
320 return _gdi.Pen_SetDashes(*args, **kwargs)
321
322 def GetDashes(*args, **kwargs):
323 """GetDashes() -> PyObject"""
324 return _gdi.Pen_GetDashes(*args, **kwargs)
9fd4be55 325
db914595 326 def __eq__(*args, **kwargs):
328fcd84 327 """__eq__(Pen other) -> bool"""
db914595
RD
328 return _gdi.Pen___eq__(*args, **kwargs)
329
328fcd84
RD
330 def __ne__(*args, **kwargs):
331 """__ne__(Pen other) -> bool"""
332 return _gdi.Pen___ne__(*args, **kwargs)
333
9fd4be55
RD
334 def GetDashCount(*args, **kwargs):
335 """GetDashCount() -> int"""
336 return _gdi.Pen_GetDashCount(*args, **kwargs)
423f194a
RD
337
338 def GetStipple(*args, **kwargs):
339 """GetStipple() -> Bitmap"""
340 return _gdi.Pen_GetStipple(*args, **kwargs)
341
342 def SetStipple(*args, **kwargs):
343 """SetStipple(Bitmap stipple)"""
344 return _gdi.Pen_SetStipple(*args, **kwargs)
345
d14a1e28 346 def __nonzero__(self): return self.Ok()
d14a1e28
RD
347
348class PenPtr(Pen):
349 def __init__(self, this):
350 self.this = this
351 if not hasattr(self,"thisown"): self.thisown = 0
352 self.__class__ = Pen
353_gdi.Pen_swigregister(PenPtr)
354
355class PyPen(Pen):
423f194a
RD
356 def __repr__(self):
357 return "<%s.%s; proxy of C++ wxPyPen instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 358 def __init__(self, *args, **kwargs):
423f194a 359 """__init__(Colour colour, int width=1, int style=SOLID) -> PyPen"""
d14a1e28
RD
360 newobj = _gdi.new_PyPen(*args, **kwargs)
361 self.this = newobj.this
8ab979d7 362 self.thisown = 1
d14a1e28
RD
363 del newobj.thisown
364 def __del__(self, destroy=_gdi.delete_PyPen):
423f194a 365 """__del__()"""
d14a1e28
RD
366 try:
367 if self.thisown: destroy(self)
368 except: pass
423f194a
RD
369
370 def SetDashes(*args, **kwargs):
371 """SetDashes(int dashes, wxDash dashes_array)"""
372 return _gdi.PyPen_SetDashes(*args, **kwargs)
373
8ab979d7 374
d14a1e28
RD
375class PyPenPtr(PyPen):
376 def __init__(self, this):
377 self.this = this
378 if not hasattr(self,"thisown"): self.thisown = 0
379 self.__class__ = PyPen
380_gdi.PyPen_swigregister(PyPenPtr)
8ab979d7 381
d14a1e28
RD
382Pen = PyPen
383#---------------------------------------------------------------------------
8ab979d7 384
d14a1e28 385class Brush(GDIObject):
41f1cec7
RD
386 """
387 A brush is a drawing tool for filling in areas. It is used for painting the
388 background of rectangles, ellipses, etc. It has a colour and a style.
389 """
423f194a
RD
390 def __repr__(self):
391 return "<%s.%s; proxy of C++ wxBrush instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 392 def __init__(self, *args, **kwargs):
41f1cec7
RD
393 """
394 __init__(Colour colour, int style=SOLID) -> Brush
395
396 Constructs a brush from a colour object and style.
397 """
d14a1e28
RD
398 newobj = _gdi.new_Brush(*args, **kwargs)
399 self.this = newobj.this
400 self.thisown = 1
401 del newobj.thisown
402 def __del__(self, destroy=_gdi.delete_Brush):
423f194a 403 """__del__()"""
d14a1e28
RD
404 try:
405 if self.thisown: destroy(self)
406 except: pass
423f194a
RD
407
408 def SetColour(*args, **kwargs):
409 """SetColour(Colour col)"""
410 return _gdi.Brush_SetColour(*args, **kwargs)
411
412 def SetStyle(*args, **kwargs):
413 """SetStyle(int style)"""
414 return _gdi.Brush_SetStyle(*args, **kwargs)
415
416 def SetStipple(*args, **kwargs):
417 """SetStipple(Bitmap stipple)"""
418 return _gdi.Brush_SetStipple(*args, **kwargs)
419
420 def GetColour(*args, **kwargs):
421 """GetColour() -> Colour"""
422 return _gdi.Brush_GetColour(*args, **kwargs)
423
424 def GetStyle(*args, **kwargs):
425 """GetStyle() -> int"""
426 return _gdi.Brush_GetStyle(*args, **kwargs)
427
428 def GetStipple(*args, **kwargs):
429 """GetStipple() -> Bitmap"""
430 return _gdi.Brush_GetStipple(*args, **kwargs)
431
432 def Ok(*args, **kwargs):
433 """Ok() -> bool"""
434 return _gdi.Brush_Ok(*args, **kwargs)
435
d14a1e28 436 def __nonzero__(self): return self.Ok()
8ab979d7 437
d14a1e28
RD
438class BrushPtr(Brush):
439 def __init__(self, this):
8ab979d7 440 self.this = this
d14a1e28
RD
441 if not hasattr(self,"thisown"): self.thisown = 0
442 self.__class__ = Brush
443_gdi.Brush_swigregister(BrushPtr)
444
445class Bitmap(GDIObject):
423f194a
RD
446 def __repr__(self):
447 return "<%s.%s; proxy of C++ wxBitmap instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 448 def __init__(self, *args, **kwargs):
41f1cec7 449 """
d03fd34d 450 __init__(String name, int type=BITMAP_TYPE_ANY) -> Bitmap
41f1cec7
RD
451
452 Loads a bitmap from a file.
453 """
d14a1e28
RD
454 newobj = _gdi.new_Bitmap(*args, **kwargs)
455 self.this = newobj.this
5a2a9da2 456 self.thisown = 1
d14a1e28
RD
457 del newobj.thisown
458 def __del__(self, destroy=_gdi.delete_Bitmap):
423f194a 459 """__del__()"""
d14a1e28
RD
460 try:
461 if self.thisown: destroy(self)
462 except: pass
423f194a
RD
463
464 def SetPalette(*args, **kwargs):
465 """SetPalette(Palette palette)"""
466 return _gdi.Bitmap_SetPalette(*args, **kwargs)
467
468 def GetHandle(*args, **kwargs):
469 """GetHandle() -> long"""
470 return _gdi.Bitmap_GetHandle(*args, **kwargs)
471
472 def SetHandle(*args, **kwargs):
473 """SetHandle(long handle)"""
474 return _gdi.Bitmap_SetHandle(*args, **kwargs)
475
476 def Ok(*args, **kwargs):
477 """Ok() -> bool"""
478 return _gdi.Bitmap_Ok(*args, **kwargs)
479
480 def GetWidth(*args, **kwargs):
41f1cec7
RD
481 """
482 GetWidth() -> int
483
484 Gets the width of the bitmap in pixels.
485 """
423f194a
RD
486 return _gdi.Bitmap_GetWidth(*args, **kwargs)
487
488 def GetHeight(*args, **kwargs):
41f1cec7
RD
489 """
490 GetHeight() -> int
491
492 Gets the height of the bitmap in pixels.
493 """
423f194a
RD
494 return _gdi.Bitmap_GetHeight(*args, **kwargs)
495
496 def GetDepth(*args, **kwargs):
41f1cec7
RD
497 """
498 GetDepth() -> int
499
500 Gets the colour depth of the bitmap. A value of 1 indicates a
501 monochrome bitmap.
502 """
423f194a
RD
503 return _gdi.Bitmap_GetDepth(*args, **kwargs)
504
505 def ConvertToImage(*args, **kwargs):
41f1cec7
RD
506 """
507 ConvertToImage() -> Image
508
509 Creates a platform-independent image from a platform-dependent bitmap. This
510 preserves mask information so that bitmaps and images can be converted back
511 and forth without loss in that respect.
512 """
423f194a
RD
513 return _gdi.Bitmap_ConvertToImage(*args, **kwargs)
514
515 def GetMask(*args, **kwargs):
41f1cec7
RD
516 """
517 GetMask() -> Mask
518
519 Gets the associated mask (if any) which may have been loaded from a file
520 or explpicitly set for the bitmap.
521 """
423f194a
RD
522 return _gdi.Bitmap_GetMask(*args, **kwargs)
523
524 def SetMask(*args, **kwargs):
41f1cec7
RD
525 """
526 SetMask(Mask mask)
527
528 Sets the mask for this bitmap.
529 """
423f194a
RD
530 return _gdi.Bitmap_SetMask(*args, **kwargs)
531
532 def SetMaskColour(*args, **kwargs):
41f1cec7
RD
533 """
534 SetMaskColour(Colour colour)
535
536 Create a Mask based on a specified colour in the Bitmap.
537 """
423f194a
RD
538 return _gdi.Bitmap_SetMaskColour(*args, **kwargs)
539
540 def GetSubBitmap(*args, **kwargs):
41f1cec7
RD
541 """
542 GetSubBitmap(Rect rect) -> Bitmap
543
544 Returns a sub bitmap of the current one as long as the rect belongs entirely
545 to the bitmap. This function preserves bit depth and mask information.
546 """
423f194a
RD
547 return _gdi.Bitmap_GetSubBitmap(*args, **kwargs)
548
549 def SaveFile(*args, **kwargs):
41f1cec7 550 """
d03fd34d 551 SaveFile(String name, int type, Palette palette=(wxPalette *) NULL) -> bool
41f1cec7
RD
552
553 Saves a bitmap in the named file.
554 """
423f194a
RD
555 return _gdi.Bitmap_SaveFile(*args, **kwargs)
556
557 def LoadFile(*args, **kwargs):
41f1cec7 558 """
d03fd34d 559 LoadFile(String name, int type) -> bool
41f1cec7
RD
560
561 Loads a bitmap from a file
562 """
423f194a
RD
563 return _gdi.Bitmap_LoadFile(*args, **kwargs)
564
565 def CopyFromIcon(*args, **kwargs):
566 """CopyFromIcon(Icon icon) -> bool"""
567 return _gdi.Bitmap_CopyFromIcon(*args, **kwargs)
568
569 def SetHeight(*args, **kwargs):
41f1cec7
RD
570 """
571 SetHeight(int height)
572
573 Set the height property (does not affect the bitmap data).
574 """
423f194a
RD
575 return _gdi.Bitmap_SetHeight(*args, **kwargs)
576
577 def SetWidth(*args, **kwargs):
41f1cec7
RD
578 """
579 SetWidth(int width)
580
581 Set the width property (does not affect the bitmap data).
582 """
423f194a
RD
583 return _gdi.Bitmap_SetWidth(*args, **kwargs)
584
585 def SetDepth(*args, **kwargs):
41f1cec7
RD
586 """
587 SetDepth(int depth)
588
589 Set the depth property (does not affect the bitmap data).
590 """
423f194a
RD
591 return _gdi.Bitmap_SetDepth(*args, **kwargs)
592
593 def CopyFromCursor(*args, **kwargs):
594 """CopyFromCursor(Cursor cursor) -> bool"""
595 return _gdi.Bitmap_CopyFromCursor(*args, **kwargs)
596
597 def GetQuality(*args, **kwargs):
598 """GetQuality() -> int"""
599 return _gdi.Bitmap_GetQuality(*args, **kwargs)
600
601 def SetQuality(*args, **kwargs):
602 """SetQuality(int q)"""
603 return _gdi.Bitmap_SetQuality(*args, **kwargs)
604
d14a1e28 605 def __nonzero__(self): return self.Ok()
5a2a9da2 606
d14a1e28
RD
607class BitmapPtr(Bitmap):
608 def __init__(self, this):
609 self.this = this
610 if not hasattr(self,"thisown"): self.thisown = 0
611 self.__class__ = Bitmap
612_gdi.Bitmap_swigregister(BitmapPtr)
5a2a9da2 613
d14a1e28 614def EmptyBitmap(*args, **kwargs):
41f1cec7
RD
615 """
616 EmptyBitmap(int width, int height, int depth=-1) -> Bitmap
617
618 Creates a new bitmap of the given size. A depth of -1 indicates the depth of
619 the current screen or visual. Some platforms only support 1 for monochrome and
620 -1 for the current colour setting.
621 """
d14a1e28
RD
622 val = _gdi.new_EmptyBitmap(*args, **kwargs)
623 val.thisown = 1
624 return val
5a2a9da2 625
d14a1e28 626def BitmapFromIcon(*args, **kwargs):
41f1cec7
RD
627 """
628 BitmapFromIcon(Icon icon) -> Bitmap
629
630 Create a new bitmap from an Icon object.
631 """
d14a1e28
RD
632 val = _gdi.new_BitmapFromIcon(*args, **kwargs)
633 val.thisown = 1
634 return val
5a2a9da2 635
d14a1e28 636def BitmapFromImage(*args, **kwargs):
41f1cec7
RD
637 """
638 BitmapFromImage(Image image, int depth=-1) -> Bitmap
639
640 Creates bitmap object from the image. This has to be done to actually display
641 an image as you cannot draw an image directly on a window. The resulting
642 bitmap will use the provided colour depth (or that of the current system if
643 depth is -1) which entails that a colour reduction has to take place.
644 """
d14a1e28
RD
645 val = _gdi.new_BitmapFromImage(*args, **kwargs)
646 val.thisown = 1
647 return val
8ab979d7 648
d14a1e28 649def BitmapFromXPMData(*args, **kwargs):
41f1cec7
RD
650 """
651 BitmapFromXPMData(PyObject listOfStrings) -> Bitmap
652
653 Construct a Bitmap from a list of strings formatted as XPM data.
654 """
d14a1e28
RD
655 val = _gdi.new_BitmapFromXPMData(*args, **kwargs)
656 val.thisown = 1
657 return val
8ab979d7 658
d14a1e28 659def BitmapFromBits(*args, **kwargs):
41f1cec7
RD
660 """
661 BitmapFromBits(PyObject bits, int width, int height, int depth=1) -> Bitmap
662
663 Creates a bitmap from an array of bits. You should only use this function for
664 monochrome bitmaps (depth 1) in portable programs: in this case the bits
665 parameter should contain an XBM image. For other bit depths, the behaviour is
666 platform dependent.
667 """
d14a1e28
RD
668 val = _gdi.new_BitmapFromBits(*args, **kwargs)
669 val.thisown = 1
670 return val
8ab979d7 671
d14a1e28 672class Mask(core.Object):
41f1cec7
RD
673 """
674 This class encapsulates a monochrome mask bitmap, where the masked area is
675 black and the unmasked area is white. When associated with a bitmap and drawn
676 in a device context, the unmasked area of the bitmap will be drawn, and the
677 masked area will not be drawn.
678 """
423f194a
RD
679 def __repr__(self):
680 return "<%s.%s; proxy of C++ wxMask instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 681 def __init__(self, *args, **kwargs):
41f1cec7 682 """
0ffb2aa6 683 __init__(Bitmap bitmap, Colour colour=NullColour) -> Mask
41f1cec7 684
0ffb2aa6
RD
685 Constructs a mask from a bitmap and a colour in that bitmap that indicates
686 the transparent portions of the mask, by default BLACK is used.
41f1cec7 687 """
d14a1e28
RD
688 newobj = _gdi.new_Mask(*args, **kwargs)
689 self.this = newobj.this
690 self.thisown = 1
691 del newobj.thisown
8ab979d7 692
d14a1e28
RD
693class MaskPtr(Mask):
694 def __init__(self, this):
0e9b78ce 695 self.this = this
d14a1e28
RD
696 if not hasattr(self,"thisown"): self.thisown = 0
697 self.__class__ = Mask
698_gdi.Mask_swigregister(MaskPtr)
699
0ffb2aa6 700MaskColour = Mask
d14a1e28 701class Icon(GDIObject):
423f194a
RD
702 def __repr__(self):
703 return "<%s.%s; proxy of C++ wxIcon instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 704 def __init__(self, *args, **kwargs):
eb9b6107 705 """__init__(String name, int type, int desiredWidth=-1, int desiredHeight=-1) -> Icon"""
d14a1e28
RD
706 newobj = _gdi.new_Icon(*args, **kwargs)
707 self.this = newobj.this
0e9b78ce 708 self.thisown = 1
d14a1e28
RD
709 del newobj.thisown
710 def __del__(self, destroy=_gdi.delete_Icon):
423f194a 711 """__del__()"""
d14a1e28
RD
712 try:
713 if self.thisown: destroy(self)
714 except: pass
423f194a
RD
715
716 def LoadFile(*args, **kwargs):
eb9b6107 717 """LoadFile(String name, int type) -> bool"""
423f194a
RD
718 return _gdi.Icon_LoadFile(*args, **kwargs)
719
720 def GetHandle(*args, **kwargs):
721 """GetHandle() -> long"""
722 return _gdi.Icon_GetHandle(*args, **kwargs)
723
724 def SetHandle(*args, **kwargs):
725 """SetHandle(long handle)"""
726 return _gdi.Icon_SetHandle(*args, **kwargs)
727
728 def Ok(*args, **kwargs):
729 """Ok() -> bool"""
730 return _gdi.Icon_Ok(*args, **kwargs)
731
732 def GetWidth(*args, **kwargs):
733 """GetWidth() -> int"""
734 return _gdi.Icon_GetWidth(*args, **kwargs)
735
736 def GetHeight(*args, **kwargs):
737 """GetHeight() -> int"""
738 return _gdi.Icon_GetHeight(*args, **kwargs)
739
740 def GetDepth(*args, **kwargs):
741 """GetDepth() -> int"""
742 return _gdi.Icon_GetDepth(*args, **kwargs)
743
744 def SetWidth(*args, **kwargs):
745 """SetWidth(int w)"""
746 return _gdi.Icon_SetWidth(*args, **kwargs)
747
748 def SetHeight(*args, **kwargs):
749 """SetHeight(int h)"""
750 return _gdi.Icon_SetHeight(*args, **kwargs)
751
752 def SetDepth(*args, **kwargs):
753 """SetDepth(int d)"""
754 return _gdi.Icon_SetDepth(*args, **kwargs)
755
756 def SetSize(*args, **kwargs):
757 """SetSize(Size size)"""
758 return _gdi.Icon_SetSize(*args, **kwargs)
759
760 def CopyFromBitmap(*args, **kwargs):
761 """CopyFromBitmap(Bitmap bmp)"""
762 return _gdi.Icon_CopyFromBitmap(*args, **kwargs)
763
d14a1e28 764 def __nonzero__(self): return self.Ok()
0e9b78ce 765
d14a1e28
RD
766class IconPtr(Icon):
767 def __init__(self, this):
768 self.this = this
769 if not hasattr(self,"thisown"): self.thisown = 0
770 self.__class__ = Icon
771_gdi.Icon_swigregister(IconPtr)
0e9b78ce 772
d14a1e28 773def EmptyIcon(*args, **kwargs):
423f194a 774 """EmptyIcon() -> Icon"""
d14a1e28
RD
775 val = _gdi.new_EmptyIcon(*args, **kwargs)
776 val.thisown = 1
777 return val
0e9b78ce 778
d14a1e28 779def IconFromLocation(*args, **kwargs):
423f194a 780 """IconFromLocation(IconLocation loc) -> Icon"""
d14a1e28 781 val = _gdi.new_IconFromLocation(*args, **kwargs)
0e9b78ce
RD
782 val.thisown = 1
783 return val
784
d14a1e28 785def IconFromBitmap(*args, **kwargs):
423f194a 786 """IconFromBitmap(Bitmap bmp) -> Icon"""
d14a1e28 787 val = _gdi.new_IconFromBitmap(*args, **kwargs)
0e9b78ce
RD
788 val.thisown = 1
789 return val
790
d14a1e28 791def IconFromXPMData(*args, **kwargs):
423f194a 792 """IconFromXPMData(PyObject listOfStrings) -> Icon"""
d14a1e28
RD
793 val = _gdi.new_IconFromXPMData(*args, **kwargs)
794 val.thisown = 1
795 return val
0e9b78ce 796
d14a1e28 797class IconLocation(object):
423f194a
RD
798 def __repr__(self):
799 return "<%s.%s; proxy of C++ wxIconLocation instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 800 def __init__(self, *args, **kwargs):
d03fd34d 801 """__init__(String filename=&wxPyEmptyString, int num=0) -> IconLocation"""
d14a1e28
RD
802 newobj = _gdi.new_IconLocation(*args, **kwargs)
803 self.this = newobj.this
804 self.thisown = 1
805 del newobj.thisown
806 def __del__(self, destroy=_gdi.delete_IconLocation):
423f194a 807 """__del__()"""
d14a1e28
RD
808 try:
809 if self.thisown: destroy(self)
810 except: pass
423f194a
RD
811
812 def IsOk(*args, **kwargs):
813 """IsOk() -> bool"""
814 return _gdi.IconLocation_IsOk(*args, **kwargs)
815
d14a1e28 816 def __nonzero__(self): return self.Ok()
423f194a 817 def SetFileName(*args, **kwargs):
d03fd34d 818 """SetFileName(String filename)"""
423f194a
RD
819 return _gdi.IconLocation_SetFileName(*args, **kwargs)
820
821 def GetFileName(*args, **kwargs):
d03fd34d 822 """GetFileName() -> String"""
423f194a
RD
823 return _gdi.IconLocation_GetFileName(*args, **kwargs)
824
825 def SetIndex(*args, **kwargs):
826 """SetIndex(int num)"""
827 return _gdi.IconLocation_SetIndex(*args, **kwargs)
828
829 def GetIndex(*args, **kwargs):
830 """GetIndex() -> int"""
831 return _gdi.IconLocation_GetIndex(*args, **kwargs)
832
d14a1e28
RD
833
834class IconLocationPtr(IconLocation):
835 def __init__(self, this):
836 self.this = this
837 if not hasattr(self,"thisown"): self.thisown = 0
838 self.__class__ = IconLocation
839_gdi.IconLocation_swigregister(IconLocationPtr)
840
841class IconBundle(object):
423f194a
RD
842 def __repr__(self):
843 return "<%s.%s; proxy of C++ wxIconBundle instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 844 def __init__(self, *args, **kwargs):
423f194a 845 """__init__() -> IconBundle"""
d14a1e28
RD
846 newobj = _gdi.new_IconBundle(*args, **kwargs)
847 self.this = newobj.this
1dc2f865 848 self.thisown = 1
d14a1e28
RD
849 del newobj.thisown
850 def __del__(self, destroy=_gdi.delete_IconBundle):
423f194a 851 """__del__()"""
d14a1e28
RD
852 try:
853 if self.thisown: destroy(self)
854 except: pass
423f194a
RD
855
856 def AddIcon(*args, **kwargs):
857 """AddIcon(Icon icon)"""
858 return _gdi.IconBundle_AddIcon(*args, **kwargs)
859
860 def AddIconFromFile(*args, **kwargs):
d03fd34d 861 """AddIconFromFile(String file, long type)"""
423f194a
RD
862 return _gdi.IconBundle_AddIconFromFile(*args, **kwargs)
863
864 def GetIcon(*args, **kwargs):
865 """GetIcon(Size size) -> Icon"""
866 return _gdi.IconBundle_GetIcon(*args, **kwargs)
867
8ab979d7 868
d14a1e28
RD
869class IconBundlePtr(IconBundle):
870 def __init__(self, this):
871 self.this = this
872 if not hasattr(self,"thisown"): self.thisown = 0
873 self.__class__ = IconBundle
874_gdi.IconBundle_swigregister(IconBundlePtr)
8ab979d7 875
d14a1e28 876def IconBundleFromFile(*args, **kwargs):
d03fd34d 877 """IconBundleFromFile(String file, long type) -> IconBundle"""
d14a1e28
RD
878 val = _gdi.new_IconBundleFromFile(*args, **kwargs)
879 val.thisown = 1
880 return val
8ab979d7 881
d14a1e28 882def IconBundleFromIcon(*args, **kwargs):
423f194a 883 """IconBundleFromIcon(Icon icon) -> IconBundle"""
d14a1e28
RD
884 val = _gdi.new_IconBundleFromIcon(*args, **kwargs)
885 val.thisown = 1
886 return val
8ab979d7 887
d14a1e28 888class Cursor(GDIObject):
2f4c0a16
RD
889 """
890 A cursor is a small bitmap usually used for denoting where the
891 mouse pointer is, with a picture that might indicate the
892 interpretation of a mouse click.
893
894 A single cursor object may be used in many windows (any subwindow
895 type). The wxWindows convention is to set the cursor for a
896 window, as in X, rather than to set it globally as in MS Windows,
897 although a global wx.SetCursor function is also available for use
898 on MS Windows.
899 """
423f194a
RD
900 def __repr__(self):
901 return "<%s.%s; proxy of C++ wxCursor instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 902 def __init__(self, *args, **kwargs):
2f4c0a16
RD
903 """
904 __init__(String cursorName, long type, int hotSpotX=0, int hotSpotY=0) -> Cursor
905
906 Construct a Cursor from a file. Specify the type of file using
907 wx.BITAMP_TYPE* constants, and specify the hotspot if not using a
908 .cur file.
909
910 This cursor is not available on wxGTK, use wx.StockCursor,
911 wx.CursorFromImage, or wx.CursorFromBits instead.
912 """
d14a1e28
RD
913 newobj = _gdi.new_Cursor(*args, **kwargs)
914 self.this = newobj.this
915 self.thisown = 1
916 del newobj.thisown
917 def __del__(self, destroy=_gdi.delete_Cursor):
423f194a 918 """__del__()"""
d14a1e28
RD
919 try:
920 if self.thisown: destroy(self)
921 except: pass
423f194a
RD
922
923 def GetHandle(*args, **kwargs):
2f4c0a16
RD
924 """
925 GetHandle() -> long
926
927 Get the MS Windows handle for the cursor
928 """
423f194a
RD
929 return _gdi.Cursor_GetHandle(*args, **kwargs)
930
931 def SetHandle(*args, **kwargs):
2f4c0a16
RD
932 """
933 SetHandle(long handle)
934
935 Set the MS Windows handle to use for the cursor
936 """
423f194a
RD
937 return _gdi.Cursor_SetHandle(*args, **kwargs)
938
939 def Ok(*args, **kwargs):
940 """Ok() -> bool"""
941 return _gdi.Cursor_Ok(*args, **kwargs)
942
2f4c0a16 943 def __nonzero__(self): return self.Ok()
423f194a
RD
944 def GetWidth(*args, **kwargs):
945 """GetWidth() -> int"""
946 return _gdi.Cursor_GetWidth(*args, **kwargs)
947
948 def GetHeight(*args, **kwargs):
949 """GetHeight() -> int"""
950 return _gdi.Cursor_GetHeight(*args, **kwargs)
951
952 def GetDepth(*args, **kwargs):
953 """GetDepth() -> int"""
954 return _gdi.Cursor_GetDepth(*args, **kwargs)
955
956 def SetWidth(*args, **kwargs):
957 """SetWidth(int w)"""
958 return _gdi.Cursor_SetWidth(*args, **kwargs)
959
960 def SetHeight(*args, **kwargs):
961 """SetHeight(int h)"""
962 return _gdi.Cursor_SetHeight(*args, **kwargs)
963
964 def SetDepth(*args, **kwargs):
965 """SetDepth(int d)"""
966 return _gdi.Cursor_SetDepth(*args, **kwargs)
967
968 def SetSize(*args, **kwargs):
969 """SetSize(Size size)"""
970 return _gdi.Cursor_SetSize(*args, **kwargs)
971
7e50db3f 972
d14a1e28
RD
973class CursorPtr(Cursor):
974 def __init__(self, this):
975 self.this = this
976 if not hasattr(self,"thisown"): self.thisown = 0
977 self.__class__ = Cursor
978_gdi.Cursor_swigregister(CursorPtr)
8ab979d7 979
d14a1e28 980def StockCursor(*args, **kwargs):
2f4c0a16
RD
981 """
982 StockCursor(int id) -> Cursor
983
984 Create a cursor using one of the stock cursors. Note that not
985 all cursors are available on all platforms.
986 """
d14a1e28
RD
987 val = _gdi.new_StockCursor(*args, **kwargs)
988 val.thisown = 1
989 return val
8ab979d7 990
d14a1e28 991def CursorFromImage(*args, **kwargs):
41f1cec7 992 """
2f4c0a16
RD
993 CursorFromImage(Image image) -> Cursor
994
995 Constructs a cursor from a wxImage. The cursor is monochrome,
996 colors with the RGB elements all greater than 127 will be
997 foreground, colors less than this background. The mask (if any)
998 will be used as transparent.
999
1000 In MSW the foreground will be white and the background black. The
1001 cursor is resized to 32x32 In GTK, the two most frequent colors
1002 will be used for foreground and background. The cursor will be
1003 displayed at the size of the image. On MacOS the cursor is
1004 resized to 16x16 and currently only shown as black/white (mask
1005 respected).
41f1cec7 1006 """
2f4c0a16 1007 val = _gdi.new_CursorFromImage(*args, **kwargs)
d14a1e28
RD
1008 val.thisown = 1
1009 return val
8ab979d7 1010
d14a1e28
RD
1011#---------------------------------------------------------------------------
1012
1013OutRegion = _gdi.OutRegion
1014PartRegion = _gdi.PartRegion
1015InRegion = _gdi.InRegion
1016class Region(GDIObject):
423f194a
RD
1017 def __repr__(self):
1018 return "<%s.%s; proxy of C++ wxRegion instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 1019 def __init__(self, *args, **kwargs):
423f194a 1020 """__init__(int x=0, int y=0, int width=0, int height=0) -> Region"""
d14a1e28
RD
1021 newobj = _gdi.new_Region(*args, **kwargs)
1022 self.this = newobj.this
abbc2570 1023 self.thisown = 1
d14a1e28
RD
1024 del newobj.thisown
1025 def __del__(self, destroy=_gdi.delete_Region):
423f194a 1026 """__del__()"""
d14a1e28
RD
1027 try:
1028 if self.thisown: destroy(self)
1029 except: pass
423f194a
RD
1030
1031 def Clear(*args, **kwargs):
1032 """Clear()"""
1033 return _gdi.Region_Clear(*args, **kwargs)
1034
1035 def Offset(*args, **kwargs):
1036 """Offset(int x, int y) -> bool"""
1037 return _gdi.Region_Offset(*args, **kwargs)
1038
1039 def Contains(*args, **kwargs):
d03fd34d 1040 """Contains(int x, int y) -> int"""
423f194a
RD
1041 return _gdi.Region_Contains(*args, **kwargs)
1042
1043 def ContainsPoint(*args, **kwargs):
d03fd34d 1044 """ContainsPoint(Point pt) -> int"""
423f194a
RD
1045 return _gdi.Region_ContainsPoint(*args, **kwargs)
1046
1047 def ContainsRect(*args, **kwargs):
d03fd34d 1048 """ContainsRect(Rect rect) -> int"""
423f194a
RD
1049 return _gdi.Region_ContainsRect(*args, **kwargs)
1050
1051 def ContainsRectDim(*args, **kwargs):
d03fd34d 1052 """ContainsRectDim(int x, int y, int w, int h) -> int"""
423f194a
RD
1053 return _gdi.Region_ContainsRectDim(*args, **kwargs)
1054
1055 def GetBox(*args, **kwargs):
1056 """GetBox() -> Rect"""
1057 return _gdi.Region_GetBox(*args, **kwargs)
1058
1059 def Intersect(*args, **kwargs):
1060 """Intersect(int x, int y, int width, int height) -> bool"""
1061 return _gdi.Region_Intersect(*args, **kwargs)
1062
1063 def IntersectRect(*args, **kwargs):
1064 """IntersectRect(Rect rect) -> bool"""
1065 return _gdi.Region_IntersectRect(*args, **kwargs)
1066
1067 def IntersectRegion(*args, **kwargs):
1068 """IntersectRegion(Region region) -> bool"""
1069 return _gdi.Region_IntersectRegion(*args, **kwargs)
1070
1071 def IsEmpty(*args, **kwargs):
1072 """IsEmpty() -> bool"""
1073 return _gdi.Region_IsEmpty(*args, **kwargs)
1074
1075 def Union(*args, **kwargs):
1076 """Union(int x, int y, int width, int height) -> bool"""
1077 return _gdi.Region_Union(*args, **kwargs)
1078
1079 def UnionRect(*args, **kwargs):
1080 """UnionRect(Rect rect) -> bool"""
1081 return _gdi.Region_UnionRect(*args, **kwargs)
1082
1083 def UnionRegion(*args, **kwargs):
1084 """UnionRegion(Region region) -> bool"""
1085 return _gdi.Region_UnionRegion(*args, **kwargs)
1086
1087 def Subtract(*args, **kwargs):
1088 """Subtract(int x, int y, int width, int height) -> bool"""
1089 return _gdi.Region_Subtract(*args, **kwargs)
1090
1091 def SubtractRect(*args, **kwargs):
1092 """SubtractRect(Rect rect) -> bool"""
1093 return _gdi.Region_SubtractRect(*args, **kwargs)
1094
1095 def SubtractRegion(*args, **kwargs):
1096 """SubtractRegion(Region region) -> bool"""
1097 return _gdi.Region_SubtractRegion(*args, **kwargs)
1098
1099 def Xor(*args, **kwargs):
1100 """Xor(int x, int y, int width, int height) -> bool"""
1101 return _gdi.Region_Xor(*args, **kwargs)
1102
1103 def XorRect(*args, **kwargs):
1104 """XorRect(Rect rect) -> bool"""
1105 return _gdi.Region_XorRect(*args, **kwargs)
1106
1107 def XorRegion(*args, **kwargs):
1108 """XorRegion(Region region) -> bool"""
1109 return _gdi.Region_XorRegion(*args, **kwargs)
1110
1111 def ConvertToBitmap(*args, **kwargs):
1112 """ConvertToBitmap() -> Bitmap"""
1113 return _gdi.Region_ConvertToBitmap(*args, **kwargs)
1114
1115 def UnionBitmap(*args, **kwargs):
1116 """UnionBitmap(Bitmap bmp, Colour transColour=NullColour, int tolerance=0) -> bool"""
1117 return _gdi.Region_UnionBitmap(*args, **kwargs)
1118
d14a1e28
RD
1119
1120class RegionPtr(Region):
1121 def __init__(self, this):
1122 self.this = this
1123 if not hasattr(self,"thisown"): self.thisown = 0
1124 self.__class__ = Region
1125_gdi.Region_swigregister(RegionPtr)
0569df0f 1126
d14a1e28 1127def RegionFromBitmap(*args, **kwargs):
423f194a 1128 """RegionFromBitmap(Bitmap bmp, Colour transColour=NullColour, int tolerance=0) -> Region"""
d14a1e28
RD
1129 val = _gdi.new_RegionFromBitmap(*args, **kwargs)
1130 val.thisown = 1
1131 return val
0569df0f 1132
d14a1e28 1133def RegionFromPoints(*args, **kwargs):
423f194a 1134 """RegionFromPoints(int points, Point points_array, int fillStyle=WINDING_RULE) -> Region"""
d14a1e28
RD
1135 val = _gdi.new_RegionFromPoints(*args, **kwargs)
1136 val.thisown = 1
1137 return val
0569df0f 1138
d14a1e28 1139class RegionIterator(core.Object):
423f194a
RD
1140 def __repr__(self):
1141 return "<%s.%s; proxy of C++ wxRegionIterator instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 1142 def __init__(self, *args, **kwargs):
423f194a 1143 """__init__(Region region) -> RegionIterator"""
d14a1e28
RD
1144 newobj = _gdi.new_RegionIterator(*args, **kwargs)
1145 self.this = newobj.this
1146 self.thisown = 1
1147 del newobj.thisown
1148 def __del__(self, destroy=_gdi.delete_RegionIterator):
423f194a 1149 """__del__()"""
d14a1e28
RD
1150 try:
1151 if self.thisown: destroy(self)
1152 except: pass
423f194a
RD
1153
1154 def GetX(*args, **kwargs):
1155 """GetX() -> int"""
1156 return _gdi.RegionIterator_GetX(*args, **kwargs)
1157
1158 def GetY(*args, **kwargs):
1159 """GetY() -> int"""
1160 return _gdi.RegionIterator_GetY(*args, **kwargs)
1161
1162 def GetW(*args, **kwargs):
1163 """GetW() -> int"""
1164 return _gdi.RegionIterator_GetW(*args, **kwargs)
1165
1166 def GetWidth(*args, **kwargs):
1167 """GetWidth() -> int"""
1168 return _gdi.RegionIterator_GetWidth(*args, **kwargs)
1169
1170 def GetH(*args, **kwargs):
1171 """GetH() -> int"""
1172 return _gdi.RegionIterator_GetH(*args, **kwargs)
1173
1174 def GetHeight(*args, **kwargs):
1175 """GetHeight() -> int"""
1176 return _gdi.RegionIterator_GetHeight(*args, **kwargs)
1177
1178 def GetRect(*args, **kwargs):
1179 """GetRect() -> Rect"""
1180 return _gdi.RegionIterator_GetRect(*args, **kwargs)
1181
1182 def HaveRects(*args, **kwargs):
1183 """HaveRects() -> bool"""
1184 return _gdi.RegionIterator_HaveRects(*args, **kwargs)
1185
1186 def Reset(*args, **kwargs):
1187 """Reset()"""
1188 return _gdi.RegionIterator_Reset(*args, **kwargs)
1189
1190 def Next(*args, **kwargs):
1191 """Next()"""
1192 return _gdi.RegionIterator_Next(*args, **kwargs)
1193
1194 def __nonzero__(*args, **kwargs):
1195 """__nonzero__() -> bool"""
1196 return _gdi.RegionIterator___nonzero__(*args, **kwargs)
1197
0569df0f 1198
d14a1e28
RD
1199class RegionIteratorPtr(RegionIterator):
1200 def __init__(self, this):
1dc2f865 1201 self.this = this
d14a1e28
RD
1202 if not hasattr(self,"thisown"): self.thisown = 0
1203 self.__class__ = RegionIterator
1204_gdi.RegionIterator_swigregister(RegionIteratorPtr)
1205
1206#---------------------------------------------------------------------------
1207
1208FONTFAMILY_DEFAULT = _gdi.FONTFAMILY_DEFAULT
1209FONTFAMILY_DECORATIVE = _gdi.FONTFAMILY_DECORATIVE
1210FONTFAMILY_ROMAN = _gdi.FONTFAMILY_ROMAN
1211FONTFAMILY_SCRIPT = _gdi.FONTFAMILY_SCRIPT
1212FONTFAMILY_SWISS = _gdi.FONTFAMILY_SWISS
1213FONTFAMILY_MODERN = _gdi.FONTFAMILY_MODERN
1214FONTFAMILY_TELETYPE = _gdi.FONTFAMILY_TELETYPE
1215FONTFAMILY_MAX = _gdi.FONTFAMILY_MAX
1216FONTFAMILY_UNKNOWN = _gdi.FONTFAMILY_UNKNOWN
1217FONTSTYLE_NORMAL = _gdi.FONTSTYLE_NORMAL
1218FONTSTYLE_ITALIC = _gdi.FONTSTYLE_ITALIC
1219FONTSTYLE_SLANT = _gdi.FONTSTYLE_SLANT
1220FONTSTYLE_MAX = _gdi.FONTSTYLE_MAX
1221FONTWEIGHT_NORMAL = _gdi.FONTWEIGHT_NORMAL
1222FONTWEIGHT_LIGHT = _gdi.FONTWEIGHT_LIGHT
1223FONTWEIGHT_BOLD = _gdi.FONTWEIGHT_BOLD
1224FONTWEIGHT_MAX = _gdi.FONTWEIGHT_MAX
1225FONTFLAG_DEFAULT = _gdi.FONTFLAG_DEFAULT
1226FONTFLAG_ITALIC = _gdi.FONTFLAG_ITALIC
1227FONTFLAG_SLANT = _gdi.FONTFLAG_SLANT
1228FONTFLAG_LIGHT = _gdi.FONTFLAG_LIGHT
1229FONTFLAG_BOLD = _gdi.FONTFLAG_BOLD
1230FONTFLAG_ANTIALIASED = _gdi.FONTFLAG_ANTIALIASED
1231FONTFLAG_NOT_ANTIALIASED = _gdi.FONTFLAG_NOT_ANTIALIASED
1232FONTFLAG_UNDERLINED = _gdi.FONTFLAG_UNDERLINED
1233FONTFLAG_STRIKETHROUGH = _gdi.FONTFLAG_STRIKETHROUGH
1234FONTFLAG_MASK = _gdi.FONTFLAG_MASK
1235FONTENCODING_SYSTEM = _gdi.FONTENCODING_SYSTEM
1236FONTENCODING_DEFAULT = _gdi.FONTENCODING_DEFAULT
1237FONTENCODING_ISO8859_1 = _gdi.FONTENCODING_ISO8859_1
1238FONTENCODING_ISO8859_2 = _gdi.FONTENCODING_ISO8859_2
1239FONTENCODING_ISO8859_3 = _gdi.FONTENCODING_ISO8859_3
1240FONTENCODING_ISO8859_4 = _gdi.FONTENCODING_ISO8859_4
1241FONTENCODING_ISO8859_5 = _gdi.FONTENCODING_ISO8859_5
1242FONTENCODING_ISO8859_6 = _gdi.FONTENCODING_ISO8859_6
1243FONTENCODING_ISO8859_7 = _gdi.FONTENCODING_ISO8859_7
1244FONTENCODING_ISO8859_8 = _gdi.FONTENCODING_ISO8859_8
1245FONTENCODING_ISO8859_9 = _gdi.FONTENCODING_ISO8859_9
1246FONTENCODING_ISO8859_10 = _gdi.FONTENCODING_ISO8859_10
1247FONTENCODING_ISO8859_11 = _gdi.FONTENCODING_ISO8859_11
1248FONTENCODING_ISO8859_12 = _gdi.FONTENCODING_ISO8859_12
1249FONTENCODING_ISO8859_13 = _gdi.FONTENCODING_ISO8859_13
1250FONTENCODING_ISO8859_14 = _gdi.FONTENCODING_ISO8859_14
1251FONTENCODING_ISO8859_15 = _gdi.FONTENCODING_ISO8859_15
1252FONTENCODING_ISO8859_MAX = _gdi.FONTENCODING_ISO8859_MAX
1253FONTENCODING_KOI8 = _gdi.FONTENCODING_KOI8
1254FONTENCODING_ALTERNATIVE = _gdi.FONTENCODING_ALTERNATIVE
1255FONTENCODING_BULGARIAN = _gdi.FONTENCODING_BULGARIAN
1256FONTENCODING_CP437 = _gdi.FONTENCODING_CP437
1257FONTENCODING_CP850 = _gdi.FONTENCODING_CP850
1258FONTENCODING_CP852 = _gdi.FONTENCODING_CP852
1259FONTENCODING_CP855 = _gdi.FONTENCODING_CP855
1260FONTENCODING_CP866 = _gdi.FONTENCODING_CP866
1261FONTENCODING_CP874 = _gdi.FONTENCODING_CP874
1262FONTENCODING_CP932 = _gdi.FONTENCODING_CP932
1263FONTENCODING_CP936 = _gdi.FONTENCODING_CP936
1264FONTENCODING_CP949 = _gdi.FONTENCODING_CP949
1265FONTENCODING_CP950 = _gdi.FONTENCODING_CP950
1266FONTENCODING_CP1250 = _gdi.FONTENCODING_CP1250
1267FONTENCODING_CP1251 = _gdi.FONTENCODING_CP1251
1268FONTENCODING_CP1252 = _gdi.FONTENCODING_CP1252
1269FONTENCODING_CP1253 = _gdi.FONTENCODING_CP1253
1270FONTENCODING_CP1254 = _gdi.FONTENCODING_CP1254
1271FONTENCODING_CP1255 = _gdi.FONTENCODING_CP1255
1272FONTENCODING_CP1256 = _gdi.FONTENCODING_CP1256
1273FONTENCODING_CP1257 = _gdi.FONTENCODING_CP1257
1274FONTENCODING_CP12_MAX = _gdi.FONTENCODING_CP12_MAX
1275FONTENCODING_UTF7 = _gdi.FONTENCODING_UTF7
1276FONTENCODING_UTF8 = _gdi.FONTENCODING_UTF8
1277FONTENCODING_EUC_JP = _gdi.FONTENCODING_EUC_JP
1278FONTENCODING_UTF16BE = _gdi.FONTENCODING_UTF16BE
1279FONTENCODING_UTF16LE = _gdi.FONTENCODING_UTF16LE
1280FONTENCODING_UTF32BE = _gdi.FONTENCODING_UTF32BE
1281FONTENCODING_UTF32LE = _gdi.FONTENCODING_UTF32LE
83448d71
RD
1282FONTENCODING_MACROMAN = _gdi.FONTENCODING_MACROMAN
1283FONTENCODING_MACJAPANESE = _gdi.FONTENCODING_MACJAPANESE
1284FONTENCODING_MACCHINESETRAD = _gdi.FONTENCODING_MACCHINESETRAD
1285FONTENCODING_MACKOREAN = _gdi.FONTENCODING_MACKOREAN
1286FONTENCODING_MACARABIC = _gdi.FONTENCODING_MACARABIC
1287FONTENCODING_MACHEBREW = _gdi.FONTENCODING_MACHEBREW
1288FONTENCODING_MACGREEK = _gdi.FONTENCODING_MACGREEK
1289FONTENCODING_MACCYRILLIC = _gdi.FONTENCODING_MACCYRILLIC
1290FONTENCODING_MACDEVANAGARI = _gdi.FONTENCODING_MACDEVANAGARI
1291FONTENCODING_MACGURMUKHI = _gdi.FONTENCODING_MACGURMUKHI
1292FONTENCODING_MACGUJARATI = _gdi.FONTENCODING_MACGUJARATI
1293FONTENCODING_MACORIYA = _gdi.FONTENCODING_MACORIYA
1294FONTENCODING_MACBENGALI = _gdi.FONTENCODING_MACBENGALI
1295FONTENCODING_MACTAMIL = _gdi.FONTENCODING_MACTAMIL
1296FONTENCODING_MACTELUGU = _gdi.FONTENCODING_MACTELUGU
1297FONTENCODING_MACKANNADA = _gdi.FONTENCODING_MACKANNADA
1298FONTENCODING_MACMALAJALAM = _gdi.FONTENCODING_MACMALAJALAM
1299FONTENCODING_MACSINHALESE = _gdi.FONTENCODING_MACSINHALESE
1300FONTENCODING_MACBURMESE = _gdi.FONTENCODING_MACBURMESE
1301FONTENCODING_MACKHMER = _gdi.FONTENCODING_MACKHMER
1302FONTENCODING_MACTHAI = _gdi.FONTENCODING_MACTHAI
1303FONTENCODING_MACLAOTIAN = _gdi.FONTENCODING_MACLAOTIAN
1304FONTENCODING_MACGEORGIAN = _gdi.FONTENCODING_MACGEORGIAN
1305FONTENCODING_MACARMENIAN = _gdi.FONTENCODING_MACARMENIAN
1306FONTENCODING_MACCHINESESIMP = _gdi.FONTENCODING_MACCHINESESIMP
1307FONTENCODING_MACTIBETAN = _gdi.FONTENCODING_MACTIBETAN
1308FONTENCODING_MACMONGOLIAN = _gdi.FONTENCODING_MACMONGOLIAN
1309FONTENCODING_MACETHIOPIC = _gdi.FONTENCODING_MACETHIOPIC
1310FONTENCODING_MACCENTRALEUR = _gdi.FONTENCODING_MACCENTRALEUR
1311FONTENCODING_MACVIATNAMESE = _gdi.FONTENCODING_MACVIATNAMESE
1312FONTENCODING_MACARABICEXT = _gdi.FONTENCODING_MACARABICEXT
1313FONTENCODING_MACSYMBOL = _gdi.FONTENCODING_MACSYMBOL
1314FONTENCODING_MACDINGBATS = _gdi.FONTENCODING_MACDINGBATS
1315FONTENCODING_MACTURKISH = _gdi.FONTENCODING_MACTURKISH
1316FONTENCODING_MACCROATIAN = _gdi.FONTENCODING_MACCROATIAN
1317FONTENCODING_MACICELANDIC = _gdi.FONTENCODING_MACICELANDIC
1318FONTENCODING_MACROMANIAN = _gdi.FONTENCODING_MACROMANIAN
1319FONTENCODING_MACCELTIC = _gdi.FONTENCODING_MACCELTIC
1320FONTENCODING_MACGAELIC = _gdi.FONTENCODING_MACGAELIC
1321FONTENCODING_MACKEYBOARD = _gdi.FONTENCODING_MACKEYBOARD
1322FONTENCODING_MACMIN = _gdi.FONTENCODING_MACMIN
1323FONTENCODING_MACMAX = _gdi.FONTENCODING_MACMAX
d14a1e28
RD
1324FONTENCODING_MAX = _gdi.FONTENCODING_MAX
1325FONTENCODING_UTF16 = _gdi.FONTENCODING_UTF16
1326FONTENCODING_UTF32 = _gdi.FONTENCODING_UTF32
1327FONTENCODING_UNICODE = _gdi.FONTENCODING_UNICODE
1328FONTENCODING_GB2312 = _gdi.FONTENCODING_GB2312
1329FONTENCODING_BIG5 = _gdi.FONTENCODING_BIG5
1330FONTENCODING_SHIFT_JIS = _gdi.FONTENCODING_SHIFT_JIS
1331#---------------------------------------------------------------------------
1332
1333class NativeFontInfo(object):
423f194a
RD
1334 def __repr__(self):
1335 return "<%s.%s; proxy of C++ wxNativeFontInfo instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 1336 def __init__(self, *args, **kwargs):
423f194a 1337 """__init__() -> NativeFontInfo"""
d14a1e28
RD
1338 newobj = _gdi.new_NativeFontInfo(*args, **kwargs)
1339 self.this = newobj.this
1340 self.thisown = 1
1341 del newobj.thisown
1342 def __del__(self, destroy=_gdi.delete_NativeFontInfo):
423f194a 1343 """__del__()"""
d14a1e28
RD
1344 try:
1345 if self.thisown: destroy(self)
1346 except: pass
423f194a
RD
1347
1348 def Init(*args, **kwargs):
1349 """Init()"""
1350 return _gdi.NativeFontInfo_Init(*args, **kwargs)
1351
1352 def InitFromFont(*args, **kwargs):
1353 """InitFromFont(Font font)"""
1354 return _gdi.NativeFontInfo_InitFromFont(*args, **kwargs)
1355
1356 def GetPointSize(*args, **kwargs):
1357 """GetPointSize() -> int"""
1358 return _gdi.NativeFontInfo_GetPointSize(*args, **kwargs)
1359
1360 def GetStyle(*args, **kwargs):
d03fd34d 1361 """GetStyle() -> int"""
423f194a
RD
1362 return _gdi.NativeFontInfo_GetStyle(*args, **kwargs)
1363
1364 def GetWeight(*args, **kwargs):
d03fd34d 1365 """GetWeight() -> int"""
423f194a
RD
1366 return _gdi.NativeFontInfo_GetWeight(*args, **kwargs)
1367
1368 def GetUnderlined(*args, **kwargs):
1369 """GetUnderlined() -> bool"""
1370 return _gdi.NativeFontInfo_GetUnderlined(*args, **kwargs)
1371
1372 def GetFaceName(*args, **kwargs):
d03fd34d 1373 """GetFaceName() -> String"""
423f194a
RD
1374 return _gdi.NativeFontInfo_GetFaceName(*args, **kwargs)
1375
1376 def GetFamily(*args, **kwargs):
d03fd34d 1377 """GetFamily() -> int"""
423f194a
RD
1378 return _gdi.NativeFontInfo_GetFamily(*args, **kwargs)
1379
1380 def GetEncoding(*args, **kwargs):
d03fd34d 1381 """GetEncoding() -> int"""
423f194a
RD
1382 return _gdi.NativeFontInfo_GetEncoding(*args, **kwargs)
1383
1384 def SetPointSize(*args, **kwargs):
1385 """SetPointSize(int pointsize)"""
1386 return _gdi.NativeFontInfo_SetPointSize(*args, **kwargs)
1387
1388 def SetStyle(*args, **kwargs):
d03fd34d 1389 """SetStyle(int style)"""
423f194a
RD
1390 return _gdi.NativeFontInfo_SetStyle(*args, **kwargs)
1391
1392 def SetWeight(*args, **kwargs):
d03fd34d 1393 """SetWeight(int weight)"""
423f194a
RD
1394 return _gdi.NativeFontInfo_SetWeight(*args, **kwargs)
1395
1396 def SetUnderlined(*args, **kwargs):
1397 """SetUnderlined(bool underlined)"""
1398 return _gdi.NativeFontInfo_SetUnderlined(*args, **kwargs)
1399
1400 def SetFaceName(*args, **kwargs):
d03fd34d 1401 """SetFaceName(String facename)"""
423f194a
RD
1402 return _gdi.NativeFontInfo_SetFaceName(*args, **kwargs)
1403
1404 def SetFamily(*args, **kwargs):
d03fd34d 1405 """SetFamily(int family)"""
423f194a
RD
1406 return _gdi.NativeFontInfo_SetFamily(*args, **kwargs)
1407
1408 def SetEncoding(*args, **kwargs):
d03fd34d 1409 """SetEncoding(int encoding)"""
423f194a
RD
1410 return _gdi.NativeFontInfo_SetEncoding(*args, **kwargs)
1411
1412 def FromString(*args, **kwargs):
d03fd34d 1413 """FromString(String s) -> bool"""
423f194a
RD
1414 return _gdi.NativeFontInfo_FromString(*args, **kwargs)
1415
1416 def ToString(*args, **kwargs):
d03fd34d 1417 """ToString() -> String"""
423f194a
RD
1418 return _gdi.NativeFontInfo_ToString(*args, **kwargs)
1419
1420 def __str__(*args, **kwargs):
d03fd34d 1421 """__str__() -> String"""
423f194a
RD
1422 return _gdi.NativeFontInfo___str__(*args, **kwargs)
1423
1424 def FromUserString(*args, **kwargs):
d03fd34d 1425 """FromUserString(String s) -> bool"""
423f194a
RD
1426 return _gdi.NativeFontInfo_FromUserString(*args, **kwargs)
1427
1428 def ToUserString(*args, **kwargs):
d03fd34d 1429 """ToUserString() -> String"""
423f194a
RD
1430 return _gdi.NativeFontInfo_ToUserString(*args, **kwargs)
1431
d14a1e28
RD
1432
1433class NativeFontInfoPtr(NativeFontInfo):
1434 def __init__(self, this):
1435 self.this = this
1436 if not hasattr(self,"thisown"): self.thisown = 0
1437 self.__class__ = NativeFontInfo
1438_gdi.NativeFontInfo_swigregister(NativeFontInfoPtr)
1439
1440class NativeEncodingInfo(object):
423f194a
RD
1441 def __repr__(self):
1442 return "<%s.%s; proxy of C++ wxNativeEncodingInfo instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28
RD
1443 facename = property(_gdi.NativeEncodingInfo_facename_get, _gdi.NativeEncodingInfo_facename_set)
1444 encoding = property(_gdi.NativeEncodingInfo_encoding_get, _gdi.NativeEncodingInfo_encoding_set)
1445 def __init__(self, *args, **kwargs):
423f194a 1446 """__init__() -> NativeEncodingInfo"""
d14a1e28
RD
1447 newobj = _gdi.new_NativeEncodingInfo(*args, **kwargs)
1448 self.this = newobj.this
1dc2f865 1449 self.thisown = 1
d14a1e28
RD
1450 del newobj.thisown
1451 def __del__(self, destroy=_gdi.delete_NativeEncodingInfo):
423f194a 1452 """__del__()"""
d14a1e28
RD
1453 try:
1454 if self.thisown: destroy(self)
1455 except: pass
423f194a
RD
1456
1457 def FromString(*args, **kwargs):
d03fd34d 1458 """FromString(String s) -> bool"""
423f194a
RD
1459 return _gdi.NativeEncodingInfo_FromString(*args, **kwargs)
1460
1461 def ToString(*args, **kwargs):
d03fd34d 1462 """ToString() -> String"""
423f194a
RD
1463 return _gdi.NativeEncodingInfo_ToString(*args, **kwargs)
1464
8ab979d7 1465
d14a1e28
RD
1466class NativeEncodingInfoPtr(NativeEncodingInfo):
1467 def __init__(self, this):
1468 self.this = this
1469 if not hasattr(self,"thisown"): self.thisown = 0
1470 self.__class__ = NativeEncodingInfo
1471_gdi.NativeEncodingInfo_swigregister(NativeEncodingInfoPtr)
8ab979d7 1472
8ab979d7 1473
423f194a 1474def GetNativeFontEncoding(*args, **kwargs):
d03fd34d 1475 """GetNativeFontEncoding(int encoding) -> NativeEncodingInfo"""
423f194a 1476 return _gdi.GetNativeFontEncoding(*args, **kwargs)
8ab979d7 1477
423f194a
RD
1478def TestFontEncoding(*args, **kwargs):
1479 """TestFontEncoding(NativeEncodingInfo info) -> bool"""
1480 return _gdi.TestFontEncoding(*args, **kwargs)
d14a1e28
RD
1481#---------------------------------------------------------------------------
1482
1483class FontMapper(object):
423f194a
RD
1484 def __repr__(self):
1485 return "<%s.%s; proxy of C++ wxFontMapper instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 1486 def __init__(self, *args, **kwargs):
423f194a 1487 """__init__() -> FontMapper"""
d14a1e28
RD
1488 newobj = _gdi.new_FontMapper(*args, **kwargs)
1489 self.this = newobj.this
ecc08ead 1490 self.thisown = 1
d14a1e28
RD
1491 del newobj.thisown
1492 def __del__(self, destroy=_gdi.delete_FontMapper):
423f194a 1493 """__del__()"""
d14a1e28
RD
1494 try:
1495 if self.thisown: destroy(self)
1496 except: pass
423f194a
RD
1497
1498 def Get(*args, **kwargs):
83448d71 1499 """Get() -> FontMapper"""
423f194a
RD
1500 return _gdi.FontMapper_Get(*args, **kwargs)
1501
1502 Get = staticmethod(Get)
1503 def Set(*args, **kwargs):
83448d71 1504 """Set(FontMapper mapper) -> FontMapper"""
423f194a
RD
1505 return _gdi.FontMapper_Set(*args, **kwargs)
1506
1507 Set = staticmethod(Set)
1508 def CharsetToEncoding(*args, **kwargs):
d03fd34d 1509 """CharsetToEncoding(String charset, bool interactive=True) -> int"""
423f194a
RD
1510 return _gdi.FontMapper_CharsetToEncoding(*args, **kwargs)
1511
1512 def GetSupportedEncodingsCount(*args, **kwargs):
83448d71 1513 """GetSupportedEncodingsCount() -> size_t"""
423f194a
RD
1514 return _gdi.FontMapper_GetSupportedEncodingsCount(*args, **kwargs)
1515
1516 GetSupportedEncodingsCount = staticmethod(GetSupportedEncodingsCount)
1517 def GetEncoding(*args, **kwargs):
83448d71 1518 """GetEncoding(size_t n) -> int"""
423f194a
RD
1519 return _gdi.FontMapper_GetEncoding(*args, **kwargs)
1520
1521 GetEncoding = staticmethod(GetEncoding)
1522 def GetEncodingName(*args, **kwargs):
83448d71 1523 """GetEncodingName(int encoding) -> String"""
423f194a
RD
1524 return _gdi.FontMapper_GetEncodingName(*args, **kwargs)
1525
1526 GetEncodingName = staticmethod(GetEncodingName)
1527 def GetEncodingDescription(*args, **kwargs):
83448d71 1528 """GetEncodingDescription(int encoding) -> String"""
423f194a
RD
1529 return _gdi.FontMapper_GetEncodingDescription(*args, **kwargs)
1530
1531 GetEncodingDescription = staticmethod(GetEncodingDescription)
1532 def SetConfig(*args, **kwargs):
d03fd34d 1533 """SetConfig(ConfigBase config)"""
423f194a
RD
1534 return _gdi.FontMapper_SetConfig(*args, **kwargs)
1535
1536 def SetConfigPath(*args, **kwargs):
d03fd34d 1537 """SetConfigPath(String prefix)"""
423f194a
RD
1538 return _gdi.FontMapper_SetConfigPath(*args, **kwargs)
1539
1540 def GetDefaultConfigPath(*args, **kwargs):
83448d71 1541 """GetDefaultConfigPath() -> String"""
423f194a
RD
1542 return _gdi.FontMapper_GetDefaultConfigPath(*args, **kwargs)
1543
1544 GetDefaultConfigPath = staticmethod(GetDefaultConfigPath)
1545 def GetAltForEncoding(*args, **kwargs):
d03fd34d 1546 """GetAltForEncoding(int encoding, String facename=EmptyString, bool interactive=True) -> PyObject"""
423f194a
RD
1547 return _gdi.FontMapper_GetAltForEncoding(*args, **kwargs)
1548
1549 def IsEncodingAvailable(*args, **kwargs):
d03fd34d 1550 """IsEncodingAvailable(int encoding, String facename=EmptyString) -> bool"""
423f194a
RD
1551 return _gdi.FontMapper_IsEncodingAvailable(*args, **kwargs)
1552
1553 def SetDialogParent(*args, **kwargs):
1554 """SetDialogParent(Window parent)"""
1555 return _gdi.FontMapper_SetDialogParent(*args, **kwargs)
1556
1557 def SetDialogTitle(*args, **kwargs):
d03fd34d 1558 """SetDialogTitle(String title)"""
423f194a
RD
1559 return _gdi.FontMapper_SetDialogTitle(*args, **kwargs)
1560
ecc08ead 1561
d14a1e28
RD
1562class FontMapperPtr(FontMapper):
1563 def __init__(self, this):
1564 self.this = this
1565 if not hasattr(self,"thisown"): self.thisown = 0
1566 self.__class__ = FontMapper
1567_gdi.FontMapper_swigregister(FontMapperPtr)
ecc08ead 1568
423f194a
RD
1569def FontMapper_Get(*args, **kwargs):
1570 """FontMapper_Get() -> FontMapper"""
1571 return _gdi.FontMapper_Get(*args, **kwargs)
ecc08ead 1572
423f194a
RD
1573def FontMapper_Set(*args, **kwargs):
1574 """FontMapper_Set(FontMapper mapper) -> FontMapper"""
1575 return _gdi.FontMapper_Set(*args, **kwargs)
ecc08ead 1576
423f194a
RD
1577def FontMapper_GetSupportedEncodingsCount(*args, **kwargs):
1578 """FontMapper_GetSupportedEncodingsCount() -> size_t"""
1579 return _gdi.FontMapper_GetSupportedEncodingsCount(*args, **kwargs)
d14a1e28 1580
423f194a 1581def FontMapper_GetEncoding(*args, **kwargs):
d03fd34d 1582 """FontMapper_GetEncoding(size_t n) -> int"""
423f194a 1583 return _gdi.FontMapper_GetEncoding(*args, **kwargs)
d14a1e28 1584
423f194a 1585def FontMapper_GetEncodingName(*args, **kwargs):
d03fd34d 1586 """FontMapper_GetEncodingName(int encoding) -> String"""
423f194a 1587 return _gdi.FontMapper_GetEncodingName(*args, **kwargs)
d14a1e28 1588
423f194a 1589def FontMapper_GetEncodingDescription(*args, **kwargs):
d03fd34d 1590 """FontMapper_GetEncodingDescription(int encoding) -> String"""
423f194a 1591 return _gdi.FontMapper_GetEncodingDescription(*args, **kwargs)
d14a1e28 1592
423f194a 1593def FontMapper_GetDefaultConfigPath(*args, **kwargs):
d03fd34d 1594 """FontMapper_GetDefaultConfigPath() -> String"""
423f194a 1595 return _gdi.FontMapper_GetDefaultConfigPath(*args, **kwargs)
d14a1e28
RD
1596
1597#---------------------------------------------------------------------------
1598
1599class Font(GDIObject):
423f194a
RD
1600 def __repr__(self):
1601 return "<%s.%s; proxy of C++ wxFont instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 1602 def __init__(self, *args, **kwargs):
41f1cec7
RD
1603 """
1604 __init__(int pointSize, int family, int style, int weight, bool underline=False,
d03fd34d
RD
1605 String face=EmptyString,
1606 int encoding=FONTENCODING_DEFAULT) -> Font
41f1cec7 1607 """
d14a1e28
RD
1608 newobj = _gdi.new_Font(*args, **kwargs)
1609 self.this = newobj.this
1610 self.thisown = 1
1611 del newobj.thisown
1612 def __del__(self, destroy=_gdi.delete_Font):
423f194a 1613 """__del__()"""
d14a1e28
RD
1614 try:
1615 if self.thisown: destroy(self)
1616 except: pass
423f194a
RD
1617
1618 def Ok(*args, **kwargs):
1619 """Ok() -> bool"""
1620 return _gdi.Font_Ok(*args, **kwargs)
1621
d14a1e28 1622 def __nonzero__(self): return self.Ok()
423f194a 1623 def __eq__(*args, **kwargs):
328fcd84 1624 """__eq__(Font other) -> bool"""
423f194a 1625 return _gdi.Font___eq__(*args, **kwargs)
d14a1e28 1626
423f194a 1627 def __ne__(*args, **kwargs):
328fcd84 1628 """__ne__(Font other) -> bool"""
423f194a 1629 return _gdi.Font___ne__(*args, **kwargs)
0569df0f 1630
423f194a
RD
1631 def GetPointSize(*args, **kwargs):
1632 """GetPointSize() -> int"""
1633 return _gdi.Font_GetPointSize(*args, **kwargs)
1634
1635 def GetFamily(*args, **kwargs):
1636 """GetFamily() -> int"""
1637 return _gdi.Font_GetFamily(*args, **kwargs)
1638
1639 def GetStyle(*args, **kwargs):
1640 """GetStyle() -> int"""
1641 return _gdi.Font_GetStyle(*args, **kwargs)
1642
1643 def GetWeight(*args, **kwargs):
1644 """GetWeight() -> int"""
1645 return _gdi.Font_GetWeight(*args, **kwargs)
1646
1647 def GetUnderlined(*args, **kwargs):
1648 """GetUnderlined() -> bool"""
1649 return _gdi.Font_GetUnderlined(*args, **kwargs)
1650
1651 def GetFaceName(*args, **kwargs):
d03fd34d 1652 """GetFaceName() -> String"""
423f194a
RD
1653 return _gdi.Font_GetFaceName(*args, **kwargs)
1654
1655 def GetEncoding(*args, **kwargs):
d03fd34d 1656 """GetEncoding() -> int"""
423f194a
RD
1657 return _gdi.Font_GetEncoding(*args, **kwargs)
1658
1659 def GetNativeFontInfo(*args, **kwargs):
1660 """GetNativeFontInfo() -> NativeFontInfo"""
1661 return _gdi.Font_GetNativeFontInfo(*args, **kwargs)
1662
1663 def IsFixedWidth(*args, **kwargs):
1664 """IsFixedWidth() -> bool"""
1665 return _gdi.Font_IsFixedWidth(*args, **kwargs)
1666
1667 def GetNativeFontInfoDesc(*args, **kwargs):
d03fd34d 1668 """GetNativeFontInfoDesc() -> String"""
423f194a
RD
1669 return _gdi.Font_GetNativeFontInfoDesc(*args, **kwargs)
1670
1671 def GetNativeFontInfoUserDesc(*args, **kwargs):
d03fd34d 1672 """GetNativeFontInfoUserDesc() -> String"""
423f194a
RD
1673 return _gdi.Font_GetNativeFontInfoUserDesc(*args, **kwargs)
1674
1675 def SetPointSize(*args, **kwargs):
1676 """SetPointSize(int pointSize)"""
1677 return _gdi.Font_SetPointSize(*args, **kwargs)
1678
1679 def SetFamily(*args, **kwargs):
1680 """SetFamily(int family)"""
1681 return _gdi.Font_SetFamily(*args, **kwargs)
1682
1683 def SetStyle(*args, **kwargs):
1684 """SetStyle(int style)"""
1685 return _gdi.Font_SetStyle(*args, **kwargs)
1686
1687 def SetWeight(*args, **kwargs):
1688 """SetWeight(int weight)"""
1689 return _gdi.Font_SetWeight(*args, **kwargs)
1690
1691 def SetFaceName(*args, **kwargs):
d03fd34d 1692 """SetFaceName(String faceName)"""
423f194a
RD
1693 return _gdi.Font_SetFaceName(*args, **kwargs)
1694
1695 def SetUnderlined(*args, **kwargs):
1696 """SetUnderlined(bool underlined)"""
1697 return _gdi.Font_SetUnderlined(*args, **kwargs)
1698
1699 def SetEncoding(*args, **kwargs):
d03fd34d 1700 """SetEncoding(int encoding)"""
423f194a
RD
1701 return _gdi.Font_SetEncoding(*args, **kwargs)
1702
1703 def SetNativeFontInfo(*args, **kwargs):
1704 """SetNativeFontInfo(NativeFontInfo info)"""
1705 return _gdi.Font_SetNativeFontInfo(*args, **kwargs)
1706
1707 def SetNativeFontInfoFromString(*args, **kwargs):
d03fd34d 1708 """SetNativeFontInfoFromString(String info)"""
423f194a
RD
1709 return _gdi.Font_SetNativeFontInfoFromString(*args, **kwargs)
1710
1711 def SetNativeFontInfoUserDesc(*args, **kwargs):
d03fd34d 1712 """SetNativeFontInfoUserDesc(String info)"""
423f194a
RD
1713 return _gdi.Font_SetNativeFontInfoUserDesc(*args, **kwargs)
1714
1715 def GetFamilyString(*args, **kwargs):
d03fd34d 1716 """GetFamilyString() -> String"""
423f194a
RD
1717 return _gdi.Font_GetFamilyString(*args, **kwargs)
1718
1719 def GetStyleString(*args, **kwargs):
d03fd34d 1720 """GetStyleString() -> String"""
423f194a
RD
1721 return _gdi.Font_GetStyleString(*args, **kwargs)
1722
1723 def GetWeightString(*args, **kwargs):
d03fd34d 1724 """GetWeightString() -> String"""
423f194a
RD
1725 return _gdi.Font_GetWeightString(*args, **kwargs)
1726
1727 def SetNoAntiAliasing(*args, **kwargs):
1728 """SetNoAntiAliasing(bool no=True)"""
1729 return _gdi.Font_SetNoAntiAliasing(*args, **kwargs)
1730
1731 def GetNoAntiAliasing(*args, **kwargs):
1732 """GetNoAntiAliasing() -> bool"""
1733 return _gdi.Font_GetNoAntiAliasing(*args, **kwargs)
1734
1735 def GetDefaultEncoding(*args, **kwargs):
83448d71 1736 """GetDefaultEncoding() -> int"""
423f194a
RD
1737 return _gdi.Font_GetDefaultEncoding(*args, **kwargs)
1738
1739 GetDefaultEncoding = staticmethod(GetDefaultEncoding)
1740 def SetDefaultEncoding(*args, **kwargs):
83448d71 1741 """SetDefaultEncoding(int encoding)"""
423f194a
RD
1742 return _gdi.Font_SetDefaultEncoding(*args, **kwargs)
1743
1744 SetDefaultEncoding = staticmethod(SetDefaultEncoding)
1745
1746class FontPtr(Font):
1747 def __init__(self, this):
1748 self.this = this
1749 if not hasattr(self,"thisown"): self.thisown = 0
1750 self.__class__ = Font
1751_gdi.Font_swigregister(FontPtr)
1752
1753def FontFromNativeInfo(*args, **kwargs):
1754 """FontFromNativeInfo(NativeFontInfo info) -> Font"""
1755 val = _gdi.new_FontFromNativeInfo(*args, **kwargs)
1756 val.thisown = 1
1757 return val
0569df0f 1758
d14a1e28 1759def FontFromNativeInfoString(*args, **kwargs):
d03fd34d 1760 """FontFromNativeInfoString(String info) -> Font"""
d14a1e28
RD
1761 val = _gdi.new_FontFromNativeInfoString(*args, **kwargs)
1762 val.thisown = 1
1763 return val
0569df0f 1764
d14a1e28 1765def Font2(*args, **kwargs):
41f1cec7 1766 """
d03fd34d
RD
1767 Font2(int pointSize, int family, int flags=FONTFLAG_DEFAULT,
1768 String face=EmptyString, int encoding=FONTENCODING_DEFAULT) -> Font
41f1cec7 1769 """
d14a1e28
RD
1770 val = _gdi.new_Font2(*args, **kwargs)
1771 val.thisown = 1
1772 return val
0569df0f 1773
423f194a 1774def Font_GetDefaultEncoding(*args, **kwargs):
d03fd34d 1775 """Font_GetDefaultEncoding() -> int"""
423f194a 1776 return _gdi.Font_GetDefaultEncoding(*args, **kwargs)
8ab979d7 1777
423f194a 1778def Font_SetDefaultEncoding(*args, **kwargs):
d03fd34d 1779 """Font_SetDefaultEncoding(int encoding)"""
423f194a 1780 return _gdi.Font_SetDefaultEncoding(*args, **kwargs)
8ab979d7 1781
d14a1e28 1782#---------------------------------------------------------------------------
8ab979d7 1783
d14a1e28 1784class FontEnumerator(object):
423f194a
RD
1785 def __repr__(self):
1786 return "<%s.%s; proxy of C++ wxPyFontEnumerator instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 1787 def __init__(self, *args, **kwargs):
423f194a 1788 """__init__() -> FontEnumerator"""
d14a1e28
RD
1789 newobj = _gdi.new_FontEnumerator(*args, **kwargs)
1790 self.this = newobj.this
1791 self.thisown = 1
1792 del newobj.thisown
1793 self._setCallbackInfo(self, FontEnumerator, 0)
423f194a 1794
d14a1e28 1795 def __del__(self, destroy=_gdi.delete_FontEnumerator):
423f194a 1796 """__del__()"""
d14a1e28
RD
1797 try:
1798 if self.thisown: destroy(self)
1799 except: pass
423f194a
RD
1800
1801 def _setCallbackInfo(*args, **kwargs):
1802 """_setCallbackInfo(PyObject self, PyObject _class, bool incref)"""
1803 return _gdi.FontEnumerator__setCallbackInfo(*args, **kwargs)
1804
1805 def EnumerateFacenames(*args, **kwargs):
d03fd34d 1806 """EnumerateFacenames(int encoding=FONTENCODING_SYSTEM, bool fixedWidthOnly=False) -> bool"""
423f194a
RD
1807 return _gdi.FontEnumerator_EnumerateFacenames(*args, **kwargs)
1808
1809 def EnumerateEncodings(*args, **kwargs):
d03fd34d 1810 """EnumerateEncodings(String facename=EmptyString) -> bool"""
423f194a
RD
1811 return _gdi.FontEnumerator_EnumerateEncodings(*args, **kwargs)
1812
1813 def GetEncodings(*args, **kwargs):
1814 """GetEncodings() -> PyObject"""
1815 return _gdi.FontEnumerator_GetEncodings(*args, **kwargs)
1816
1817 def GetFacenames(*args, **kwargs):
1818 """GetFacenames() -> PyObject"""
1819 return _gdi.FontEnumerator_GetFacenames(*args, **kwargs)
1820
8ab979d7 1821
d14a1e28
RD
1822class FontEnumeratorPtr(FontEnumerator):
1823 def __init__(self, this):
0569df0f 1824 self.this = this
d14a1e28
RD
1825 if not hasattr(self,"thisown"): self.thisown = 0
1826 self.__class__ = FontEnumerator
1827_gdi.FontEnumerator_swigregister(FontEnumeratorPtr)
1828
1829#---------------------------------------------------------------------------
1830
1831LANGUAGE_DEFAULT = _gdi.LANGUAGE_DEFAULT
1832LANGUAGE_UNKNOWN = _gdi.LANGUAGE_UNKNOWN
1833LANGUAGE_ABKHAZIAN = _gdi.LANGUAGE_ABKHAZIAN
1834LANGUAGE_AFAR = _gdi.LANGUAGE_AFAR
1835LANGUAGE_AFRIKAANS = _gdi.LANGUAGE_AFRIKAANS
1836LANGUAGE_ALBANIAN = _gdi.LANGUAGE_ALBANIAN
1837LANGUAGE_AMHARIC = _gdi.LANGUAGE_AMHARIC
1838LANGUAGE_ARABIC = _gdi.LANGUAGE_ARABIC
1839LANGUAGE_ARABIC_ALGERIA = _gdi.LANGUAGE_ARABIC_ALGERIA
1840LANGUAGE_ARABIC_BAHRAIN = _gdi.LANGUAGE_ARABIC_BAHRAIN
1841LANGUAGE_ARABIC_EGYPT = _gdi.LANGUAGE_ARABIC_EGYPT
1842LANGUAGE_ARABIC_IRAQ = _gdi.LANGUAGE_ARABIC_IRAQ
1843LANGUAGE_ARABIC_JORDAN = _gdi.LANGUAGE_ARABIC_JORDAN
1844LANGUAGE_ARABIC_KUWAIT = _gdi.LANGUAGE_ARABIC_KUWAIT
1845LANGUAGE_ARABIC_LEBANON = _gdi.LANGUAGE_ARABIC_LEBANON
1846LANGUAGE_ARABIC_LIBYA = _gdi.LANGUAGE_ARABIC_LIBYA
1847LANGUAGE_ARABIC_MOROCCO = _gdi.LANGUAGE_ARABIC_MOROCCO
1848LANGUAGE_ARABIC_OMAN = _gdi.LANGUAGE_ARABIC_OMAN
1849LANGUAGE_ARABIC_QATAR = _gdi.LANGUAGE_ARABIC_QATAR
1850LANGUAGE_ARABIC_SAUDI_ARABIA = _gdi.LANGUAGE_ARABIC_SAUDI_ARABIA
1851LANGUAGE_ARABIC_SUDAN = _gdi.LANGUAGE_ARABIC_SUDAN
1852LANGUAGE_ARABIC_SYRIA = _gdi.LANGUAGE_ARABIC_SYRIA
1853LANGUAGE_ARABIC_TUNISIA = _gdi.LANGUAGE_ARABIC_TUNISIA
1854LANGUAGE_ARABIC_UAE = _gdi.LANGUAGE_ARABIC_UAE
1855LANGUAGE_ARABIC_YEMEN = _gdi.LANGUAGE_ARABIC_YEMEN
1856LANGUAGE_ARMENIAN = _gdi.LANGUAGE_ARMENIAN
1857LANGUAGE_ASSAMESE = _gdi.LANGUAGE_ASSAMESE
1858LANGUAGE_AYMARA = _gdi.LANGUAGE_AYMARA
1859LANGUAGE_AZERI = _gdi.LANGUAGE_AZERI
1860LANGUAGE_AZERI_CYRILLIC = _gdi.LANGUAGE_AZERI_CYRILLIC
1861LANGUAGE_AZERI_LATIN = _gdi.LANGUAGE_AZERI_LATIN
1862LANGUAGE_BASHKIR = _gdi.LANGUAGE_BASHKIR
1863LANGUAGE_BASQUE = _gdi.LANGUAGE_BASQUE
1864LANGUAGE_BELARUSIAN = _gdi.LANGUAGE_BELARUSIAN
1865LANGUAGE_BENGALI = _gdi.LANGUAGE_BENGALI
1866LANGUAGE_BHUTANI = _gdi.LANGUAGE_BHUTANI
1867LANGUAGE_BIHARI = _gdi.LANGUAGE_BIHARI
1868LANGUAGE_BISLAMA = _gdi.LANGUAGE_BISLAMA
1869LANGUAGE_BRETON = _gdi.LANGUAGE_BRETON
1870LANGUAGE_BULGARIAN = _gdi.LANGUAGE_BULGARIAN
1871LANGUAGE_BURMESE = _gdi.LANGUAGE_BURMESE
1872LANGUAGE_CAMBODIAN = _gdi.LANGUAGE_CAMBODIAN
1873LANGUAGE_CATALAN = _gdi.LANGUAGE_CATALAN
1874LANGUAGE_CHINESE = _gdi.LANGUAGE_CHINESE
1875LANGUAGE_CHINESE_SIMPLIFIED = _gdi.LANGUAGE_CHINESE_SIMPLIFIED
1876LANGUAGE_CHINESE_TRADITIONAL = _gdi.LANGUAGE_CHINESE_TRADITIONAL
1877LANGUAGE_CHINESE_HONGKONG = _gdi.LANGUAGE_CHINESE_HONGKONG
1878LANGUAGE_CHINESE_MACAU = _gdi.LANGUAGE_CHINESE_MACAU
1879LANGUAGE_CHINESE_SINGAPORE = _gdi.LANGUAGE_CHINESE_SINGAPORE
1880LANGUAGE_CHINESE_TAIWAN = _gdi.LANGUAGE_CHINESE_TAIWAN
1881LANGUAGE_CORSICAN = _gdi.LANGUAGE_CORSICAN
1882LANGUAGE_CROATIAN = _gdi.LANGUAGE_CROATIAN
1883LANGUAGE_CZECH = _gdi.LANGUAGE_CZECH
1884LANGUAGE_DANISH = _gdi.LANGUAGE_DANISH
1885LANGUAGE_DUTCH = _gdi.LANGUAGE_DUTCH
1886LANGUAGE_DUTCH_BELGIAN = _gdi.LANGUAGE_DUTCH_BELGIAN
1887LANGUAGE_ENGLISH = _gdi.LANGUAGE_ENGLISH
1888LANGUAGE_ENGLISH_UK = _gdi.LANGUAGE_ENGLISH_UK
1889LANGUAGE_ENGLISH_US = _gdi.LANGUAGE_ENGLISH_US
1890LANGUAGE_ENGLISH_AUSTRALIA = _gdi.LANGUAGE_ENGLISH_AUSTRALIA
1891LANGUAGE_ENGLISH_BELIZE = _gdi.LANGUAGE_ENGLISH_BELIZE
1892LANGUAGE_ENGLISH_BOTSWANA = _gdi.LANGUAGE_ENGLISH_BOTSWANA
1893LANGUAGE_ENGLISH_CANADA = _gdi.LANGUAGE_ENGLISH_CANADA
1894LANGUAGE_ENGLISH_CARIBBEAN = _gdi.LANGUAGE_ENGLISH_CARIBBEAN
1895LANGUAGE_ENGLISH_DENMARK = _gdi.LANGUAGE_ENGLISH_DENMARK
1896LANGUAGE_ENGLISH_EIRE = _gdi.LANGUAGE_ENGLISH_EIRE
1897LANGUAGE_ENGLISH_JAMAICA = _gdi.LANGUAGE_ENGLISH_JAMAICA
1898LANGUAGE_ENGLISH_NEW_ZEALAND = _gdi.LANGUAGE_ENGLISH_NEW_ZEALAND
1899LANGUAGE_ENGLISH_PHILIPPINES = _gdi.LANGUAGE_ENGLISH_PHILIPPINES
1900LANGUAGE_ENGLISH_SOUTH_AFRICA = _gdi.LANGUAGE_ENGLISH_SOUTH_AFRICA
1901LANGUAGE_ENGLISH_TRINIDAD = _gdi.LANGUAGE_ENGLISH_TRINIDAD
1902LANGUAGE_ENGLISH_ZIMBABWE = _gdi.LANGUAGE_ENGLISH_ZIMBABWE
1903LANGUAGE_ESPERANTO = _gdi.LANGUAGE_ESPERANTO
1904LANGUAGE_ESTONIAN = _gdi.LANGUAGE_ESTONIAN
1905LANGUAGE_FAEROESE = _gdi.LANGUAGE_FAEROESE
1906LANGUAGE_FARSI = _gdi.LANGUAGE_FARSI
1907LANGUAGE_FIJI = _gdi.LANGUAGE_FIJI
1908LANGUAGE_FINNISH = _gdi.LANGUAGE_FINNISH
1909LANGUAGE_FRENCH = _gdi.LANGUAGE_FRENCH
1910LANGUAGE_FRENCH_BELGIAN = _gdi.LANGUAGE_FRENCH_BELGIAN
1911LANGUAGE_FRENCH_CANADIAN = _gdi.LANGUAGE_FRENCH_CANADIAN
1912LANGUAGE_FRENCH_LUXEMBOURG = _gdi.LANGUAGE_FRENCH_LUXEMBOURG
1913LANGUAGE_FRENCH_MONACO = _gdi.LANGUAGE_FRENCH_MONACO
1914LANGUAGE_FRENCH_SWISS = _gdi.LANGUAGE_FRENCH_SWISS
1915LANGUAGE_FRISIAN = _gdi.LANGUAGE_FRISIAN
1916LANGUAGE_GALICIAN = _gdi.LANGUAGE_GALICIAN
1917LANGUAGE_GEORGIAN = _gdi.LANGUAGE_GEORGIAN
1918LANGUAGE_GERMAN = _gdi.LANGUAGE_GERMAN
1919LANGUAGE_GERMAN_AUSTRIAN = _gdi.LANGUAGE_GERMAN_AUSTRIAN
1920LANGUAGE_GERMAN_BELGIUM = _gdi.LANGUAGE_GERMAN_BELGIUM
1921LANGUAGE_GERMAN_LIECHTENSTEIN = _gdi.LANGUAGE_GERMAN_LIECHTENSTEIN
1922LANGUAGE_GERMAN_LUXEMBOURG = _gdi.LANGUAGE_GERMAN_LUXEMBOURG
1923LANGUAGE_GERMAN_SWISS = _gdi.LANGUAGE_GERMAN_SWISS
1924LANGUAGE_GREEK = _gdi.LANGUAGE_GREEK
1925LANGUAGE_GREENLANDIC = _gdi.LANGUAGE_GREENLANDIC
1926LANGUAGE_GUARANI = _gdi.LANGUAGE_GUARANI
1927LANGUAGE_GUJARATI = _gdi.LANGUAGE_GUJARATI
1928LANGUAGE_HAUSA = _gdi.LANGUAGE_HAUSA
1929LANGUAGE_HEBREW = _gdi.LANGUAGE_HEBREW
1930LANGUAGE_HINDI = _gdi.LANGUAGE_HINDI
1931LANGUAGE_HUNGARIAN = _gdi.LANGUAGE_HUNGARIAN
1932LANGUAGE_ICELANDIC = _gdi.LANGUAGE_ICELANDIC
1933LANGUAGE_INDONESIAN = _gdi.LANGUAGE_INDONESIAN
1934LANGUAGE_INTERLINGUA = _gdi.LANGUAGE_INTERLINGUA
1935LANGUAGE_INTERLINGUE = _gdi.LANGUAGE_INTERLINGUE
1936LANGUAGE_INUKTITUT = _gdi.LANGUAGE_INUKTITUT
1937LANGUAGE_INUPIAK = _gdi.LANGUAGE_INUPIAK
1938LANGUAGE_IRISH = _gdi.LANGUAGE_IRISH
1939LANGUAGE_ITALIAN = _gdi.LANGUAGE_ITALIAN
1940LANGUAGE_ITALIAN_SWISS = _gdi.LANGUAGE_ITALIAN_SWISS
1941LANGUAGE_JAPANESE = _gdi.LANGUAGE_JAPANESE
1942LANGUAGE_JAVANESE = _gdi.LANGUAGE_JAVANESE
1943LANGUAGE_KANNADA = _gdi.LANGUAGE_KANNADA
1944LANGUAGE_KASHMIRI = _gdi.LANGUAGE_KASHMIRI
1945LANGUAGE_KASHMIRI_INDIA = _gdi.LANGUAGE_KASHMIRI_INDIA
1946LANGUAGE_KAZAKH = _gdi.LANGUAGE_KAZAKH
1947LANGUAGE_KERNEWEK = _gdi.LANGUAGE_KERNEWEK
1948LANGUAGE_KINYARWANDA = _gdi.LANGUAGE_KINYARWANDA
1949LANGUAGE_KIRGHIZ = _gdi.LANGUAGE_KIRGHIZ
1950LANGUAGE_KIRUNDI = _gdi.LANGUAGE_KIRUNDI
1951LANGUAGE_KONKANI = _gdi.LANGUAGE_KONKANI
1952LANGUAGE_KOREAN = _gdi.LANGUAGE_KOREAN
1953LANGUAGE_KURDISH = _gdi.LANGUAGE_KURDISH
1954LANGUAGE_LAOTHIAN = _gdi.LANGUAGE_LAOTHIAN
1955LANGUAGE_LATIN = _gdi.LANGUAGE_LATIN
1956LANGUAGE_LATVIAN = _gdi.LANGUAGE_LATVIAN
1957LANGUAGE_LINGALA = _gdi.LANGUAGE_LINGALA
1958LANGUAGE_LITHUANIAN = _gdi.LANGUAGE_LITHUANIAN
1959LANGUAGE_MACEDONIAN = _gdi.LANGUAGE_MACEDONIAN
1960LANGUAGE_MALAGASY = _gdi.LANGUAGE_MALAGASY
1961LANGUAGE_MALAY = _gdi.LANGUAGE_MALAY
1962LANGUAGE_MALAYALAM = _gdi.LANGUAGE_MALAYALAM
1963LANGUAGE_MALAY_BRUNEI_DARUSSALAM = _gdi.LANGUAGE_MALAY_BRUNEI_DARUSSALAM
1964LANGUAGE_MALAY_MALAYSIA = _gdi.LANGUAGE_MALAY_MALAYSIA
1965LANGUAGE_MALTESE = _gdi.LANGUAGE_MALTESE
1966LANGUAGE_MANIPURI = _gdi.LANGUAGE_MANIPURI
1967LANGUAGE_MAORI = _gdi.LANGUAGE_MAORI
1968LANGUAGE_MARATHI = _gdi.LANGUAGE_MARATHI
1969LANGUAGE_MOLDAVIAN = _gdi.LANGUAGE_MOLDAVIAN
1970LANGUAGE_MONGOLIAN = _gdi.LANGUAGE_MONGOLIAN
1971LANGUAGE_NAURU = _gdi.LANGUAGE_NAURU
1972LANGUAGE_NEPALI = _gdi.LANGUAGE_NEPALI
1973LANGUAGE_NEPALI_INDIA = _gdi.LANGUAGE_NEPALI_INDIA
1974LANGUAGE_NORWEGIAN_BOKMAL = _gdi.LANGUAGE_NORWEGIAN_BOKMAL
1975LANGUAGE_NORWEGIAN_NYNORSK = _gdi.LANGUAGE_NORWEGIAN_NYNORSK
1976LANGUAGE_OCCITAN = _gdi.LANGUAGE_OCCITAN
1977LANGUAGE_ORIYA = _gdi.LANGUAGE_ORIYA
1978LANGUAGE_OROMO = _gdi.LANGUAGE_OROMO
1979LANGUAGE_PASHTO = _gdi.LANGUAGE_PASHTO
1980LANGUAGE_POLISH = _gdi.LANGUAGE_POLISH
1981LANGUAGE_PORTUGUESE = _gdi.LANGUAGE_PORTUGUESE
1982LANGUAGE_PORTUGUESE_BRAZILIAN = _gdi.LANGUAGE_PORTUGUESE_BRAZILIAN
1983LANGUAGE_PUNJABI = _gdi.LANGUAGE_PUNJABI
1984LANGUAGE_QUECHUA = _gdi.LANGUAGE_QUECHUA
1985LANGUAGE_RHAETO_ROMANCE = _gdi.LANGUAGE_RHAETO_ROMANCE
1986LANGUAGE_ROMANIAN = _gdi.LANGUAGE_ROMANIAN
1987LANGUAGE_RUSSIAN = _gdi.LANGUAGE_RUSSIAN
1988LANGUAGE_RUSSIAN_UKRAINE = _gdi.LANGUAGE_RUSSIAN_UKRAINE
1989LANGUAGE_SAMOAN = _gdi.LANGUAGE_SAMOAN
1990LANGUAGE_SANGHO = _gdi.LANGUAGE_SANGHO
1991LANGUAGE_SANSKRIT = _gdi.LANGUAGE_SANSKRIT
1992LANGUAGE_SCOTS_GAELIC = _gdi.LANGUAGE_SCOTS_GAELIC
1993LANGUAGE_SERBIAN = _gdi.LANGUAGE_SERBIAN
1994LANGUAGE_SERBIAN_CYRILLIC = _gdi.LANGUAGE_SERBIAN_CYRILLIC
1995LANGUAGE_SERBIAN_LATIN = _gdi.LANGUAGE_SERBIAN_LATIN
1996LANGUAGE_SERBO_CROATIAN = _gdi.LANGUAGE_SERBO_CROATIAN
1997LANGUAGE_SESOTHO = _gdi.LANGUAGE_SESOTHO
1998LANGUAGE_SETSWANA = _gdi.LANGUAGE_SETSWANA
1999LANGUAGE_SHONA = _gdi.LANGUAGE_SHONA
2000LANGUAGE_SINDHI = _gdi.LANGUAGE_SINDHI
2001LANGUAGE_SINHALESE = _gdi.LANGUAGE_SINHALESE
2002LANGUAGE_SISWATI = _gdi.LANGUAGE_SISWATI
2003LANGUAGE_SLOVAK = _gdi.LANGUAGE_SLOVAK
2004LANGUAGE_SLOVENIAN = _gdi.LANGUAGE_SLOVENIAN
2005LANGUAGE_SOMALI = _gdi.LANGUAGE_SOMALI
2006LANGUAGE_SPANISH = _gdi.LANGUAGE_SPANISH
2007LANGUAGE_SPANISH_ARGENTINA = _gdi.LANGUAGE_SPANISH_ARGENTINA
2008LANGUAGE_SPANISH_BOLIVIA = _gdi.LANGUAGE_SPANISH_BOLIVIA
2009LANGUAGE_SPANISH_CHILE = _gdi.LANGUAGE_SPANISH_CHILE
2010LANGUAGE_SPANISH_COLOMBIA = _gdi.LANGUAGE_SPANISH_COLOMBIA
2011LANGUAGE_SPANISH_COSTA_RICA = _gdi.LANGUAGE_SPANISH_COSTA_RICA
2012LANGUAGE_SPANISH_DOMINICAN_REPUBLIC = _gdi.LANGUAGE_SPANISH_DOMINICAN_REPUBLIC
2013LANGUAGE_SPANISH_ECUADOR = _gdi.LANGUAGE_SPANISH_ECUADOR
2014LANGUAGE_SPANISH_EL_SALVADOR = _gdi.LANGUAGE_SPANISH_EL_SALVADOR
2015LANGUAGE_SPANISH_GUATEMALA = _gdi.LANGUAGE_SPANISH_GUATEMALA
2016LANGUAGE_SPANISH_HONDURAS = _gdi.LANGUAGE_SPANISH_HONDURAS
2017LANGUAGE_SPANISH_MEXICAN = _gdi.LANGUAGE_SPANISH_MEXICAN
2018LANGUAGE_SPANISH_MODERN = _gdi.LANGUAGE_SPANISH_MODERN
2019LANGUAGE_SPANISH_NICARAGUA = _gdi.LANGUAGE_SPANISH_NICARAGUA
2020LANGUAGE_SPANISH_PANAMA = _gdi.LANGUAGE_SPANISH_PANAMA
2021LANGUAGE_SPANISH_PARAGUAY = _gdi.LANGUAGE_SPANISH_PARAGUAY
2022LANGUAGE_SPANISH_PERU = _gdi.LANGUAGE_SPANISH_PERU
2023LANGUAGE_SPANISH_PUERTO_RICO = _gdi.LANGUAGE_SPANISH_PUERTO_RICO
2024LANGUAGE_SPANISH_URUGUAY = _gdi.LANGUAGE_SPANISH_URUGUAY
2025LANGUAGE_SPANISH_US = _gdi.LANGUAGE_SPANISH_US
2026LANGUAGE_SPANISH_VENEZUELA = _gdi.LANGUAGE_SPANISH_VENEZUELA
2027LANGUAGE_SUNDANESE = _gdi.LANGUAGE_SUNDANESE
2028LANGUAGE_SWAHILI = _gdi.LANGUAGE_SWAHILI
2029LANGUAGE_SWEDISH = _gdi.LANGUAGE_SWEDISH
2030LANGUAGE_SWEDISH_FINLAND = _gdi.LANGUAGE_SWEDISH_FINLAND
2031LANGUAGE_TAGALOG = _gdi.LANGUAGE_TAGALOG
2032LANGUAGE_TAJIK = _gdi.LANGUAGE_TAJIK
2033LANGUAGE_TAMIL = _gdi.LANGUAGE_TAMIL
2034LANGUAGE_TATAR = _gdi.LANGUAGE_TATAR
2035LANGUAGE_TELUGU = _gdi.LANGUAGE_TELUGU
2036LANGUAGE_THAI = _gdi.LANGUAGE_THAI
2037LANGUAGE_TIBETAN = _gdi.LANGUAGE_TIBETAN
2038LANGUAGE_TIGRINYA = _gdi.LANGUAGE_TIGRINYA
2039LANGUAGE_TONGA = _gdi.LANGUAGE_TONGA
2040LANGUAGE_TSONGA = _gdi.LANGUAGE_TSONGA
2041LANGUAGE_TURKISH = _gdi.LANGUAGE_TURKISH
2042LANGUAGE_TURKMEN = _gdi.LANGUAGE_TURKMEN
2043LANGUAGE_TWI = _gdi.LANGUAGE_TWI
2044LANGUAGE_UIGHUR = _gdi.LANGUAGE_UIGHUR
2045LANGUAGE_UKRAINIAN = _gdi.LANGUAGE_UKRAINIAN
2046LANGUAGE_URDU = _gdi.LANGUAGE_URDU
2047LANGUAGE_URDU_INDIA = _gdi.LANGUAGE_URDU_INDIA
2048LANGUAGE_URDU_PAKISTAN = _gdi.LANGUAGE_URDU_PAKISTAN
2049LANGUAGE_UZBEK = _gdi.LANGUAGE_UZBEK
2050LANGUAGE_UZBEK_CYRILLIC = _gdi.LANGUAGE_UZBEK_CYRILLIC
2051LANGUAGE_UZBEK_LATIN = _gdi.LANGUAGE_UZBEK_LATIN
2052LANGUAGE_VIETNAMESE = _gdi.LANGUAGE_VIETNAMESE
2053LANGUAGE_VOLAPUK = _gdi.LANGUAGE_VOLAPUK
2054LANGUAGE_WELSH = _gdi.LANGUAGE_WELSH
2055LANGUAGE_WOLOF = _gdi.LANGUAGE_WOLOF
2056LANGUAGE_XHOSA = _gdi.LANGUAGE_XHOSA
2057LANGUAGE_YIDDISH = _gdi.LANGUAGE_YIDDISH
2058LANGUAGE_YORUBA = _gdi.LANGUAGE_YORUBA
2059LANGUAGE_ZHUANG = _gdi.LANGUAGE_ZHUANG
2060LANGUAGE_ZULU = _gdi.LANGUAGE_ZULU
2061LANGUAGE_USER_DEFINED = _gdi.LANGUAGE_USER_DEFINED
2062class LanguageInfo(object):
d14a1e28 2063 def __init__(self): raise RuntimeError, "No constructor defined"
0569df0f 2064 def __repr__(self):
d14a1e28 2065 return "<%s.%s; proxy of C++ wxLanguageInfo instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
423f194a
RD
2066 Language = property(_gdi.LanguageInfo_Language_get, _gdi.LanguageInfo_Language_set)
2067 CanonicalName = property(_gdi.LanguageInfo_CanonicalName_get, _gdi.LanguageInfo_CanonicalName_set)
2068 Description = property(_gdi.LanguageInfo_Description_get, _gdi.LanguageInfo_Description_set)
d14a1e28
RD
2069
2070class LanguageInfoPtr(LanguageInfo):
2071 def __init__(self, this):
0569df0f 2072 self.this = this
d14a1e28
RD
2073 if not hasattr(self,"thisown"): self.thisown = 0
2074 self.__class__ = LanguageInfo
2075_gdi.LanguageInfo_swigregister(LanguageInfoPtr)
2076
2077LOCALE_CAT_NUMBER = _gdi.LOCALE_CAT_NUMBER
2078LOCALE_CAT_DATE = _gdi.LOCALE_CAT_DATE
2079LOCALE_CAT_MONEY = _gdi.LOCALE_CAT_MONEY
2080LOCALE_CAT_MAX = _gdi.LOCALE_CAT_MAX
2081LOCALE_THOUSANDS_SEP = _gdi.LOCALE_THOUSANDS_SEP
2082LOCALE_DECIMAL_POINT = _gdi.LOCALE_DECIMAL_POINT
2083LOCALE_LOAD_DEFAULT = _gdi.LOCALE_LOAD_DEFAULT
2084LOCALE_CONV_ENCODING = _gdi.LOCALE_CONV_ENCODING
2085class Locale(object):
423f194a
RD
2086 def __repr__(self):
2087 return "<%s.%s; proxy of C++ wxLocale instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 2088 def __init__(self, *args, **kwargs):
423f194a 2089 """__init__(int language=LANGUAGE_DEFAULT, int flags=wxLOCALE_LOAD_DEFAULT|wxLOCALE_CONV_ENCODING) -> Locale"""
d14a1e28
RD
2090 newobj = _gdi.new_Locale(*args, **kwargs)
2091 self.this = newobj.this
2092 self.thisown = 1
2093 del newobj.thisown
2094 def __del__(self, destroy=_gdi.delete_Locale):
423f194a 2095 """__del__()"""
d14a1e28
RD
2096 try:
2097 if self.thisown: destroy(self)
2098 except: pass
423f194a
RD
2099
2100 def Init1(*args, **kwargs):
41f1cec7 2101 """
d03fd34d
RD
2102 Init1(String szName, String szShort=EmptyString, String szLocale=EmptyString,
2103 bool bLoadDefault=True,
41f1cec7
RD
2104 bool bConvertEncoding=False) -> bool
2105 """
423f194a
RD
2106 return _gdi.Locale_Init1(*args, **kwargs)
2107
2108 def Init2(*args, **kwargs):
2109 """Init2(int language=LANGUAGE_DEFAULT, int flags=wxLOCALE_LOAD_DEFAULT|wxLOCALE_CONV_ENCODING) -> bool"""
2110 return _gdi.Locale_Init2(*args, **kwargs)
2111
d14a1e28
RD
2112 def Init(self, *_args, **_kwargs):
2113 if type(_args[0]) in [type(''), type(u'')]:
2114 val = self.Init1(*_args, **_kwargs)
2115 else:
2116 val = self.Init2(*_args, **_kwargs)
2117 return val
2118
423f194a 2119 def GetSystemLanguage(*args, **kwargs):
83448d71 2120 """GetSystemLanguage() -> int"""
423f194a
RD
2121 return _gdi.Locale_GetSystemLanguage(*args, **kwargs)
2122
2123 GetSystemLanguage = staticmethod(GetSystemLanguage)
2124 def GetSystemEncoding(*args, **kwargs):
83448d71 2125 """GetSystemEncoding() -> int"""
423f194a
RD
2126 return _gdi.Locale_GetSystemEncoding(*args, **kwargs)
2127
2128 GetSystemEncoding = staticmethod(GetSystemEncoding)
2129 def GetSystemEncodingName(*args, **kwargs):
83448d71 2130 """GetSystemEncodingName() -> String"""
423f194a
RD
2131 return _gdi.Locale_GetSystemEncodingName(*args, **kwargs)
2132
2133 GetSystemEncodingName = staticmethod(GetSystemEncodingName)
2134 def IsOk(*args, **kwargs):
2135 """IsOk() -> bool"""
2136 return _gdi.Locale_IsOk(*args, **kwargs)
2137
d14a1e28 2138 def __nonzero__(self): return self.IsOk()
423f194a 2139 def GetLocale(*args, **kwargs):
d03fd34d 2140 """GetLocale() -> String"""
423f194a
RD
2141 return _gdi.Locale_GetLocale(*args, **kwargs)
2142
2143 def GetLanguage(*args, **kwargs):
2144 """GetLanguage() -> int"""
2145 return _gdi.Locale_GetLanguage(*args, **kwargs)
2146
2147 def GetSysName(*args, **kwargs):
d03fd34d 2148 """GetSysName() -> String"""
423f194a
RD
2149 return _gdi.Locale_GetSysName(*args, **kwargs)
2150
2151 def GetCanonicalName(*args, **kwargs):
d03fd34d 2152 """GetCanonicalName() -> String"""
423f194a
RD
2153 return _gdi.Locale_GetCanonicalName(*args, **kwargs)
2154
2155 def AddCatalogLookupPathPrefix(*args, **kwargs):
83448d71 2156 """AddCatalogLookupPathPrefix(String prefix)"""
423f194a
RD
2157 return _gdi.Locale_AddCatalogLookupPathPrefix(*args, **kwargs)
2158
2159 AddCatalogLookupPathPrefix = staticmethod(AddCatalogLookupPathPrefix)
2160 def AddCatalog(*args, **kwargs):
d03fd34d 2161 """AddCatalog(String szDomain) -> bool"""
423f194a
RD
2162 return _gdi.Locale_AddCatalog(*args, **kwargs)
2163
2164 def IsLoaded(*args, **kwargs):
d03fd34d 2165 """IsLoaded(String szDomain) -> bool"""
423f194a
RD
2166 return _gdi.Locale_IsLoaded(*args, **kwargs)
2167
2168 def GetLanguageInfo(*args, **kwargs):
83448d71 2169 """GetLanguageInfo(int lang) -> LanguageInfo"""
423f194a
RD
2170 return _gdi.Locale_GetLanguageInfo(*args, **kwargs)
2171
2172 GetLanguageInfo = staticmethod(GetLanguageInfo)
2173 def GetLanguageName(*args, **kwargs):
83448d71 2174 """GetLanguageName(int lang) -> String"""
423f194a
RD
2175 return _gdi.Locale_GetLanguageName(*args, **kwargs)
2176
2177 GetLanguageName = staticmethod(GetLanguageName)
2178 def FindLanguageInfo(*args, **kwargs):
83448d71 2179 """FindLanguageInfo(String locale) -> LanguageInfo"""
423f194a
RD
2180 return _gdi.Locale_FindLanguageInfo(*args, **kwargs)
2181
2182 FindLanguageInfo = staticmethod(FindLanguageInfo)
2183 def AddLanguage(*args, **kwargs):
83448d71 2184 """AddLanguage(LanguageInfo info)"""
423f194a
RD
2185 return _gdi.Locale_AddLanguage(*args, **kwargs)
2186
2187 AddLanguage = staticmethod(AddLanguage)
2188 def GetString(*args, **kwargs):
d03fd34d 2189 """GetString(String szOrigString, String szDomain=EmptyString) -> String"""
423f194a
RD
2190 return _gdi.Locale_GetString(*args, **kwargs)
2191
2192 def GetName(*args, **kwargs):
d03fd34d 2193 """GetName() -> String"""
423f194a
RD
2194 return _gdi.Locale_GetName(*args, **kwargs)
2195
0569df0f 2196
d14a1e28
RD
2197class LocalePtr(Locale):
2198 def __init__(self, this):
2199 self.this = this
2200 if not hasattr(self,"thisown"): self.thisown = 0
2201 self.__class__ = Locale
2202_gdi.Locale_swigregister(LocalePtr)
0569df0f 2203
423f194a
RD
2204def Locale_GetSystemLanguage(*args, **kwargs):
2205 """Locale_GetSystemLanguage() -> int"""
2206 return _gdi.Locale_GetSystemLanguage(*args, **kwargs)
0569df0f 2207
423f194a 2208def Locale_GetSystemEncoding(*args, **kwargs):
d03fd34d 2209 """Locale_GetSystemEncoding() -> int"""
423f194a 2210 return _gdi.Locale_GetSystemEncoding(*args, **kwargs)
0569df0f 2211
423f194a 2212def Locale_GetSystemEncodingName(*args, **kwargs):
d03fd34d 2213 """Locale_GetSystemEncodingName() -> String"""
423f194a 2214 return _gdi.Locale_GetSystemEncodingName(*args, **kwargs)
d14a1e28 2215
423f194a 2216def Locale_AddCatalogLookupPathPrefix(*args, **kwargs):
d03fd34d 2217 """Locale_AddCatalogLookupPathPrefix(String prefix)"""
423f194a 2218 return _gdi.Locale_AddCatalogLookupPathPrefix(*args, **kwargs)
d14a1e28 2219
423f194a
RD
2220def Locale_GetLanguageInfo(*args, **kwargs):
2221 """Locale_GetLanguageInfo(int lang) -> LanguageInfo"""
2222 return _gdi.Locale_GetLanguageInfo(*args, **kwargs)
d14a1e28 2223
423f194a 2224def Locale_GetLanguageName(*args, **kwargs):
d03fd34d 2225 """Locale_GetLanguageName(int lang) -> String"""
423f194a 2226 return _gdi.Locale_GetLanguageName(*args, **kwargs)
d14a1e28 2227
423f194a 2228def Locale_FindLanguageInfo(*args, **kwargs):
d03fd34d 2229 """Locale_FindLanguageInfo(String locale) -> LanguageInfo"""
423f194a 2230 return _gdi.Locale_FindLanguageInfo(*args, **kwargs)
d14a1e28 2231
423f194a
RD
2232def Locale_AddLanguage(*args, **kwargs):
2233 """Locale_AddLanguage(LanguageInfo info)"""
2234 return _gdi.Locale_AddLanguage(*args, **kwargs)
d14a1e28
RD
2235
2236
423f194a
RD
2237def GetLocale(*args, **kwargs):
2238 """GetLocale() -> Locale"""
2239 return _gdi.GetLocale(*args, **kwargs)
d14a1e28
RD
2240#---------------------------------------------------------------------------
2241
2242CONVERT_STRICT = _gdi.CONVERT_STRICT
2243CONVERT_SUBSTITUTE = _gdi.CONVERT_SUBSTITUTE
2244PLATFORM_CURRENT = _gdi.PLATFORM_CURRENT
2245PLATFORM_UNIX = _gdi.PLATFORM_UNIX
2246PLATFORM_WINDOWS = _gdi.PLATFORM_WINDOWS
2247PLATFORM_OS2 = _gdi.PLATFORM_OS2
2248PLATFORM_MAC = _gdi.PLATFORM_MAC
2249class EncodingConverter(core.Object):
423f194a
RD
2250 def __repr__(self):
2251 return "<%s.%s; proxy of C++ wxEncodingConverter instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 2252 def __init__(self, *args, **kwargs):
423f194a 2253 """__init__() -> EncodingConverter"""
d14a1e28
RD
2254 newobj = _gdi.new_EncodingConverter(*args, **kwargs)
2255 self.this = newobj.this
2256 self.thisown = 1
2257 del newobj.thisown
2258 def __del__(self, destroy=_gdi.delete_EncodingConverter):
423f194a 2259 """__del__()"""
d14a1e28
RD
2260 try:
2261 if self.thisown: destroy(self)
2262 except: pass
423f194a
RD
2263
2264 def Init(*args, **kwargs):
d03fd34d 2265 """Init(int input_enc, int output_enc, int method=CONVERT_STRICT) -> bool"""
423f194a
RD
2266 return _gdi.EncodingConverter_Init(*args, **kwargs)
2267
2268 def Convert(*args, **kwargs):
d03fd34d 2269 """Convert(String input) -> String"""
423f194a
RD
2270 return _gdi.EncodingConverter_Convert(*args, **kwargs)
2271
2272 def GetPlatformEquivalents(*args, **kwargs):
83448d71 2273 """GetPlatformEquivalents(int enc, int platform=PLATFORM_CURRENT) -> wxFontEncodingArray"""
423f194a
RD
2274 return _gdi.EncodingConverter_GetPlatformEquivalents(*args, **kwargs)
2275
2276 GetPlatformEquivalents = staticmethod(GetPlatformEquivalents)
2277 def GetAllEquivalents(*args, **kwargs):
83448d71 2278 """GetAllEquivalents(int enc) -> wxFontEncodingArray"""
423f194a
RD
2279 return _gdi.EncodingConverter_GetAllEquivalents(*args, **kwargs)
2280
2281 GetAllEquivalents = staticmethod(GetAllEquivalents)
2282 def CanConvert(*args, **kwargs):
83448d71 2283 """CanConvert(int encIn, int encOut) -> bool"""
423f194a
RD
2284 return _gdi.EncodingConverter_CanConvert(*args, **kwargs)
2285
2286 CanConvert = staticmethod(CanConvert)
d14a1e28 2287 def __nonzero__(self): return self.IsOk()
d14a1e28
RD
2288
2289class EncodingConverterPtr(EncodingConverter):
2290 def __init__(self, this):
2291 self.this = this
2292 if not hasattr(self,"thisown"): self.thisown = 0
2293 self.__class__ = EncodingConverter
2294_gdi.EncodingConverter_swigregister(EncodingConverterPtr)
2295
423f194a 2296def GetTranslation(*args):
41f1cec7 2297 """
db914595
RD
2298 GetTranslation(String str) -> String
2299 GetTranslation(String str, String strPlural, size_t n) -> String
41f1cec7 2300 """
423f194a 2301 return _gdi.GetTranslation(*args)
d14a1e28 2302
423f194a 2303def EncodingConverter_GetPlatformEquivalents(*args, **kwargs):
d03fd34d 2304 """EncodingConverter_GetPlatformEquivalents(int enc, int platform=PLATFORM_CURRENT) -> wxFontEncodingArray"""
423f194a 2305 return _gdi.EncodingConverter_GetPlatformEquivalents(*args, **kwargs)
d14a1e28 2306
423f194a 2307def EncodingConverter_GetAllEquivalents(*args, **kwargs):
d03fd34d 2308 """EncodingConverter_GetAllEquivalents(int enc) -> wxFontEncodingArray"""
423f194a 2309 return _gdi.EncodingConverter_GetAllEquivalents(*args, **kwargs)
d14a1e28 2310
423f194a 2311def EncodingConverter_CanConvert(*args, **kwargs):
d03fd34d 2312 """EncodingConverter_CanConvert(int encIn, int encOut) -> bool"""
423f194a 2313 return _gdi.EncodingConverter_CanConvert(*args, **kwargs)
d14a1e28
RD
2314
2315#----------------------------------------------------------------------------
2316# wxGTK sets the locale when initialized. Doing this at the Python
2317# level should set it up to match what GTK is doing at the C level.
2318if wx.Platform == "__WXGTK__":
2319 try:
2320 import locale
2321 locale.setlocale(locale.LC_ALL, "")
2322 except:
2323 pass
2324
2325# On MSW add the directory where the wxWindows catalogs were installed
2326# to the default catalog path.
2327if wx.Platform == "__WXMSW__":
2328 import os
2329 localedir = os.path.join(os.path.split(__file__)[0], "locale")
2330 Locale_AddCatalogLookupPathPrefix(localedir)
2331 del os
2332
2333#----------------------------------------------------------------------------
2334
2335#---------------------------------------------------------------------------
2336
2337class DC(core.Object):
423f194a
RD
2338 def __init__(self): raise RuntimeError, "No constructor defined"
2339 def __repr__(self):
2340 return "<%s.%s; proxy of C++ wxDC instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 2341 def __del__(self, destroy=_gdi.delete_DC):
423f194a 2342 """__del__()"""
d14a1e28
RD
2343 try:
2344 if self.thisown: destroy(self)
2345 except: pass
423f194a
RD
2346
2347 def BeginDrawing(*args, **kwargs):
2348 """BeginDrawing()"""
2349 return _gdi.DC_BeginDrawing(*args, **kwargs)
2350
2351 def EndDrawing(*args, **kwargs):
2352 """EndDrawing()"""
2353 return _gdi.DC_EndDrawing(*args, **kwargs)
2354
2355 def FloodFillXY(*args, **kwargs):
2356 """FloodFillXY(int x, int y, Colour col, int style=FLOOD_SURFACE) -> bool"""
2357 return _gdi.DC_FloodFillXY(*args, **kwargs)
2358
2359 def FloodFill(*args, **kwargs):
2360 """FloodFill(Point pt, Colour col, int style=FLOOD_SURFACE) -> bool"""
2361 return _gdi.DC_FloodFill(*args, **kwargs)
2362
2363 def GetPixelXY(*args, **kwargs):
2364 """GetPixelXY(int x, int y) -> Colour"""
2365 return _gdi.DC_GetPixelXY(*args, **kwargs)
2366
2367 def GetPixel(*args, **kwargs):
2368 """GetPixel(Point pt) -> Colour"""
2369 return _gdi.DC_GetPixel(*args, **kwargs)
2370
2371 def DrawLineXY(*args, **kwargs):
2372 """DrawLineXY(int x1, int y1, int x2, int y2)"""
2373 return _gdi.DC_DrawLineXY(*args, **kwargs)
2374
2375 def DrawLine(*args, **kwargs):
2376 """DrawLine(Point pt1, Point pt2)"""
2377 return _gdi.DC_DrawLine(*args, **kwargs)
2378
2379 def CrossHairXY(*args, **kwargs):
2380 """CrossHairXY(int x, int y)"""
2381 return _gdi.DC_CrossHairXY(*args, **kwargs)
2382
2383 def CrossHair(*args, **kwargs):
2384 """CrossHair(Point pt)"""
2385 return _gdi.DC_CrossHair(*args, **kwargs)
2386
2387 def DrawArcXY(*args, **kwargs):
2388 """DrawArcXY(int x1, int y1, int x2, int y2, int xc, int yc)"""
2389 return _gdi.DC_DrawArcXY(*args, **kwargs)
2390
2391 def DrawArc(*args, **kwargs):
2392 """DrawArc(Point pt1, Point pt2, Point centre)"""
2393 return _gdi.DC_DrawArc(*args, **kwargs)
2394
2395 def DrawCheckMarkXY(*args, **kwargs):
2396 """DrawCheckMarkXY(int x, int y, int width, int height)"""
2397 return _gdi.DC_DrawCheckMarkXY(*args, **kwargs)
2398
2399 def DrawCheckMark(*args, **kwargs):
2400 """DrawCheckMark(Rect rect)"""
2401 return _gdi.DC_DrawCheckMark(*args, **kwargs)
2402
2403 def DrawEllipticArcXY(*args, **kwargs):
2404 """DrawEllipticArcXY(int x, int y, int w, int h, double sa, double ea)"""
2405 return _gdi.DC_DrawEllipticArcXY(*args, **kwargs)
2406
2407 def DrawEllipticArc(*args, **kwargs):
2408 """DrawEllipticArc(Point pt, Size sz, double sa, double ea)"""
2409 return _gdi.DC_DrawEllipticArc(*args, **kwargs)
2410
2411 def DrawPointXY(*args, **kwargs):
2412 """DrawPointXY(int x, int y)"""
2413 return _gdi.DC_DrawPointXY(*args, **kwargs)
2414
2415 def DrawPoint(*args, **kwargs):
2416 """DrawPoint(Point pt)"""
2417 return _gdi.DC_DrawPoint(*args, **kwargs)
2418
2419 def DrawRectangleXY(*args, **kwargs):
2420 """DrawRectangleXY(int x, int y, int width, int height)"""
2421 return _gdi.DC_DrawRectangleXY(*args, **kwargs)
2422
2423 def DrawRectangle(*args, **kwargs):
2424 """DrawRectangle(Point pt, Size sz)"""
2425 return _gdi.DC_DrawRectangle(*args, **kwargs)
2426
2427 def DrawRectangleRect(*args, **kwargs):
2428 """DrawRectangleRect(Rect rect)"""
2429 return _gdi.DC_DrawRectangleRect(*args, **kwargs)
2430
2431 def DrawRoundedRectangleXY(*args, **kwargs):
2432 """DrawRoundedRectangleXY(int x, int y, int width, int height, double radius)"""
2433 return _gdi.DC_DrawRoundedRectangleXY(*args, **kwargs)
2434
2435 def DrawRoundedRectangle(*args, **kwargs):
2436 """DrawRoundedRectangle(Point pt, Size sz, double radius)"""
2437 return _gdi.DC_DrawRoundedRectangle(*args, **kwargs)
2438
2439 def DrawRoundedRectangleRect(*args, **kwargs):
2440 """DrawRoundedRectangleRect(Rect r, double radius)"""
2441 return _gdi.DC_DrawRoundedRectangleRect(*args, **kwargs)
2442
2443 def DrawCircleXY(*args, **kwargs):
2444 """DrawCircleXY(int x, int y, int radius)"""
2445 return _gdi.DC_DrawCircleXY(*args, **kwargs)
2446
2447 def DrawCircle(*args, **kwargs):
2448 """DrawCircle(Point pt, int radius)"""
2449 return _gdi.DC_DrawCircle(*args, **kwargs)
2450
2451 def DrawEllipseXY(*args, **kwargs):
2452 """DrawEllipseXY(int x, int y, int width, int height)"""
2453 return _gdi.DC_DrawEllipseXY(*args, **kwargs)
2454
2455 def DrawEllipse(*args, **kwargs):
2456 """DrawEllipse(Point pt, Size sz)"""
2457 return _gdi.DC_DrawEllipse(*args, **kwargs)
2458
2459 def DrawEllipseRect(*args, **kwargs):
2460 """DrawEllipseRect(Rect rect)"""
2461 return _gdi.DC_DrawEllipseRect(*args, **kwargs)
2462
2463 def DrawIconXY(*args, **kwargs):
2464 """DrawIconXY(Icon icon, int x, int y)"""
2465 return _gdi.DC_DrawIconXY(*args, **kwargs)
2466
2467 def DrawIcon(*args, **kwargs):
2468 """DrawIcon(Icon icon, Point pt)"""
2469 return _gdi.DC_DrawIcon(*args, **kwargs)
2470
2471 def DrawBitmapXY(*args, **kwargs):
2472 """DrawBitmapXY(Bitmap bmp, int x, int y, bool useMask=False)"""
2473 return _gdi.DC_DrawBitmapXY(*args, **kwargs)
2474
2475 def DrawBitmap(*args, **kwargs):
2476 """DrawBitmap(Bitmap bmp, Point pt, bool useMask=False)"""
2477 return _gdi.DC_DrawBitmap(*args, **kwargs)
2478
2479 def DrawTextXY(*args, **kwargs):
d03fd34d 2480 """DrawTextXY(String text, int x, int y)"""
423f194a
RD
2481 return _gdi.DC_DrawTextXY(*args, **kwargs)
2482
2483 def DrawText(*args, **kwargs):
d03fd34d 2484 """DrawText(String text, Point pt)"""
423f194a
RD
2485 return _gdi.DC_DrawText(*args, **kwargs)
2486
2487 def DrawRotatedTextXY(*args, **kwargs):
d03fd34d 2488 """DrawRotatedTextXY(String text, int x, int y, double angle)"""
423f194a
RD
2489 return _gdi.DC_DrawRotatedTextXY(*args, **kwargs)
2490
2491 def DrawRotatedText(*args, **kwargs):
d03fd34d 2492 """DrawRotatedText(String text, Point pt, double angle)"""
423f194a
RD
2493 return _gdi.DC_DrawRotatedText(*args, **kwargs)
2494
2495 def BlitXY(*args, **kwargs):
41f1cec7
RD
2496 """
2497 BlitXY(int xdest, int ydest, int width, int height, DC source,
2498 int xsrc, int ysrc, int rop=COPY, bool useMask=False,
2499 int xsrcMask=-1, int ysrcMask=-1) -> bool
2500 """
423f194a
RD
2501 return _gdi.DC_BlitXY(*args, **kwargs)
2502
2503 def Blit(*args, **kwargs):
41f1cec7
RD
2504 """
2505 Blit(Point destPt, Size sz, DC source, Point srcPt, int rop=COPY,
2506 bool useMask=False, Point srcPtMask=DefaultPosition) -> bool
2507 """
423f194a
RD
2508 return _gdi.DC_Blit(*args, **kwargs)
2509
2510 def DrawLines(*args, **kwargs):
2511 """DrawLines(int points, Point points_array, int xoffset=0, int yoffset=0)"""
2512 return _gdi.DC_DrawLines(*args, **kwargs)
2513
2514 def DrawPolygon(*args, **kwargs):
41f1cec7
RD
2515 """
2516 DrawPolygon(int points, Point points_array, int xoffset=0, int yoffset=0,
2517 int fillStyle=ODDEVEN_RULE)
2518 """
423f194a
RD
2519 return _gdi.DC_DrawPolygon(*args, **kwargs)
2520
2521 def DrawLabel(*args, **kwargs):
41f1cec7 2522 """
d03fd34d 2523 DrawLabel(String text, Rect rect, int alignment=wxALIGN_LEFT|wxALIGN_TOP,
41f1cec7
RD
2524 int indexAccel=-1)
2525 """
423f194a
RD
2526 return _gdi.DC_DrawLabel(*args, **kwargs)
2527
2528 def DrawImageLabel(*args, **kwargs):
41f1cec7 2529 """
d03fd34d 2530 DrawImageLabel(String text, Bitmap image, Rect rect, int alignment=wxALIGN_LEFT|wxALIGN_TOP,
41f1cec7
RD
2531 int indexAccel=-1) -> Rect
2532 """
423f194a
RD
2533 return _gdi.DC_DrawImageLabel(*args, **kwargs)
2534
2535 def DrawSpline(*args, **kwargs):
2536 """DrawSpline(int points, Point points_array)"""
2537 return _gdi.DC_DrawSpline(*args, **kwargs)
2538
2539 def Clear(*args, **kwargs):
2540 """Clear()"""
2541 return _gdi.DC_Clear(*args, **kwargs)
2542
2543 def StartDoc(*args, **kwargs):
d03fd34d 2544 """StartDoc(String message) -> bool"""
423f194a
RD
2545 return _gdi.DC_StartDoc(*args, **kwargs)
2546
2547 def EndDoc(*args, **kwargs):
2548 """EndDoc()"""
2549 return _gdi.DC_EndDoc(*args, **kwargs)
2550
2551 def StartPage(*args, **kwargs):
2552 """StartPage()"""
2553 return _gdi.DC_StartPage(*args, **kwargs)
2554
2555 def EndPage(*args, **kwargs):
2556 """EndPage()"""
2557 return _gdi.DC_EndPage(*args, **kwargs)
2558
2559 def SetFont(*args, **kwargs):
2560 """SetFont(Font font)"""
2561 return _gdi.DC_SetFont(*args, **kwargs)
2562
2563 def SetPen(*args, **kwargs):
2564 """SetPen(Pen pen)"""
2565 return _gdi.DC_SetPen(*args, **kwargs)
2566
2567 def SetBrush(*args, **kwargs):
2568 """SetBrush(Brush brush)"""
2569 return _gdi.DC_SetBrush(*args, **kwargs)
2570
2571 def SetBackground(*args, **kwargs):
2572 """SetBackground(Brush brush)"""
2573 return _gdi.DC_SetBackground(*args, **kwargs)
2574
2575 def SetBackgroundMode(*args, **kwargs):
2576 """SetBackgroundMode(int mode)"""
2577 return _gdi.DC_SetBackgroundMode(*args, **kwargs)
2578
2579 def SetPalette(*args, **kwargs):
2580 """SetPalette(Palette palette)"""
2581 return _gdi.DC_SetPalette(*args, **kwargs)
2582
f0983263
RD
2583 def SetClippingRegionXY(*args, **kwargs):
2584 """SetClippingRegionXY(int x, int y, int width, int height)"""
2585 return _gdi.DC_SetClippingRegionXY(*args, **kwargs)
2586
423f194a 2587 def SetClippingRegion(*args, **kwargs):
f0983263 2588 """SetClippingRegion(Point pt, Size sz)"""
423f194a
RD
2589 return _gdi.DC_SetClippingRegion(*args, **kwargs)
2590
2591 def SetClippingRect(*args, **kwargs):
2592 """SetClippingRect(Rect rect)"""
2593 return _gdi.DC_SetClippingRect(*args, **kwargs)
2594
2595 def SetClippingRegionAsRegion(*args, **kwargs):
2596 """SetClippingRegionAsRegion(Region region)"""
2597 return _gdi.DC_SetClippingRegionAsRegion(*args, **kwargs)
2598
2599 def DestroyClippingRegion(*args, **kwargs):
2600 """DestroyClippingRegion()"""
2601 return _gdi.DC_DestroyClippingRegion(*args, **kwargs)
2602
2603 def GetClippingBox(*args, **kwargs):
44127b65 2604 """GetClippingBox() -> (x, y, width, height)"""
423f194a
RD
2605 return _gdi.DC_GetClippingBox(*args, **kwargs)
2606
2607 def GetClippingRect(*args, **kwargs):
2608 """GetClippingRect() -> Rect"""
2609 return _gdi.DC_GetClippingRect(*args, **kwargs)
2610
2611 def GetCharHeight(*args, **kwargs):
2612 """GetCharHeight() -> int"""
2613 return _gdi.DC_GetCharHeight(*args, **kwargs)
2614
2615 def GetCharWidth(*args, **kwargs):
2616 """GetCharWidth() -> int"""
2617 return _gdi.DC_GetCharWidth(*args, **kwargs)
2618
2619 def GetTextExtent(*args, **kwargs):
41f1cec7
RD
2620 """
2621 GetTextExtent(wxString string) -> (width, height)
44127b65 2622
41f1cec7
RD
2623 Get the width and height of the text using the current font.
2624 Only works for single line strings.
2625 """
423f194a
RD
2626 return _gdi.DC_GetTextExtent(*args, **kwargs)
2627
2628 def GetFullTextExtent(*args, **kwargs):
41f1cec7
RD
2629 """
2630 GetFullTextExtent(wxString string, Font font=None) ->
2631 (width, height, descent, externalLeading)
44127b65 2632
41f1cec7
RD
2633 Get the width, height, decent and leading of the text using the current or specified font.
2634 Only works for single line strings.
2635 """
423f194a
RD
2636 return _gdi.DC_GetFullTextExtent(*args, **kwargs)
2637
2638 def GetMultiLineTextExtent(*args, **kwargs):
41f1cec7
RD
2639 """
2640 GetMultiLineTextExtent(wxString string, Font font=None) ->
2641 (width, height, descent, externalLeading)
423f194a 2642
41f1cec7
RD
2643 Get the width, height, decent and leading of the text using the current or specified font.
2644 Works for single as well as multi-line strings.
2645 """
44127b65 2646 return _gdi.DC_GetMultiLineTextExtent(*args, **kwargs)
423f194a 2647
db914595
RD
2648 def GetPartialTextExtents(*args, **kwargs):
2649 """GetPartialTextExtents(String text) -> wxArrayInt"""
2650 return _gdi.DC_GetPartialTextExtents(*args, **kwargs)
2651
423f194a 2652 def GetSize(*args, **kwargs):
41f1cec7
RD
2653 """
2654 GetSize() -> Size
44127b65 2655
41f1cec7
RD
2656 Get the DC size in device units.
2657 """
423f194a
RD
2658 return _gdi.DC_GetSize(*args, **kwargs)
2659
44127b65 2660 def GetSizeTuple(*args, **kwargs):
41f1cec7
RD
2661 """
2662 GetSizeTuple() -> (width, height)
44127b65 2663
41f1cec7
RD
2664 Get the DC size in device units.
2665 """
44127b65 2666 return _gdi.DC_GetSizeTuple(*args, **kwargs)
423f194a
RD
2667
2668 def GetSizeMM(*args, **kwargs):
41f1cec7
RD
2669 """
2670 GetSizeMM() -> Size
44127b65 2671
41f1cec7
RD
2672 Get the DC size in milimeters.
2673 """
423f194a
RD
2674 return _gdi.DC_GetSizeMM(*args, **kwargs)
2675
44127b65 2676 def GetSizeMMTuple(*args, **kwargs):
41f1cec7
RD
2677 """
2678 GetSizeMMTuple() -> (width, height)
44127b65 2679
41f1cec7
RD
2680 Get the DC size in milimeters.
2681 """
44127b65
RD
2682 return _gdi.DC_GetSizeMMTuple(*args, **kwargs)
2683
423f194a
RD
2684 def DeviceToLogicalX(*args, **kwargs):
2685 """DeviceToLogicalX(int x) -> int"""
2686 return _gdi.DC_DeviceToLogicalX(*args, **kwargs)
2687
2688 def DeviceToLogicalY(*args, **kwargs):
2689 """DeviceToLogicalY(int y) -> int"""
2690 return _gdi.DC_DeviceToLogicalY(*args, **kwargs)
2691
2692 def DeviceToLogicalXRel(*args, **kwargs):
2693 """DeviceToLogicalXRel(int x) -> int"""
2694 return _gdi.DC_DeviceToLogicalXRel(*args, **kwargs)
2695
2696 def DeviceToLogicalYRel(*args, **kwargs):
2697 """DeviceToLogicalYRel(int y) -> int"""
2698 return _gdi.DC_DeviceToLogicalYRel(*args, **kwargs)
2699
2700 def LogicalToDeviceX(*args, **kwargs):
2701 """LogicalToDeviceX(int x) -> int"""
2702 return _gdi.DC_LogicalToDeviceX(*args, **kwargs)
2703
2704 def LogicalToDeviceY(*args, **kwargs):
2705 """LogicalToDeviceY(int y) -> int"""
2706 return _gdi.DC_LogicalToDeviceY(*args, **kwargs)
2707
2708 def LogicalToDeviceXRel(*args, **kwargs):
2709 """LogicalToDeviceXRel(int x) -> int"""
2710 return _gdi.DC_LogicalToDeviceXRel(*args, **kwargs)
2711
2712 def LogicalToDeviceYRel(*args, **kwargs):
2713 """LogicalToDeviceYRel(int y) -> int"""
2714 return _gdi.DC_LogicalToDeviceYRel(*args, **kwargs)
2715
2716 def CanDrawBitmap(*args, **kwargs):
2717 """CanDrawBitmap() -> bool"""
2718 return _gdi.DC_CanDrawBitmap(*args, **kwargs)
2719
2720 def CanGetTextExtent(*args, **kwargs):
2721 """CanGetTextExtent() -> bool"""
2722 return _gdi.DC_CanGetTextExtent(*args, **kwargs)
2723
2724 def GetDepth(*args, **kwargs):
2725 """GetDepth() -> int"""
2726 return _gdi.DC_GetDepth(*args, **kwargs)
2727
2728 def GetPPI(*args, **kwargs):
2729 """GetPPI() -> Size"""
2730 return _gdi.DC_GetPPI(*args, **kwargs)
2731
2732 def Ok(*args, **kwargs):
2733 """Ok() -> bool"""
2734 return _gdi.DC_Ok(*args, **kwargs)
2735
2736 def GetBackgroundMode(*args, **kwargs):
2737 """GetBackgroundMode() -> int"""
2738 return _gdi.DC_GetBackgroundMode(*args, **kwargs)
2739
2740 def GetBackground(*args, **kwargs):
2741 """GetBackground() -> Brush"""
2742 return _gdi.DC_GetBackground(*args, **kwargs)
2743
2744 def GetBrush(*args, **kwargs):
2745 """GetBrush() -> Brush"""
2746 return _gdi.DC_GetBrush(*args, **kwargs)
2747
2748 def GetFont(*args, **kwargs):
2749 """GetFont() -> Font"""
2750 return _gdi.DC_GetFont(*args, **kwargs)
2751
2752 def GetPen(*args, **kwargs):
2753 """GetPen() -> Pen"""
2754 return _gdi.DC_GetPen(*args, **kwargs)
2755
2756 def GetTextBackground(*args, **kwargs):
2757 """GetTextBackground() -> Colour"""
2758 return _gdi.DC_GetTextBackground(*args, **kwargs)
2759
2760 def GetTextForeground(*args, **kwargs):
2761 """GetTextForeground() -> Colour"""
2762 return _gdi.DC_GetTextForeground(*args, **kwargs)
2763
2764 def SetTextForeground(*args, **kwargs):
2765 """SetTextForeground(Colour colour)"""
2766 return _gdi.DC_SetTextForeground(*args, **kwargs)
2767
2768 def SetTextBackground(*args, **kwargs):
2769 """SetTextBackground(Colour colour)"""
2770 return _gdi.DC_SetTextBackground(*args, **kwargs)
2771
2772 def GetMapMode(*args, **kwargs):
2773 """GetMapMode() -> int"""
2774 return _gdi.DC_GetMapMode(*args, **kwargs)
2775
2776 def SetMapMode(*args, **kwargs):
2777 """SetMapMode(int mode)"""
2778 return _gdi.DC_SetMapMode(*args, **kwargs)
2779
2780 def GetUserScale(*args, **kwargs):
44127b65 2781 """GetUserScale() -> (xScale, yScale)"""
423f194a
RD
2782 return _gdi.DC_GetUserScale(*args, **kwargs)
2783
2784 def SetUserScale(*args, **kwargs):
2785 """SetUserScale(double x, double y)"""
2786 return _gdi.DC_SetUserScale(*args, **kwargs)
2787
2788 def GetLogicalScale(*args, **kwargs):
44127b65 2789 """GetLogicalScale() -> (xScale, yScale)"""
423f194a
RD
2790 return _gdi.DC_GetLogicalScale(*args, **kwargs)
2791
2792 def SetLogicalScale(*args, **kwargs):
2793 """SetLogicalScale(double x, double y)"""
2794 return _gdi.DC_SetLogicalScale(*args, **kwargs)
2795
423f194a
RD
2796 def GetLogicalOrigin(*args, **kwargs):
2797 """GetLogicalOrigin() -> Point"""
2798 return _gdi.DC_GetLogicalOrigin(*args, **kwargs)
2799
44127b65
RD
2800 def GetLogicalOriginTuple(*args, **kwargs):
2801 """GetLogicalOriginTuple() -> (x,y)"""
2802 return _gdi.DC_GetLogicalOriginTuple(*args, **kwargs)
2803
423f194a
RD
2804 def SetLogicalOrigin(*args, **kwargs):
2805 """SetLogicalOrigin(int x, int y)"""
2806 return _gdi.DC_SetLogicalOrigin(*args, **kwargs)
2807
423f194a
RD
2808 def GetDeviceOrigin(*args, **kwargs):
2809 """GetDeviceOrigin() -> Point"""
2810 return _gdi.DC_GetDeviceOrigin(*args, **kwargs)
2811
44127b65
RD
2812 def GetDeviceOriginTuple(*args, **kwargs):
2813 """GetDeviceOriginTuple() -> (x,y)"""
2814 return _gdi.DC_GetDeviceOriginTuple(*args, **kwargs)
2815
423f194a
RD
2816 def SetDeviceOrigin(*args, **kwargs):
2817 """SetDeviceOrigin(int x, int y)"""
2818 return _gdi.DC_SetDeviceOrigin(*args, **kwargs)
2819
2820 def SetAxisOrientation(*args, **kwargs):
2821 """SetAxisOrientation(bool xLeftRight, bool yBottomUp)"""
2822 return _gdi.DC_SetAxisOrientation(*args, **kwargs)
2823
2824 def GetLogicalFunction(*args, **kwargs):
2825 """GetLogicalFunction() -> int"""
2826 return _gdi.DC_GetLogicalFunction(*args, **kwargs)
2827
2828 def SetLogicalFunction(*args, **kwargs):
2829 """SetLogicalFunction(int function)"""
2830 return _gdi.DC_SetLogicalFunction(*args, **kwargs)
2831
2832 def SetOptimization(*args, **kwargs):
2833 """SetOptimization(bool opt)"""
2834 return _gdi.DC_SetOptimization(*args, **kwargs)
2835
2836 def GetOptimization(*args, **kwargs):
2837 """GetOptimization() -> bool"""
2838 return _gdi.DC_GetOptimization(*args, **kwargs)
2839
2840 def CalcBoundingBox(*args, **kwargs):
2841 """CalcBoundingBox(int x, int y)"""
2842 return _gdi.DC_CalcBoundingBox(*args, **kwargs)
2843
2844 def ResetBoundingBox(*args, **kwargs):
2845 """ResetBoundingBox()"""
2846 return _gdi.DC_ResetBoundingBox(*args, **kwargs)
2847
2848 def MinX(*args, **kwargs):
2849 """MinX() -> int"""
2850 return _gdi.DC_MinX(*args, **kwargs)
2851
2852 def MaxX(*args, **kwargs):
2853 """MaxX() -> int"""
2854 return _gdi.DC_MaxX(*args, **kwargs)
2855
2856 def MinY(*args, **kwargs):
2857 """MinY() -> int"""
2858 return _gdi.DC_MinY(*args, **kwargs)
2859
2860 def MaxY(*args, **kwargs):
2861 """MaxY() -> int"""
2862 return _gdi.DC_MaxY(*args, **kwargs)
2863
2864 def GetBoundingBox(*args, **kwargs):
44127b65 2865 """GetBoundingBox() -> (x1,y1, x2,y2)"""
423f194a
RD
2866 return _gdi.DC_GetBoundingBox(*args, **kwargs)
2867
d14a1e28 2868 def __nonzero__(self): return self.Ok()
423f194a
RD
2869 def _DrawPointList(*args, **kwargs):
2870 """_DrawPointList(PyObject pyCoords, PyObject pyPens, PyObject pyBrushes) -> PyObject"""
2871 return _gdi.DC__DrawPointList(*args, **kwargs)
2872
2873 def _DrawLineList(*args, **kwargs):
2874 """_DrawLineList(PyObject pyCoords, PyObject pyPens, PyObject pyBrushes) -> PyObject"""
2875 return _gdi.DC__DrawLineList(*args, **kwargs)
2876
2877 def _DrawRectangleList(*args, **kwargs):
2878 """_DrawRectangleList(PyObject pyCoords, PyObject pyPens, PyObject pyBrushes) -> PyObject"""
2879 return _gdi.DC__DrawRectangleList(*args, **kwargs)
2880
2881 def _DrawEllipseList(*args, **kwargs):
2882 """_DrawEllipseList(PyObject pyCoords, PyObject pyPens, PyObject pyBrushes) -> PyObject"""
2883 return _gdi.DC__DrawEllipseList(*args, **kwargs)
2884
2885 def _DrawPolygonList(*args, **kwargs):
2886 """_DrawPolygonList(PyObject pyCoords, PyObject pyPens, PyObject pyBrushes) -> PyObject"""
2887 return _gdi.DC__DrawPolygonList(*args, **kwargs)
2888
2889 def _DrawTextList(*args, **kwargs):
41f1cec7
RD
2890 """
2891 _DrawTextList(PyObject textList, PyObject pyPoints, PyObject foregroundList,
2892 PyObject backgroundList) -> PyObject
2893 """
423f194a
RD
2894 return _gdi.DC__DrawTextList(*args, **kwargs)
2895
9d37f964
RD
2896 def DrawPointList(self, points, pens=None):
2897 if pens is None:
2898 pens = []
d14a1e28 2899 elif isinstance(pens, wx.Pen):
9d37f964
RD
2900 pens = [pens]
2901 elif len(pens) != len(points):
2902 raise ValueError('points and pens must have same length')
7e50db3f
RD
2903 return self._DrawPointList(points, pens, [])
2904
9d37f964
RD
2905
2906 def DrawLineList(self, lines, pens=None):
2907 if pens is None:
2908 pens = []
d14a1e28 2909 elif isinstance(pens, wx.Pen):
9d37f964
RD
2910 pens = [pens]
2911 elif len(pens) != len(lines):
2912 raise ValueError('lines and pens must have same length')
7e50db3f
RD
2913 return self._DrawLineList(lines, pens, [])
2914
2915
2916 def DrawRectangleList(self, rectangles, pens=None, brushes=None):
2917 if pens is None:
2918 pens = []
d14a1e28 2919 elif isinstance(pens, wx.Pen):
7e50db3f
RD
2920 pens = [pens]
2921 elif len(pens) != len(rectangles):
2922 raise ValueError('rectangles and pens must have same length')
2923 if brushes is None:
2924 brushes = []
d14a1e28 2925 elif isinstance(brushes, wx.Brush):
7e50db3f
RD
2926 brushes = [brushes]
2927 elif len(brushes) != len(rectangles):
2928 raise ValueError('rectangles and brushes must have same length')
2929 return self._DrawRectangleList(rectangles, pens, brushes)
2930
2931
2932 def DrawEllipseList(self, ellipses, pens=None, brushes=None):
2933 if pens is None:
2934 pens = []
d14a1e28 2935 elif isinstance(pens, wx.Pen):
7e50db3f
RD
2936 pens = [pens]
2937 elif len(pens) != len(ellipses):
2938 raise ValueError('ellipses and pens must have same length')
2939 if brushes is None:
2940 brushes = []
d14a1e28 2941 elif isinstance(brushes, wx.Brush):
7e50db3f
RD
2942 brushes = [brushes]
2943 elif len(brushes) != len(ellipses):
2944 raise ValueError('ellipses and brushes must have same length')
2945 return self._DrawEllipseList(ellipses, pens, brushes)
2946
2947
2948 def DrawPolygonList(self, polygons, pens=None, brushes=None):
eb9b6107
RD
2949 ## Note: This does not currently support fill style or offset
2950 ## you can always use the non-List version if need be.
7e50db3f
RD
2951 if pens is None:
2952 pens = []
d14a1e28 2953 elif isinstance(pens, wx.Pen):
7e50db3f
RD
2954 pens = [pens]
2955 elif len(pens) != len(polygons):
2956 raise ValueError('polygons and pens must have same length')
2957 if brushes is None:
2958 brushes = []
d14a1e28 2959 elif isinstance(brushes, wx.Brush):
7e50db3f
RD
2960 brushes = [brushes]
2961 elif len(brushes) != len(polygons):
2962 raise ValueError('polygons and brushes must have same length')
2963 return self._DrawPolygonList(polygons, pens, brushes)
2964
2965
2966 def DrawTextList(self, textList, coords, foregrounds = None, backgrounds = None, fonts = None):
eb9b6107
RD
2967 ## NOTE: this does not currently support changing the font
2968 ## Make sure you set Background mode to wxSolid (DC.SetBackgroundMode)
2969 ## If you want backgounds to do anything.
7e50db3f
RD
2970 if type(textList) == type(''):
2971 textList = [textList]
2972 elif len(textList) != len(coords):
2973 raise ValueError('textlist and coords must have same length')
2974 if foregrounds is None:
2975 foregrounds = []
8a0b029b 2976 elif isinstance(foregrounds, wx.Colour):
7e50db3f
RD
2977 foregrounds = [foregrounds]
2978 elif len(foregrounds) != len(coords):
2979 raise ValueError('foregrounds and coords must have same length')
2980 if backgrounds is None:
2981 backgrounds = []
8a0b029b 2982 elif isinstance(backgrounds, wx.Colour):
7e50db3f
RD
2983 backgrounds = [backgrounds]
2984 elif len(backgrounds) != len(coords):
2985 raise ValueError('backgrounds and coords must have same length')
2986 return self._DrawTextList(textList, coords, foregrounds, backgrounds)
9d37f964 2987
8ab979d7 2988
d14a1e28
RD
2989class DCPtr(DC):
2990 def __init__(self, this):
2991 self.this = this
2992 if not hasattr(self,"thisown"): self.thisown = 0
2993 self.__class__ = DC
2994_gdi.DC_swigregister(DCPtr)
8ab979d7 2995
d14a1e28 2996#---------------------------------------------------------------------------
8ab979d7 2997
d14a1e28 2998class MemoryDC(DC):
423f194a
RD
2999 def __repr__(self):
3000 return "<%s.%s; proxy of C++ wxMemoryDC instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 3001 def __init__(self, *args, **kwargs):
423f194a 3002 """__init__() -> MemoryDC"""
d14a1e28
RD
3003 newobj = _gdi.new_MemoryDC(*args, **kwargs)
3004 self.this = newobj.this
1dc2f865 3005 self.thisown = 1
d14a1e28 3006 del newobj.thisown
423f194a
RD
3007 def SelectObject(*args, **kwargs):
3008 """SelectObject(Bitmap bitmap)"""
3009 return _gdi.MemoryDC_SelectObject(*args, **kwargs)
3010
8ab979d7 3011
d14a1e28
RD
3012class MemoryDCPtr(MemoryDC):
3013 def __init__(self, this):
3014 self.this = this
3015 if not hasattr(self,"thisown"): self.thisown = 0
3016 self.__class__ = MemoryDC
3017_gdi.MemoryDC_swigregister(MemoryDCPtr)
8ab979d7 3018
d14a1e28 3019def MemoryDCFromDC(*args, **kwargs):
423f194a 3020 """MemoryDCFromDC(DC oldDC) -> MemoryDC"""
d14a1e28
RD
3021 val = _gdi.new_MemoryDCFromDC(*args, **kwargs)
3022 val.thisown = 1
3023 return val
b639c3c5 3024
d14a1e28 3025#---------------------------------------------------------------------------
b639c3c5 3026
d14a1e28 3027class BufferedDC(MemoryDC):
423f194a
RD
3028 def __repr__(self):
3029 return "<%s.%s; proxy of C++ wxBufferedDC instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
db914595
RD
3030 def __init__(self, *args):
3031 """
3032 __init__(DC dc, Bitmap buffer) -> BufferedDC
328fcd84 3033 __init__(DC dc, Size area) -> BufferedDC
db914595
RD
3034 """
3035 newobj = _gdi.new_BufferedDC(*args)
d14a1e28 3036 self.this = newobj.this
e9159fe8 3037 self.thisown = 1
d14a1e28 3038 del newobj.thisown
1f05e33b 3039 self._dc = args[0] # save a ref so the other dc will not be deleted before self
423f194a 3040
328fcd84
RD
3041 def __del__(self, destroy=_gdi.delete_BufferedDC):
3042 """__del__()"""
3043 try:
3044 if self.thisown: destroy(self)
3045 except: pass
3046
423f194a
RD
3047 def UnMask(*args, **kwargs):
3048 """UnMask()"""
3049 return _gdi.BufferedDC_UnMask(*args, **kwargs)
3050
e9159fe8 3051
d14a1e28
RD
3052class BufferedDCPtr(BufferedDC):
3053 def __init__(self, this):
3054 self.this = this
3055 if not hasattr(self,"thisown"): self.thisown = 0
3056 self.__class__ = BufferedDC
3057_gdi.BufferedDC_swigregister(BufferedDCPtr)
e9159fe8 3058
db914595 3059def BufferedDCInternalBuffer(*args):
328fcd84 3060 """BufferedDCInternalBuffer(DC dc, Size area) -> BufferedDC"""
db914595 3061 val = _gdi.new_BufferedDCInternalBuffer(*args)
e9159fe8 3062 val.thisown = 1
d14a1e28 3063 val._dc = args[0] # save a ref so the other dc will not be deleted before self
e9159fe8
RD
3064 return val
3065
d14a1e28 3066class BufferedPaintDC(BufferedDC):
423f194a
RD
3067 def __repr__(self):
3068 return "<%s.%s; proxy of C++ wxBufferedPaintDC instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
328fcd84
RD
3069 def __init__(self, *args, **kwargs):
3070 """__init__(Window window, Bitmap buffer=NullBitmap) -> BufferedPaintDC"""
3071 newobj = _gdi.new_BufferedPaintDC(*args, **kwargs)
d14a1e28 3072 self.this = newobj.this
e9159fe8 3073 self.thisown = 1
d14a1e28 3074 del newobj.thisown
e9159fe8 3075
d14a1e28
RD
3076class BufferedPaintDCPtr(BufferedPaintDC):
3077 def __init__(self, this):
3078 self.this = this
3079 if not hasattr(self,"thisown"): self.thisown = 0
3080 self.__class__ = BufferedPaintDC
3081_gdi.BufferedPaintDC_swigregister(BufferedPaintDCPtr)
e9159fe8 3082
d14a1e28 3083#---------------------------------------------------------------------------
e9159fe8 3084
d14a1e28 3085class ScreenDC(DC):
423f194a
RD
3086 def __repr__(self):
3087 return "<%s.%s; proxy of C++ wxScreenDC instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 3088 def __init__(self, *args, **kwargs):
423f194a 3089 """__init__() -> ScreenDC"""
d14a1e28
RD
3090 newobj = _gdi.new_ScreenDC(*args, **kwargs)
3091 self.this = newobj.this
1dc2f865 3092 self.thisown = 1
d14a1e28 3093 del newobj.thisown
423f194a
RD
3094 def StartDrawingOnTopWin(*args, **kwargs):
3095 """StartDrawingOnTopWin(Window window) -> bool"""
3096 return _gdi.ScreenDC_StartDrawingOnTopWin(*args, **kwargs)
3097
3098 def StartDrawingOnTop(*args, **kwargs):
3099 """StartDrawingOnTop(Rect rect=None) -> bool"""
3100 return _gdi.ScreenDC_StartDrawingOnTop(*args, **kwargs)
3101
3102 def EndDrawingOnTop(*args, **kwargs):
3103 """EndDrawingOnTop() -> bool"""
3104 return _gdi.ScreenDC_EndDrawingOnTop(*args, **kwargs)
3105
b639c3c5 3106
d14a1e28
RD
3107class ScreenDCPtr(ScreenDC):
3108 def __init__(self, this):
3109 self.this = this
3110 if not hasattr(self,"thisown"): self.thisown = 0
3111 self.__class__ = ScreenDC
3112_gdi.ScreenDC_swigregister(ScreenDCPtr)
b639c3c5 3113
d14a1e28 3114#---------------------------------------------------------------------------
8ab979d7 3115
d14a1e28 3116class ClientDC(DC):
423f194a
RD
3117 def __repr__(self):
3118 return "<%s.%s; proxy of C++ wxClientDC instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 3119 def __init__(self, *args, **kwargs):
423f194a 3120 """__init__(Window win) -> ClientDC"""
d14a1e28
RD
3121 newobj = _gdi.new_ClientDC(*args, **kwargs)
3122 self.this = newobj.this
1dc2f865 3123 self.thisown = 1
d14a1e28 3124 del newobj.thisown
8ab979d7 3125
d14a1e28
RD
3126class ClientDCPtr(ClientDC):
3127 def __init__(self, this):
3128 self.this = this
3129 if not hasattr(self,"thisown"): self.thisown = 0
3130 self.__class__ = ClientDC
3131_gdi.ClientDC_swigregister(ClientDCPtr)
8ab979d7 3132
d14a1e28 3133#---------------------------------------------------------------------------
8ab979d7 3134
d14a1e28 3135class PaintDC(DC):
423f194a
RD
3136 def __repr__(self):
3137 return "<%s.%s; proxy of C++ wxPaintDC instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 3138 def __init__(self, *args, **kwargs):
423f194a 3139 """__init__(Window win) -> PaintDC"""
d14a1e28
RD
3140 newobj = _gdi.new_PaintDC(*args, **kwargs)
3141 self.this = newobj.this
1dc2f865 3142 self.thisown = 1
d14a1e28 3143 del newobj.thisown
8ab979d7 3144
d14a1e28
RD
3145class PaintDCPtr(PaintDC):
3146 def __init__(self, this):
3147 self.this = this
3148 if not hasattr(self,"thisown"): self.thisown = 0
3149 self.__class__ = PaintDC
3150_gdi.PaintDC_swigregister(PaintDCPtr)
8ab979d7 3151
d14a1e28 3152#---------------------------------------------------------------------------
b639c3c5 3153
d14a1e28 3154class WindowDC(DC):
423f194a
RD
3155 def __repr__(self):
3156 return "<%s.%s; proxy of C++ wxWindowDC instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 3157 def __init__(self, *args, **kwargs):
423f194a 3158 """__init__(Window win) -> WindowDC"""
d14a1e28
RD
3159 newobj = _gdi.new_WindowDC(*args, **kwargs)
3160 self.this = newobj.this
5a2a9da2 3161 self.thisown = 1
d14a1e28 3162 del newobj.thisown
5a2a9da2 3163
d14a1e28
RD
3164class WindowDCPtr(WindowDC):
3165 def __init__(self, this):
3166 self.this = this
3167 if not hasattr(self,"thisown"): self.thisown = 0
3168 self.__class__ = WindowDC
3169_gdi.WindowDC_swigregister(WindowDCPtr)
5a2a9da2 3170
d14a1e28 3171#---------------------------------------------------------------------------
5a2a9da2 3172
d14a1e28 3173class MirrorDC(DC):
423f194a
RD
3174 def __repr__(self):
3175 return "<%s.%s; proxy of C++ wxMirrorDC instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 3176 def __init__(self, *args, **kwargs):
423f194a 3177 """__init__(DC dc, bool mirror) -> MirrorDC"""
d14a1e28
RD
3178 newobj = _gdi.new_MirrorDC(*args, **kwargs)
3179 self.this = newobj.this
1dc2f865 3180 self.thisown = 1
d14a1e28 3181 del newobj.thisown
b639c3c5 3182
d14a1e28
RD
3183class MirrorDCPtr(MirrorDC):
3184 def __init__(self, this):
3185 self.this = this
3186 if not hasattr(self,"thisown"): self.thisown = 0
3187 self.__class__ = MirrorDC
3188_gdi.MirrorDC_swigregister(MirrorDCPtr)
b639c3c5 3189
d14a1e28 3190#---------------------------------------------------------------------------
8bf5d46e 3191
d14a1e28 3192class PostScriptDC(DC):
423f194a
RD
3193 def __repr__(self):
3194 return "<%s.%s; proxy of C++ wxPostScriptDC instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 3195 def __init__(self, *args, **kwargs):
423f194a 3196 """__init__(wxPrintData printData) -> PostScriptDC"""
d14a1e28
RD
3197 newobj = _gdi.new_PostScriptDC(*args, **kwargs)
3198 self.this = newobj.this
3199 self.thisown = 1
3200 del newobj.thisown
423f194a
RD
3201 def GetPrintData(*args, **kwargs):
3202 """GetPrintData() -> wxPrintData"""
3203 return _gdi.PostScriptDC_GetPrintData(*args, **kwargs)
3204
3205 def SetPrintData(*args, **kwargs):
3206 """SetPrintData(wxPrintData data)"""
3207 return _gdi.PostScriptDC_SetPrintData(*args, **kwargs)
3208
3209 def SetResolution(*args, **kwargs):
83448d71 3210 """SetResolution(int ppi)"""
423f194a
RD
3211 return _gdi.PostScriptDC_SetResolution(*args, **kwargs)
3212
3213 SetResolution = staticmethod(SetResolution)
3214 def GetResolution(*args, **kwargs):
83448d71 3215 """GetResolution() -> int"""
423f194a
RD
3216 return _gdi.PostScriptDC_GetResolution(*args, **kwargs)
3217
3218 GetResolution = staticmethod(GetResolution)
8bf5d46e 3219
d14a1e28
RD
3220class PostScriptDCPtr(PostScriptDC):
3221 def __init__(self, this):
17c0e08c 3222 self.this = this
d14a1e28
RD
3223 if not hasattr(self,"thisown"): self.thisown = 0
3224 self.__class__ = PostScriptDC
3225_gdi.PostScriptDC_swigregister(PostScriptDCPtr)
17c0e08c 3226
423f194a
RD
3227def PostScriptDC_SetResolution(*args, **kwargs):
3228 """PostScriptDC_SetResolution(int ppi)"""
3229 return _gdi.PostScriptDC_SetResolution(*args, **kwargs)
17c0e08c 3230
423f194a
RD
3231def PostScriptDC_GetResolution(*args, **kwargs):
3232 """PostScriptDC_GetResolution() -> int"""
3233 return _gdi.PostScriptDC_GetResolution(*args, **kwargs)
17c0e08c 3234
d14a1e28 3235#---------------------------------------------------------------------------
17c0e08c 3236
d14a1e28 3237class MetaFile(core.Object):
423f194a
RD
3238 def __repr__(self):
3239 return "<%s.%s; proxy of C++ wxMetaFile instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 3240 def __init__(self, *args, **kwargs):
d03fd34d 3241 """__init__(String filename=EmptyString) -> MetaFile"""
d14a1e28
RD
3242 newobj = _gdi.new_MetaFile(*args, **kwargs)
3243 self.this = newobj.this
1dc2f865 3244 self.thisown = 1
d14a1e28
RD
3245 del newobj.thisown
3246 def __del__(self, destroy=_gdi.delete_MetaFile):
423f194a 3247 """__del__()"""
d14a1e28
RD
3248 try:
3249 if self.thisown: destroy(self)
3250 except: pass
423f194a
RD
3251
3252 def Ok(*args, **kwargs):
3253 """Ok() -> bool"""
3254 return _gdi.MetaFile_Ok(*args, **kwargs)
3255
3256 def SetClipboard(*args, **kwargs):
3257 """SetClipboard(int width=0, int height=0) -> bool"""
3258 return _gdi.MetaFile_SetClipboard(*args, **kwargs)
3259
3260 def GetSize(*args, **kwargs):
3261 """GetSize() -> Size"""
3262 return _gdi.MetaFile_GetSize(*args, **kwargs)
3263
3264 def GetWidth(*args, **kwargs):
3265 """GetWidth() -> int"""
3266 return _gdi.MetaFile_GetWidth(*args, **kwargs)
3267
3268 def GetHeight(*args, **kwargs):
3269 """GetHeight() -> int"""
3270 return _gdi.MetaFile_GetHeight(*args, **kwargs)
3271
3272 def GetFileName(*args, **kwargs):
d03fd34d 3273 """GetFileName() -> String"""
423f194a
RD
3274 return _gdi.MetaFile_GetFileName(*args, **kwargs)
3275
d14a1e28 3276 def __nonzero__(self): return self.Ok()
8bf5d46e 3277
d14a1e28
RD
3278class MetaFilePtr(MetaFile):
3279 def __init__(self, this):
1dc2f865 3280 self.this = this
d14a1e28
RD
3281 if not hasattr(self,"thisown"): self.thisown = 0
3282 self.__class__ = MetaFile
3283_gdi.MetaFile_swigregister(MetaFilePtr)
3284
3285class MetaFileDC(DC):
423f194a
RD
3286 def __repr__(self):
3287 return "<%s.%s; proxy of C++ wxMetaFileDC instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 3288 def __init__(self, *args, **kwargs):
41f1cec7 3289 """
d03fd34d
RD
3290 __init__(String filename=EmptyString, int width=0, int height=0,
3291 String description=EmptyString) -> MetaFileDC
41f1cec7 3292 """
d14a1e28
RD
3293 newobj = _gdi.new_MetaFileDC(*args, **kwargs)
3294 self.this = newobj.this
1dc2f865 3295 self.thisown = 1
d14a1e28 3296 del newobj.thisown
423f194a
RD
3297 def Close(*args, **kwargs):
3298 """Close() -> MetaFile"""
3299 return _gdi.MetaFileDC_Close(*args, **kwargs)
3300
8bf5d46e 3301
d14a1e28
RD
3302class MetaFileDCPtr(MetaFileDC):
3303 def __init__(self, this):
1dc2f865 3304 self.this = this
d14a1e28
RD
3305 if not hasattr(self,"thisown"): self.thisown = 0
3306 self.__class__ = MetaFileDC
3307_gdi.MetaFileDC_swigregister(MetaFileDCPtr)
3308
3309class PrinterDC(DC):
423f194a
RD
3310 def __repr__(self):
3311 return "<%s.%s; proxy of C++ wxPrinterDC instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 3312 def __init__(self, *args, **kwargs):
423f194a 3313 """__init__(wxPrintData printData) -> PrinterDC"""
d14a1e28
RD
3314 newobj = _gdi.new_PrinterDC(*args, **kwargs)
3315 self.this = newobj.this
1dc2f865 3316 self.thisown = 1
d14a1e28 3317 del newobj.thisown
af309447 3318
d14a1e28
RD
3319class PrinterDCPtr(PrinterDC):
3320 def __init__(self, this):
9416aa89 3321 self.this = this
d14a1e28
RD
3322 if not hasattr(self,"thisown"): self.thisown = 0
3323 self.__class__ = PrinterDC
3324_gdi.PrinterDC_swigregister(PrinterDCPtr)
3325
eb9b6107
RD
3326class DC_old(DC):
3327 """DC class that has methods with 2.4 compatible parameters."""
3328 FloodFill = DC.FloodFillXY
3329 GetPixel = DC.GetPixelXY
3330 DrawLine = DC.DrawLineXY
3331 CrossHair = DC.CrossHairXY
3332 DrawArc = DC.DrawArcXY
3333 DrawCheckMark = DC.DrawCheckMarkXY
3334 DrawEllipticArc = DC.DrawEllipticArcXY
3335 DrawPoint = DC.DrawPointXY
3336 DrawRectangle = DC.DrawRectangleXY
3337 DrawRoundedRectangle = DC.DrawRoundedRectangleXY
3338 DrawCircle = DC.DrawCircleXY
3339 DrawEllipse = DC.DrawEllipseXY
3340 DrawIcon = DC.DrawIconXY
3341 DrawBitmap = DC.DrawBitmapXY
3342 DrawText = DC.DrawTextXY
3343 DrawRotatedText = DC.DrawRotatedTextXY
3344 Blit = DC.BlitXY
3345
3346class MemoryDC_old(MemoryDC):
3347 """DC class that has methods with 2.4 compatible parameters."""
3348 FloodFill = MemoryDC.FloodFillXY
3349 GetPixel = MemoryDC.GetPixelXY
3350 DrawLine = MemoryDC.DrawLineXY
3351 CrossHair = MemoryDC.CrossHairXY
3352 DrawArc = MemoryDC.DrawArcXY
3353 DrawCheckMark = MemoryDC.DrawCheckMarkXY
3354 DrawEllipticArc = MemoryDC.DrawEllipticArcXY
3355 DrawPoint = MemoryDC.DrawPointXY
3356 DrawRectangle = MemoryDC.DrawRectangleXY
3357 DrawRoundedRectangle = MemoryDC.DrawRoundedRectangleXY
3358 DrawCircle = MemoryDC.DrawCircleXY
3359 DrawEllipse = MemoryDC.DrawEllipseXY
3360 DrawIcon = MemoryDC.DrawIconXY
3361 DrawBitmap = MemoryDC.DrawBitmapXY
3362 DrawText = MemoryDC.DrawTextXY
3363 DrawRotatedText = MemoryDC.DrawRotatedTextXY
3364 Blit = MemoryDC.BlitXY
3365
3366class BufferedDC_old(BufferedDC):
3367 """DC class that has methods with 2.4 compatible parameters."""
3368 FloodFill = BufferedDC.FloodFillXY
3369 GetPixel = BufferedDC.GetPixelXY
3370 DrawLine = BufferedDC.DrawLineXY
3371 CrossHair = BufferedDC.CrossHairXY
3372 DrawArc = BufferedDC.DrawArcXY
3373 DrawCheckMark = BufferedDC.DrawCheckMarkXY
3374 DrawEllipticArc = BufferedDC.DrawEllipticArcXY
3375 DrawPoint = BufferedDC.DrawPointXY
3376 DrawRectangle = BufferedDC.DrawRectangleXY
3377 DrawRoundedRectangle = BufferedDC.DrawRoundedRectangleXY
3378 DrawCircle = BufferedDC.DrawCircleXY
3379 DrawEllipse = BufferedDC.DrawEllipseXY
3380 DrawIcon = BufferedDC.DrawIconXY
3381 DrawBitmap = BufferedDC.DrawBitmapXY
3382 DrawText = BufferedDC.DrawTextXY
3383 DrawRotatedText = BufferedDC.DrawRotatedTextXY
3384 Blit = BufferedDC.BlitXY
3385
3386class BufferedPaintDC_old(BufferedPaintDC):
3387 """DC class that has methods with 2.4 compatible parameters."""
3388 FloodFill = BufferedPaintDC.FloodFillXY
3389 GetPixel = BufferedPaintDC.GetPixelXY
3390 DrawLine = BufferedPaintDC.DrawLineXY
3391 CrossHair = BufferedPaintDC.CrossHairXY
3392 DrawArc = BufferedPaintDC.DrawArcXY
3393 DrawCheckMark = BufferedPaintDC.DrawCheckMarkXY
3394 DrawEllipticArc = BufferedPaintDC.DrawEllipticArcXY
3395 DrawPoint = BufferedPaintDC.DrawPointXY
3396 DrawRectangle = BufferedPaintDC.DrawRectangleXY
3397 DrawRoundedRectangle = BufferedPaintDC.DrawRoundedRectangleXY
3398 DrawCircle = BufferedPaintDC.DrawCircleXY
3399 DrawEllipse = BufferedPaintDC.DrawEllipseXY
3400 DrawIcon = BufferedPaintDC.DrawIconXY
3401 DrawBitmap = BufferedPaintDC.DrawBitmapXY
3402 DrawText = BufferedPaintDC.DrawTextXY
3403 DrawRotatedText = BufferedPaintDC.DrawRotatedTextXY
3404 Blit = BufferedPaintDC.BlitXY
3405
3406class ScreenDC_old(ScreenDC):
3407 """DC class that has methods with 2.4 compatible parameters."""
3408 FloodFill = ScreenDC.FloodFillXY
3409 GetPixel = ScreenDC.GetPixelXY
3410 DrawLine = ScreenDC.DrawLineXY
3411 CrossHair = ScreenDC.CrossHairXY
3412 DrawArc = ScreenDC.DrawArcXY
3413 DrawCheckMark = ScreenDC.DrawCheckMarkXY
3414 DrawEllipticArc = ScreenDC.DrawEllipticArcXY
3415 DrawPoint = ScreenDC.DrawPointXY
3416 DrawRectangle = ScreenDC.DrawRectangleXY
3417 DrawRoundedRectangle = ScreenDC.DrawRoundedRectangleXY
3418 DrawCircle = ScreenDC.DrawCircleXY
3419 DrawEllipse = ScreenDC.DrawEllipseXY
3420 DrawIcon = ScreenDC.DrawIconXY
3421 DrawBitmap = ScreenDC.DrawBitmapXY
3422 DrawText = ScreenDC.DrawTextXY
3423 DrawRotatedText = ScreenDC.DrawRotatedTextXY
3424 Blit = ScreenDC.BlitXY
3425
3426class ClientDC_old(ClientDC):
3427 """DC class that has methods with 2.4 compatible parameters."""
3428 FloodFill = ClientDC.FloodFillXY
3429 GetPixel = ClientDC.GetPixelXY
3430 DrawLine = ClientDC.DrawLineXY
3431 CrossHair = ClientDC.CrossHairXY
3432 DrawArc = ClientDC.DrawArcXY
3433 DrawCheckMark = ClientDC.DrawCheckMarkXY
3434 DrawEllipticArc = ClientDC.DrawEllipticArcXY
3435 DrawPoint = ClientDC.DrawPointXY
3436 DrawRectangle = ClientDC.DrawRectangleXY
3437 DrawRoundedRectangle = ClientDC.DrawRoundedRectangleXY
3438 DrawCircle = ClientDC.DrawCircleXY
3439 DrawEllipse = ClientDC.DrawEllipseXY
3440 DrawIcon = ClientDC.DrawIconXY
3441 DrawBitmap = ClientDC.DrawBitmapXY
3442 DrawText = ClientDC.DrawTextXY
3443 DrawRotatedText = ClientDC.DrawRotatedTextXY
3444 Blit = ClientDC.BlitXY
3445
3446class PaintDC_old(PaintDC):
3447 """DC class that has methods with 2.4 compatible parameters."""
3448 FloodFill = PaintDC.FloodFillXY
3449 GetPixel = PaintDC.GetPixelXY
3450 DrawLine = PaintDC.DrawLineXY
3451 CrossHair = PaintDC.CrossHairXY
3452 DrawArc = PaintDC.DrawArcXY
3453 DrawCheckMark = PaintDC.DrawCheckMarkXY
3454 DrawEllipticArc = PaintDC.DrawEllipticArcXY
3455 DrawPoint = PaintDC.DrawPointXY
3456 DrawRectangle = PaintDC.DrawRectangleXY
3457 DrawRoundedRectangle = PaintDC.DrawRoundedRectangleXY
3458 DrawCircle = PaintDC.DrawCircleXY
3459 DrawEllipse = PaintDC.DrawEllipseXY
3460 DrawIcon = PaintDC.DrawIconXY
3461 DrawBitmap = PaintDC.DrawBitmapXY
3462 DrawText = PaintDC.DrawTextXY
3463 DrawRotatedText = PaintDC.DrawRotatedTextXY
3464 Blit = PaintDC.BlitXY
3465
3466class WindowDC_old(WindowDC):
3467 """DC class that has methods with 2.4 compatible parameters."""
3468 FloodFill = WindowDC.FloodFillXY
3469 GetPixel = WindowDC.GetPixelXY
3470 DrawLine = WindowDC.DrawLineXY
3471 CrossHair = WindowDC.CrossHairXY
3472 DrawArc = WindowDC.DrawArcXY
3473 DrawCheckMark = WindowDC.DrawCheckMarkXY
3474 DrawEllipticArc = WindowDC.DrawEllipticArcXY
3475 DrawPoint = WindowDC.DrawPointXY
3476 DrawRectangle = WindowDC.DrawRectangleXY
3477 DrawRoundedRectangle = WindowDC.DrawRoundedRectangleXY
3478 DrawCircle = WindowDC.DrawCircleXY
3479 DrawEllipse = WindowDC.DrawEllipseXY
3480 DrawIcon = WindowDC.DrawIconXY
3481 DrawBitmap = WindowDC.DrawBitmapXY
3482 DrawText = WindowDC.DrawTextXY
3483 DrawRotatedText = WindowDC.DrawRotatedTextXY
3484 Blit = WindowDC.BlitXY
3485
3486class MirrorDC_old(MirrorDC):
3487 """DC class that has methods with 2.4 compatible parameters."""
3488 FloodFill = MirrorDC.FloodFillXY
3489 GetPixel = MirrorDC.GetPixelXY
3490 DrawLine = MirrorDC.DrawLineXY
3491 CrossHair = MirrorDC.CrossHairXY
3492 DrawArc = MirrorDC.DrawArcXY
3493 DrawCheckMark = MirrorDC.DrawCheckMarkXY
3494 DrawEllipticArc = MirrorDC.DrawEllipticArcXY
3495 DrawPoint = MirrorDC.DrawPointXY
3496 DrawRectangle = MirrorDC.DrawRectangleXY
3497 DrawRoundedRectangle = MirrorDC.DrawRoundedRectangleXY
3498 DrawCircle = MirrorDC.DrawCircleXY
3499 DrawEllipse = MirrorDC.DrawEllipseXY
3500 DrawIcon = MirrorDC.DrawIconXY
3501 DrawBitmap = MirrorDC.DrawBitmapXY
3502 DrawText = MirrorDC.DrawTextXY
3503 DrawRotatedText = MirrorDC.DrawRotatedTextXY
3504 Blit = MirrorDC.BlitXY
3505
3506class PostScriptDC_old(PostScriptDC):
3507 """DC class that has methods with 2.4 compatible parameters."""
3508 FloodFill = PostScriptDC.FloodFillXY
3509 GetPixel = PostScriptDC.GetPixelXY
3510 DrawLine = PostScriptDC.DrawLineXY
3511 CrossHair = PostScriptDC.CrossHairXY
3512 DrawArc = PostScriptDC.DrawArcXY
3513 DrawCheckMark = PostScriptDC.DrawCheckMarkXY
3514 DrawEllipticArc = PostScriptDC.DrawEllipticArcXY
3515 DrawPoint = PostScriptDC.DrawPointXY
3516 DrawRectangle = PostScriptDC.DrawRectangleXY
3517 DrawRoundedRectangle = PostScriptDC.DrawRoundedRectangleXY
3518 DrawCircle = PostScriptDC.DrawCircleXY
3519 DrawEllipse = PostScriptDC.DrawEllipseXY
3520 DrawIcon = PostScriptDC.DrawIconXY
3521 DrawBitmap = PostScriptDC.DrawBitmapXY
3522 DrawText = PostScriptDC.DrawTextXY
3523 DrawRotatedText = PostScriptDC.DrawRotatedTextXY
3524 Blit = PostScriptDC.BlitXY
3525
3526class MetaFileDC_old(MetaFileDC):
3527 """DC class that has methods with 2.4 compatible parameters."""
3528 FloodFill = MetaFileDC.FloodFillXY
3529 GetPixel = MetaFileDC.GetPixelXY
3530 DrawLine = MetaFileDC.DrawLineXY
3531 CrossHair = MetaFileDC.CrossHairXY
3532 DrawArc = MetaFileDC.DrawArcXY
3533 DrawCheckMark = MetaFileDC.DrawCheckMarkXY
3534 DrawEllipticArc = MetaFileDC.DrawEllipticArcXY
3535 DrawPoint = MetaFileDC.DrawPointXY
3536 DrawRectangle = MetaFileDC.DrawRectangleXY
3537 DrawRoundedRectangle = MetaFileDC.DrawRoundedRectangleXY
3538 DrawCircle = MetaFileDC.DrawCircleXY
3539 DrawEllipse = MetaFileDC.DrawEllipseXY
3540 DrawIcon = MetaFileDC.DrawIconXY
3541 DrawBitmap = MetaFileDC.DrawBitmapXY
3542 DrawText = MetaFileDC.DrawTextXY
3543 DrawRotatedText = MetaFileDC.DrawRotatedTextXY
3544 Blit = MetaFileDC.BlitXY
3545
3546class PrinterDC_old(PrinterDC):
3547 """DC class that has methods with 2.4 compatible parameters."""
3548 FloodFill = PrinterDC.FloodFillXY
3549 GetPixel = PrinterDC.GetPixelXY
3550 DrawLine = PrinterDC.DrawLineXY
3551 CrossHair = PrinterDC.CrossHairXY
3552 DrawArc = PrinterDC.DrawArcXY
3553 DrawCheckMark = PrinterDC.DrawCheckMarkXY
3554 DrawEllipticArc = PrinterDC.DrawEllipticArcXY
3555 DrawPoint = PrinterDC.DrawPointXY
3556 DrawRectangle = PrinterDC.DrawRectangleXY
3557 DrawRoundedRectangle = PrinterDC.DrawRoundedRectangleXY
3558 DrawCircle = PrinterDC.DrawCircleXY
3559 DrawEllipse = PrinterDC.DrawEllipseXY
3560 DrawIcon = PrinterDC.DrawIconXY
3561 DrawBitmap = PrinterDC.DrawBitmapXY
3562 DrawText = PrinterDC.DrawTextXY
3563 DrawRotatedText = PrinterDC.DrawRotatedTextXY
3564 Blit = PrinterDC.BlitXY
3565
d14a1e28
RD
3566#---------------------------------------------------------------------------
3567
3568IMAGELIST_DRAW_NORMAL = _gdi.IMAGELIST_DRAW_NORMAL
3569IMAGELIST_DRAW_TRANSPARENT = _gdi.IMAGELIST_DRAW_TRANSPARENT
3570IMAGELIST_DRAW_SELECTED = _gdi.IMAGELIST_DRAW_SELECTED
3571IMAGELIST_DRAW_FOCUSED = _gdi.IMAGELIST_DRAW_FOCUSED
3572IMAGE_LIST_NORMAL = _gdi.IMAGE_LIST_NORMAL
3573IMAGE_LIST_SMALL = _gdi.IMAGE_LIST_SMALL
3574IMAGE_LIST_STATE = _gdi.IMAGE_LIST_STATE
3575class ImageList(core.Object):
423f194a
RD
3576 def __repr__(self):
3577 return "<%s.%s; proxy of C++ wxImageList instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 3578 def __init__(self, *args, **kwargs):
423f194a 3579 """__init__(int width, int height, int mask=True, int initialCount=1) -> ImageList"""
d14a1e28
RD
3580 newobj = _gdi.new_ImageList(*args, **kwargs)
3581 self.this = newobj.this
9416aa89 3582 self.thisown = 1
d14a1e28
RD
3583 del newobj.thisown
3584 def __del__(self, destroy=_gdi.delete_ImageList):
423f194a 3585 """__del__()"""
d14a1e28
RD
3586 try:
3587 if self.thisown: destroy(self)
3588 except: pass
423f194a
RD
3589
3590 def Add(*args, **kwargs):
3591 """Add(Bitmap bitmap, Bitmap mask=NullBitmap) -> int"""
3592 return _gdi.ImageList_Add(*args, **kwargs)
3593
3594 def AddWithColourMask(*args, **kwargs):
3595 """AddWithColourMask(Bitmap bitmap, Colour maskColour) -> int"""
3596 return _gdi.ImageList_AddWithColourMask(*args, **kwargs)
3597
3598 def AddIcon(*args, **kwargs):
3599 """AddIcon(Icon icon) -> int"""
3600 return _gdi.ImageList_AddIcon(*args, **kwargs)
3601
3602 def Replace(*args, **kwargs):
3603 """Replace(int index, Bitmap bitmap, Bitmap mask=NullBitmap) -> bool"""
3604 return _gdi.ImageList_Replace(*args, **kwargs)
3605
3606 def Draw(*args, **kwargs):
41f1cec7
RD
3607 """
3608 Draw(int index, DC dc, int x, int x, int flags=IMAGELIST_DRAW_NORMAL,
3609 bool solidBackground=False) -> bool
3610 """
423f194a
RD
3611 return _gdi.ImageList_Draw(*args, **kwargs)
3612
3613 def GetImageCount(*args, **kwargs):
3614 """GetImageCount() -> int"""
3615 return _gdi.ImageList_GetImageCount(*args, **kwargs)
3616
3617 def Remove(*args, **kwargs):
3618 """Remove(int index) -> bool"""
3619 return _gdi.ImageList_Remove(*args, **kwargs)
3620
3621 def RemoveAll(*args, **kwargs):
3622 """RemoveAll() -> bool"""
3623 return _gdi.ImageList_RemoveAll(*args, **kwargs)
3624
3625 def GetSize(*args, **kwargs):
44127b65 3626 """GetSize() -> (width,height)"""
423f194a
RD
3627 return _gdi.ImageList_GetSize(*args, **kwargs)
3628
9416aa89 3629
d14a1e28
RD
3630class ImageListPtr(ImageList):
3631 def __init__(self, this):
9416aa89 3632 self.this = this
d14a1e28
RD
3633 if not hasattr(self,"thisown"): self.thisown = 0
3634 self.__class__ = ImageList
3635_gdi.ImageList_swigregister(ImageListPtr)
3636
3637#---------------------------------------------------------------------------
3638
3639class PenList(core.Object):
d14a1e28 3640 def __init__(self): raise RuntimeError, "No constructor defined"
9416aa89 3641 def __repr__(self):
d14a1e28 3642 return "<%s.%s; proxy of C++ wxPenList instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
423f194a
RD
3643 def AddPen(*args, **kwargs):
3644 """AddPen(Pen pen)"""
3645 return _gdi.PenList_AddPen(*args, **kwargs)
3646
3647 def FindOrCreatePen(*args, **kwargs):
3648 """FindOrCreatePen(Colour colour, int width, int style) -> Pen"""
3649 return _gdi.PenList_FindOrCreatePen(*args, **kwargs)
3650
3651 def RemovePen(*args, **kwargs):
3652 """RemovePen(Pen pen)"""
3653 return _gdi.PenList_RemovePen(*args, **kwargs)
3654
3655 def GetCount(*args, **kwargs):
3656 """GetCount() -> int"""
3657 return _gdi.PenList_GetCount(*args, **kwargs)
3658
8ab979d7 3659
d14a1e28
RD
3660class PenListPtr(PenList):
3661 def __init__(self, this):
3662 self.this = this
3663 if not hasattr(self,"thisown"): self.thisown = 0
3664 self.__class__ = PenList
3665_gdi.PenList_swigregister(PenListPtr)
8edf1c75
RD
3666cvar = _gdi.cvar
3667NORMAL_FONT = cvar.NORMAL_FONT
3668SMALL_FONT = cvar.SMALL_FONT
3669ITALIC_FONT = cvar.ITALIC_FONT
3670SWISS_FONT = cvar.SWISS_FONT
3671RED_PEN = cvar.RED_PEN
3672CYAN_PEN = cvar.CYAN_PEN
3673GREEN_PEN = cvar.GREEN_PEN
3674BLACK_PEN = cvar.BLACK_PEN
3675WHITE_PEN = cvar.WHITE_PEN
3676TRANSPARENT_PEN = cvar.TRANSPARENT_PEN
3677BLACK_DASHED_PEN = cvar.BLACK_DASHED_PEN
3678GREY_PEN = cvar.GREY_PEN
3679MEDIUM_GREY_PEN = cvar.MEDIUM_GREY_PEN
3680LIGHT_GREY_PEN = cvar.LIGHT_GREY_PEN
3681BLUE_BRUSH = cvar.BLUE_BRUSH
3682GREEN_BRUSH = cvar.GREEN_BRUSH
3683WHITE_BRUSH = cvar.WHITE_BRUSH
3684BLACK_BRUSH = cvar.BLACK_BRUSH
3685TRANSPARENT_BRUSH = cvar.TRANSPARENT_BRUSH
3686CYAN_BRUSH = cvar.CYAN_BRUSH
3687RED_BRUSH = cvar.RED_BRUSH
3688GREY_BRUSH = cvar.GREY_BRUSH
3689MEDIUM_GREY_BRUSH = cvar.MEDIUM_GREY_BRUSH
3690LIGHT_GREY_BRUSH = cvar.LIGHT_GREY_BRUSH
3691BLACK = cvar.BLACK
3692WHITE = cvar.WHITE
3693RED = cvar.RED
3694BLUE = cvar.BLUE
3695GREEN = cvar.GREEN
3696CYAN = cvar.CYAN
3697LIGHT_GREY = cvar.LIGHT_GREY
3698STANDARD_CURSOR = cvar.STANDARD_CURSOR
3699HOURGLASS_CURSOR = cvar.HOURGLASS_CURSOR
3700CROSS_CURSOR = cvar.CROSS_CURSOR
3701NullBitmap = cvar.NullBitmap
3702NullIcon = cvar.NullIcon
3703NullCursor = cvar.NullCursor
3704NullPen = cvar.NullPen
3705NullBrush = cvar.NullBrush
3706NullPalette = cvar.NullPalette
3707NullFont = cvar.NullFont
3708NullColour = cvar.NullColour
d14a1e28
RD
3709
3710class BrushList(core.Object):
d14a1e28
RD
3711 def __init__(self): raise RuntimeError, "No constructor defined"
3712 def __repr__(self):
3713 return "<%s.%s; proxy of C++ wxBrushList instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
423f194a
RD
3714 def AddBrush(*args, **kwargs):
3715 """AddBrush(Brush brush)"""
3716 return _gdi.BrushList_AddBrush(*args, **kwargs)
3717
3718 def FindOrCreateBrush(*args, **kwargs):
3719 """FindOrCreateBrush(Colour colour, int style) -> Brush"""
3720 return _gdi.BrushList_FindOrCreateBrush(*args, **kwargs)
3721
3722 def RemoveBrush(*args, **kwargs):
3723 """RemoveBrush(Brush brush)"""
3724 return _gdi.BrushList_RemoveBrush(*args, **kwargs)
3725
3726 def GetCount(*args, **kwargs):
3727 """GetCount() -> int"""
3728 return _gdi.BrushList_GetCount(*args, **kwargs)
3729
8ab979d7 3730
d14a1e28
RD
3731class BrushListPtr(BrushList):
3732 def __init__(self, this):
3733 self.this = this
3734 if not hasattr(self,"thisown"): self.thisown = 0
3735 self.__class__ = BrushList
3736_gdi.BrushList_swigregister(BrushListPtr)
3737
3738class ColourDatabase(core.Object):
423f194a
RD
3739 def __repr__(self):
3740 return "<%s.%s; proxy of C++ wxColourDatabase instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 3741 def __init__(self, *args, **kwargs):
423f194a 3742 """__init__() -> ColourDatabase"""
d14a1e28
RD
3743 newobj = _gdi.new_ColourDatabase(*args, **kwargs)
3744 self.this = newobj.this
3745 self.thisown = 1
3746 del newobj.thisown
3747 def __del__(self, destroy=_gdi.delete_ColourDatabase):
423f194a 3748 """__del__()"""
d14a1e28
RD
3749 try:
3750 if self.thisown: destroy(self)
3751 except: pass
423f194a
RD
3752
3753 def Find(*args, **kwargs):
d03fd34d 3754 """Find(String name) -> Colour"""
423f194a
RD
3755 return _gdi.ColourDatabase_Find(*args, **kwargs)
3756
3757 def FindName(*args, **kwargs):
d03fd34d 3758 """FindName(Colour colour) -> String"""
423f194a
RD
3759 return _gdi.ColourDatabase_FindName(*args, **kwargs)
3760
d14a1e28 3761 FindColour = Find
423f194a 3762 def AddColour(*args, **kwargs):
d03fd34d 3763 """AddColour(String name, Colour colour)"""
423f194a
RD
3764 return _gdi.ColourDatabase_AddColour(*args, **kwargs)
3765
3766 def Append(*args, **kwargs):
d03fd34d 3767 """Append(String name, int red, int green, int blue)"""
423f194a
RD
3768 return _gdi.ColourDatabase_Append(*args, **kwargs)
3769
96bfd053 3770
d14a1e28
RD
3771class ColourDatabasePtr(ColourDatabase):
3772 def __init__(self, this):
3773 self.this = this
3774 if not hasattr(self,"thisown"): self.thisown = 0
3775 self.__class__ = ColourDatabase
3776_gdi.ColourDatabase_swigregister(ColourDatabasePtr)
3777
3778class FontList(core.Object):
d14a1e28
RD
3779 def __init__(self): raise RuntimeError, "No constructor defined"
3780 def __repr__(self):
3781 return "<%s.%s; proxy of C++ wxFontList instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
423f194a
RD
3782 def AddFont(*args, **kwargs):
3783 """AddFont(Font font)"""
3784 return _gdi.FontList_AddFont(*args, **kwargs)
3785
3786 def FindOrCreateFont(*args, **kwargs):
41f1cec7
RD
3787 """
3788 FindOrCreateFont(int point_size, int family, int style, int weight,
d03fd34d
RD
3789 bool underline=False, String facename=EmptyString,
3790 int encoding=FONTENCODING_DEFAULT) -> Font
41f1cec7 3791 """
423f194a
RD
3792 return _gdi.FontList_FindOrCreateFont(*args, **kwargs)
3793
3794 def RemoveFont(*args, **kwargs):
3795 """RemoveFont(Font font)"""
3796 return _gdi.FontList_RemoveFont(*args, **kwargs)
3797
3798 def GetCount(*args, **kwargs):
3799 """GetCount() -> int"""
3800 return _gdi.FontList_GetCount(*args, **kwargs)
3801
96bfd053 3802
d14a1e28
RD
3803class FontListPtr(FontList):
3804 def __init__(self, this):
3805 self.this = this
3806 if not hasattr(self,"thisown"): self.thisown = 0
3807 self.__class__ = FontList
3808_gdi.FontList_swigregister(FontListPtr)
1dc2f865 3809
d14a1e28 3810#---------------------------------------------------------------------------
1dc2f865 3811
8edf1c75 3812NullColor = NullColour
d14a1e28 3813#---------------------------------------------------------------------------
96bfd053 3814
423f194a 3815class Effects(core.Object):
423f194a
RD
3816 def __repr__(self):
3817 return "<%s.%s; proxy of C++ wxEffects instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 3818 def __init__(self, *args, **kwargs):
423f194a
RD
3819 """__init__() -> Effects"""
3820 newobj = _gdi.new_Effects(*args, **kwargs)
d14a1e28
RD
3821 self.this = newobj.this
3822 self.thisown = 1
3823 del newobj.thisown
423f194a
RD
3824 def GetHighlightColour(*args, **kwargs):
3825 """GetHighlightColour() -> Colour"""
3826 return _gdi.Effects_GetHighlightColour(*args, **kwargs)
3827
3828 def GetLightShadow(*args, **kwargs):
3829 """GetLightShadow() -> Colour"""
3830 return _gdi.Effects_GetLightShadow(*args, **kwargs)
3831
3832 def GetFaceColour(*args, **kwargs):
3833 """GetFaceColour() -> Colour"""
3834 return _gdi.Effects_GetFaceColour(*args, **kwargs)
3835
3836 def GetMediumShadow(*args, **kwargs):
3837 """GetMediumShadow() -> Colour"""
3838 return _gdi.Effects_GetMediumShadow(*args, **kwargs)
3839
3840 def GetDarkShadow(*args, **kwargs):
3841 """GetDarkShadow() -> Colour"""
3842 return _gdi.Effects_GetDarkShadow(*args, **kwargs)
3843
3844 def SetHighlightColour(*args, **kwargs):
3845 """SetHighlightColour(Colour c)"""
3846 return _gdi.Effects_SetHighlightColour(*args, **kwargs)
3847
3848 def SetLightShadow(*args, **kwargs):
3849 """SetLightShadow(Colour c)"""
3850 return _gdi.Effects_SetLightShadow(*args, **kwargs)
5a2a9da2 3851
423f194a
RD
3852 def SetFaceColour(*args, **kwargs):
3853 """SetFaceColour(Colour c)"""
3854 return _gdi.Effects_SetFaceColour(*args, **kwargs)
3855
3856 def SetMediumShadow(*args, **kwargs):
3857 """SetMediumShadow(Colour c)"""
3858 return _gdi.Effects_SetMediumShadow(*args, **kwargs)
3859
3860 def SetDarkShadow(*args, **kwargs):
3861 """SetDarkShadow(Colour c)"""
3862 return _gdi.Effects_SetDarkShadow(*args, **kwargs)
3863
3864 def Set(*args, **kwargs):
41f1cec7
RD
3865 """
3866 Set(Colour highlightColour, Colour lightShadow, Colour faceColour,
3867 Colour mediumShadow, Colour darkShadow)
3868 """
423f194a
RD
3869 return _gdi.Effects_Set(*args, **kwargs)
3870
3871 def DrawSunkenEdge(*args, **kwargs):
3872 """DrawSunkenEdge(DC dc, Rect rect, int borderSize=1)"""
3873 return _gdi.Effects_DrawSunkenEdge(*args, **kwargs)
3874
3875 def TileBitmap(*args, **kwargs):
3876 """TileBitmap(Rect rect, DC dc, Bitmap bitmap) -> bool"""
3877 return _gdi.Effects_TileBitmap(*args, **kwargs)
3878
3879
3880class EffectsPtr(Effects):
d14a1e28
RD
3881 def __init__(self, this):
3882 self.this = this
3883 if not hasattr(self,"thisown"): self.thisown = 0
423f194a
RD
3884 self.__class__ = Effects
3885_gdi.Effects_swigregister(EffectsPtr)
d14a1e28
RD
3886TheFontList = cvar.TheFontList
3887ThePenList = cvar.ThePenList
3888TheBrushList = cvar.TheBrushList
3889TheColourDatabase = cvar.TheColourDatabase
3890
1dc2f865 3891