]> git.saurik.com Git - wxWidgets.git/blob - wxPython/src/mac/_misc.py
Add *wxTopLevelWindowGTK*RequestUserAttention*int*;
[wxWidgets.git] / wxPython / src / mac / _misc.py
1 # This file was created automatically by SWIG.
2 # Don't modify this file, modify the SWIG interface instead.
3
4 import _misc_
5
6 def _swig_setattr_nondynamic(self,class_type,name,value,static=1):
7 if (name == "this"):
8 if isinstance(value, class_type):
9 self.__dict__[name] = value.this
10 if hasattr(value,"thisown"): self.__dict__["thisown"] = value.thisown
11 del value.thisown
12 return
13 method = class_type.__swig_setmethods__.get(name,None)
14 if method: return method(self,value)
15 if (not static) or hasattr(self,name) or (name == "thisown"):
16 self.__dict__[name] = value
17 else:
18 raise AttributeError("You cannot add attributes to %s" % self)
19
20 def _swig_setattr(self,class_type,name,value):
21 return _swig_setattr_nondynamic(self,class_type,name,value,0)
22
23 def _swig_getattr(self,class_type,name):
24 method = class_type.__swig_getmethods__.get(name,None)
25 if method: return method(self)
26 raise AttributeError,name
27
28 import types
29 try:
30 _object = types.ObjectType
31 _newclass = 1
32 except AttributeError:
33 class _object : pass
34 _newclass = 0
35 del types
36
37
38 def _swig_setattr_nondynamic_method(set):
39 def set_attr(self,name,value):
40 if hasattr(self,name) or (name in ("this", "thisown")):
41 set(self,name,value)
42 else:
43 raise AttributeError("You cannot add attributes to %s" % self)
44 return set_attr
45
46
47 import _core
48 wx = _core
49 #---------------------------------------------------------------------------
50
51 SYS_OEM_FIXED_FONT = _misc_.SYS_OEM_FIXED_FONT
52 SYS_ANSI_FIXED_FONT = _misc_.SYS_ANSI_FIXED_FONT
53 SYS_ANSI_VAR_FONT = _misc_.SYS_ANSI_VAR_FONT
54 SYS_SYSTEM_FONT = _misc_.SYS_SYSTEM_FONT
55 SYS_DEVICE_DEFAULT_FONT = _misc_.SYS_DEVICE_DEFAULT_FONT
56 SYS_DEFAULT_PALETTE = _misc_.SYS_DEFAULT_PALETTE
57 SYS_SYSTEM_FIXED_FONT = _misc_.SYS_SYSTEM_FIXED_FONT
58 SYS_DEFAULT_GUI_FONT = _misc_.SYS_DEFAULT_GUI_FONT
59 SYS_ICONTITLE_FONT = _misc_.SYS_ICONTITLE_FONT
60 SYS_COLOUR_SCROLLBAR = _misc_.SYS_COLOUR_SCROLLBAR
61 SYS_COLOUR_BACKGROUND = _misc_.SYS_COLOUR_BACKGROUND
62 SYS_COLOUR_DESKTOP = _misc_.SYS_COLOUR_DESKTOP
63 SYS_COLOUR_ACTIVECAPTION = _misc_.SYS_COLOUR_ACTIVECAPTION
64 SYS_COLOUR_INACTIVECAPTION = _misc_.SYS_COLOUR_INACTIVECAPTION
65 SYS_COLOUR_MENU = _misc_.SYS_COLOUR_MENU
66 SYS_COLOUR_WINDOW = _misc_.SYS_COLOUR_WINDOW
67 SYS_COLOUR_WINDOWFRAME = _misc_.SYS_COLOUR_WINDOWFRAME
68 SYS_COLOUR_MENUTEXT = _misc_.SYS_COLOUR_MENUTEXT
69 SYS_COLOUR_WINDOWTEXT = _misc_.SYS_COLOUR_WINDOWTEXT
70 SYS_COLOUR_CAPTIONTEXT = _misc_.SYS_COLOUR_CAPTIONTEXT
71 SYS_COLOUR_ACTIVEBORDER = _misc_.SYS_COLOUR_ACTIVEBORDER
72 SYS_COLOUR_INACTIVEBORDER = _misc_.SYS_COLOUR_INACTIVEBORDER
73 SYS_COLOUR_APPWORKSPACE = _misc_.SYS_COLOUR_APPWORKSPACE
74 SYS_COLOUR_HIGHLIGHT = _misc_.SYS_COLOUR_HIGHLIGHT
75 SYS_COLOUR_HIGHLIGHTTEXT = _misc_.SYS_COLOUR_HIGHLIGHTTEXT
76 SYS_COLOUR_BTNFACE = _misc_.SYS_COLOUR_BTNFACE
77 SYS_COLOUR_3DFACE = _misc_.SYS_COLOUR_3DFACE
78 SYS_COLOUR_BTNSHADOW = _misc_.SYS_COLOUR_BTNSHADOW
79 SYS_COLOUR_3DSHADOW = _misc_.SYS_COLOUR_3DSHADOW
80 SYS_COLOUR_GRAYTEXT = _misc_.SYS_COLOUR_GRAYTEXT
81 SYS_COLOUR_BTNTEXT = _misc_.SYS_COLOUR_BTNTEXT
82 SYS_COLOUR_INACTIVECAPTIONTEXT = _misc_.SYS_COLOUR_INACTIVECAPTIONTEXT
83 SYS_COLOUR_BTNHIGHLIGHT = _misc_.SYS_COLOUR_BTNHIGHLIGHT
84 SYS_COLOUR_BTNHILIGHT = _misc_.SYS_COLOUR_BTNHILIGHT
85 SYS_COLOUR_3DHIGHLIGHT = _misc_.SYS_COLOUR_3DHIGHLIGHT
86 SYS_COLOUR_3DHILIGHT = _misc_.SYS_COLOUR_3DHILIGHT
87 SYS_COLOUR_3DDKSHADOW = _misc_.SYS_COLOUR_3DDKSHADOW
88 SYS_COLOUR_3DLIGHT = _misc_.SYS_COLOUR_3DLIGHT
89 SYS_COLOUR_INFOTEXT = _misc_.SYS_COLOUR_INFOTEXT
90 SYS_COLOUR_INFOBK = _misc_.SYS_COLOUR_INFOBK
91 SYS_COLOUR_LISTBOX = _misc_.SYS_COLOUR_LISTBOX
92 SYS_COLOUR_HOTLIGHT = _misc_.SYS_COLOUR_HOTLIGHT
93 SYS_COLOUR_GRADIENTACTIVECAPTION = _misc_.SYS_COLOUR_GRADIENTACTIVECAPTION
94 SYS_COLOUR_GRADIENTINACTIVECAPTION = _misc_.SYS_COLOUR_GRADIENTINACTIVECAPTION
95 SYS_COLOUR_MENUHILIGHT = _misc_.SYS_COLOUR_MENUHILIGHT
96 SYS_COLOUR_MENUBAR = _misc_.SYS_COLOUR_MENUBAR
97 SYS_COLOUR_MAX = _misc_.SYS_COLOUR_MAX
98 SYS_MOUSE_BUTTONS = _misc_.SYS_MOUSE_BUTTONS
99 SYS_BORDER_X = _misc_.SYS_BORDER_X
100 SYS_BORDER_Y = _misc_.SYS_BORDER_Y
101 SYS_CURSOR_X = _misc_.SYS_CURSOR_X
102 SYS_CURSOR_Y = _misc_.SYS_CURSOR_Y
103 SYS_DCLICK_X = _misc_.SYS_DCLICK_X
104 SYS_DCLICK_Y = _misc_.SYS_DCLICK_Y
105 SYS_DRAG_X = _misc_.SYS_DRAG_X
106 SYS_DRAG_Y = _misc_.SYS_DRAG_Y
107 SYS_EDGE_X = _misc_.SYS_EDGE_X
108 SYS_EDGE_Y = _misc_.SYS_EDGE_Y
109 SYS_HSCROLL_ARROW_X = _misc_.SYS_HSCROLL_ARROW_X
110 SYS_HSCROLL_ARROW_Y = _misc_.SYS_HSCROLL_ARROW_Y
111 SYS_HTHUMB_X = _misc_.SYS_HTHUMB_X
112 SYS_ICON_X = _misc_.SYS_ICON_X
113 SYS_ICON_Y = _misc_.SYS_ICON_Y
114 SYS_ICONSPACING_X = _misc_.SYS_ICONSPACING_X
115 SYS_ICONSPACING_Y = _misc_.SYS_ICONSPACING_Y
116 SYS_WINDOWMIN_X = _misc_.SYS_WINDOWMIN_X
117 SYS_WINDOWMIN_Y = _misc_.SYS_WINDOWMIN_Y
118 SYS_SCREEN_X = _misc_.SYS_SCREEN_X
119 SYS_SCREEN_Y = _misc_.SYS_SCREEN_Y
120 SYS_FRAMESIZE_X = _misc_.SYS_FRAMESIZE_X
121 SYS_FRAMESIZE_Y = _misc_.SYS_FRAMESIZE_Y
122 SYS_SMALLICON_X = _misc_.SYS_SMALLICON_X
123 SYS_SMALLICON_Y = _misc_.SYS_SMALLICON_Y
124 SYS_HSCROLL_Y = _misc_.SYS_HSCROLL_Y
125 SYS_VSCROLL_X = _misc_.SYS_VSCROLL_X
126 SYS_VSCROLL_ARROW_X = _misc_.SYS_VSCROLL_ARROW_X
127 SYS_VSCROLL_ARROW_Y = _misc_.SYS_VSCROLL_ARROW_Y
128 SYS_VTHUMB_Y = _misc_.SYS_VTHUMB_Y
129 SYS_CAPTION_Y = _misc_.SYS_CAPTION_Y
130 SYS_MENU_Y = _misc_.SYS_MENU_Y
131 SYS_NETWORK_PRESENT = _misc_.SYS_NETWORK_PRESENT
132 SYS_PENWINDOWS_PRESENT = _misc_.SYS_PENWINDOWS_PRESENT
133 SYS_SHOW_SOUNDS = _misc_.SYS_SHOW_SOUNDS
134 SYS_SWAP_BUTTONS = _misc_.SYS_SWAP_BUTTONS
135 SYS_CAN_DRAW_FRAME_DECORATIONS = _misc_.SYS_CAN_DRAW_FRAME_DECORATIONS
136 SYS_CAN_ICONIZE_FRAME = _misc_.SYS_CAN_ICONIZE_FRAME
137 SYS_SCREEN_NONE = _misc_.SYS_SCREEN_NONE
138 SYS_SCREEN_TINY = _misc_.SYS_SCREEN_TINY
139 SYS_SCREEN_PDA = _misc_.SYS_SCREEN_PDA
140 SYS_SCREEN_SMALL = _misc_.SYS_SCREEN_SMALL
141 SYS_SCREEN_DESKTOP = _misc_.SYS_SCREEN_DESKTOP
142 class SystemSettings(object):
143 """Proxy of C++ SystemSettings class"""
144 def __init__(self): raise RuntimeError, "No constructor defined"
145 def __repr__(self):
146 return "<%s.%s; proxy of C++ wxSystemSettings instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
147 def GetColour(*args, **kwargs):
148 """GetColour(int index) -> Colour"""
149 return _misc_.SystemSettings_GetColour(*args, **kwargs)
150
151 GetColour = staticmethod(GetColour)
152 def GetFont(*args, **kwargs):
153 """GetFont(int index) -> Font"""
154 return _misc_.SystemSettings_GetFont(*args, **kwargs)
155
156 GetFont = staticmethod(GetFont)
157 def GetMetric(*args, **kwargs):
158 """GetMetric(int index, Window win=None) -> int"""
159 return _misc_.SystemSettings_GetMetric(*args, **kwargs)
160
161 GetMetric = staticmethod(GetMetric)
162 def HasFeature(*args, **kwargs):
163 """HasFeature(int index) -> bool"""
164 return _misc_.SystemSettings_HasFeature(*args, **kwargs)
165
166 HasFeature = staticmethod(HasFeature)
167 def GetScreenType(*args, **kwargs):
168 """GetScreenType() -> int"""
169 return _misc_.SystemSettings_GetScreenType(*args, **kwargs)
170
171 GetScreenType = staticmethod(GetScreenType)
172 def SetScreenType(*args, **kwargs):
173 """SetScreenType(int screen)"""
174 return _misc_.SystemSettings_SetScreenType(*args, **kwargs)
175
176 SetScreenType = staticmethod(SetScreenType)
177
178 class SystemSettingsPtr(SystemSettings):
179 def __init__(self, this):
180 self.this = this
181 if not hasattr(self,"thisown"): self.thisown = 0
182 self.__class__ = SystemSettings
183 _misc_.SystemSettings_swigregister(SystemSettingsPtr)
184
185 def SystemSettings_GetColour(*args, **kwargs):
186 """SystemSettings_GetColour(int index) -> Colour"""
187 return _misc_.SystemSettings_GetColour(*args, **kwargs)
188
189 def SystemSettings_GetFont(*args, **kwargs):
190 """SystemSettings_GetFont(int index) -> Font"""
191 return _misc_.SystemSettings_GetFont(*args, **kwargs)
192
193 def SystemSettings_GetMetric(*args, **kwargs):
194 """SystemSettings_GetMetric(int index, Window win=None) -> int"""
195 return _misc_.SystemSettings_GetMetric(*args, **kwargs)
196
197 def SystemSettings_HasFeature(*args, **kwargs):
198 """SystemSettings_HasFeature(int index) -> bool"""
199 return _misc_.SystemSettings_HasFeature(*args, **kwargs)
200
201 def SystemSettings_GetScreenType(*args, **kwargs):
202 """SystemSettings_GetScreenType() -> int"""
203 return _misc_.SystemSettings_GetScreenType(*args, **kwargs)
204
205 def SystemSettings_SetScreenType(*args, **kwargs):
206 """SystemSettings_SetScreenType(int screen)"""
207 return _misc_.SystemSettings_SetScreenType(*args, **kwargs)
208
209 class SystemOptions(_core.Object):
210 """Proxy of C++ SystemOptions class"""
211 def __repr__(self):
212 return "<%s.%s; proxy of C++ wxSystemOptions instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
213 def __init__(self, *args, **kwargs):
214 """__init__(self) -> SystemOptions"""
215 newobj = _misc_.new_SystemOptions(*args, **kwargs)
216 self.this = newobj.this
217 self.thisown = 1
218 del newobj.thisown
219 def SetOption(*args, **kwargs):
220 """SetOption(String name, String value)"""
221 return _misc_.SystemOptions_SetOption(*args, **kwargs)
222
223 SetOption = staticmethod(SetOption)
224 def SetOptionInt(*args, **kwargs):
225 """SetOptionInt(String name, int value)"""
226 return _misc_.SystemOptions_SetOptionInt(*args, **kwargs)
227
228 SetOptionInt = staticmethod(SetOptionInt)
229 def GetOption(*args, **kwargs):
230 """GetOption(String name) -> String"""
231 return _misc_.SystemOptions_GetOption(*args, **kwargs)
232
233 GetOption = staticmethod(GetOption)
234 def GetOptionInt(*args, **kwargs):
235 """GetOptionInt(String name) -> int"""
236 return _misc_.SystemOptions_GetOptionInt(*args, **kwargs)
237
238 GetOptionInt = staticmethod(GetOptionInt)
239 def HasOption(*args, **kwargs):
240 """HasOption(String name) -> bool"""
241 return _misc_.SystemOptions_HasOption(*args, **kwargs)
242
243 HasOption = staticmethod(HasOption)
244 def IsFalse(*args, **kwargs):
245 """IsFalse(String name) -> bool"""
246 return _misc_.SystemOptions_IsFalse(*args, **kwargs)
247
248 IsFalse = staticmethod(IsFalse)
249
250 class SystemOptionsPtr(SystemOptions):
251 def __init__(self, this):
252 self.this = this
253 if not hasattr(self,"thisown"): self.thisown = 0
254 self.__class__ = SystemOptions
255 _misc_.SystemOptions_swigregister(SystemOptionsPtr)
256 cvar = _misc_.cvar
257 WINDOW_DEFAULT_VARIANT = cvar.WINDOW_DEFAULT_VARIANT
258
259 def SystemOptions_SetOption(*args, **kwargs):
260 """SystemOptions_SetOption(String name, String value)"""
261 return _misc_.SystemOptions_SetOption(*args, **kwargs)
262
263 def SystemOptions_SetOptionInt(*args, **kwargs):
264 """SystemOptions_SetOptionInt(String name, int value)"""
265 return _misc_.SystemOptions_SetOptionInt(*args, **kwargs)
266
267 def SystemOptions_GetOption(*args, **kwargs):
268 """SystemOptions_GetOption(String name) -> String"""
269 return _misc_.SystemOptions_GetOption(*args, **kwargs)
270
271 def SystemOptions_GetOptionInt(*args, **kwargs):
272 """SystemOptions_GetOptionInt(String name) -> int"""
273 return _misc_.SystemOptions_GetOptionInt(*args, **kwargs)
274
275 def SystemOptions_HasOption(*args, **kwargs):
276 """SystemOptions_HasOption(String name) -> bool"""
277 return _misc_.SystemOptions_HasOption(*args, **kwargs)
278
279 def SystemOptions_IsFalse(*args, **kwargs):
280 """SystemOptions_IsFalse(String name) -> bool"""
281 return _misc_.SystemOptions_IsFalse(*args, **kwargs)
282
283 #---------------------------------------------------------------------------
284
285
286 def NewId(*args, **kwargs):
287 """NewId() -> long"""
288 return _misc_.NewId(*args, **kwargs)
289
290 def RegisterId(*args, **kwargs):
291 """RegisterId(long id)"""
292 return _misc_.RegisterId(*args, **kwargs)
293
294 def GetCurrentId(*args, **kwargs):
295 """GetCurrentId() -> long"""
296 return _misc_.GetCurrentId(*args, **kwargs)
297
298 def IsStockID(*args, **kwargs):
299 """IsStockID(int id) -> bool"""
300 return _misc_.IsStockID(*args, **kwargs)
301
302 def IsStockLabel(*args, **kwargs):
303 """IsStockLabel(int id, String label) -> bool"""
304 return _misc_.IsStockLabel(*args, **kwargs)
305
306 def GetStockLabel(*args, **kwargs):
307 """GetStockLabel(int id, bool withCodes=True, String accelerator=EmptyString) -> String"""
308 return _misc_.GetStockLabel(*args, **kwargs)
309
310 def Bell(*args, **kwargs):
311 """Bell()"""
312 return _misc_.Bell(*args, **kwargs)
313
314 def EndBusyCursor(*args, **kwargs):
315 """EndBusyCursor()"""
316 return _misc_.EndBusyCursor(*args, **kwargs)
317
318 def GetElapsedTime(*args, **kwargs):
319 """GetElapsedTime(bool resetTimer=True) -> long"""
320 return _misc_.GetElapsedTime(*args, **kwargs)
321
322 def GetMousePosition(*args, **kwargs):
323 """GetMousePosition() -> (x,y)"""
324 return _misc_.GetMousePosition(*args, **kwargs)
325
326 def IsBusy(*args, **kwargs):
327 """IsBusy() -> bool"""
328 return _misc_.IsBusy(*args, **kwargs)
329
330 def Now(*args, **kwargs):
331 """Now() -> String"""
332 return _misc_.Now(*args, **kwargs)
333
334 def Shell(*args, **kwargs):
335 """Shell(String command=EmptyString) -> bool"""
336 return _misc_.Shell(*args, **kwargs)
337
338 def StartTimer(*args, **kwargs):
339 """StartTimer()"""
340 return _misc_.StartTimer(*args, **kwargs)
341
342 def GetOsVersion(*args, **kwargs):
343 """GetOsVersion() -> (platform, major, minor)"""
344 return _misc_.GetOsVersion(*args, **kwargs)
345
346 def GetOsDescription(*args, **kwargs):
347 """GetOsDescription() -> String"""
348 return _misc_.GetOsDescription(*args, **kwargs)
349
350 def GetFreeMemory(*args, **kwargs):
351 """GetFreeMemory() -> long"""
352 return _misc_.GetFreeMemory(*args, **kwargs)
353 SHUTDOWN_POWEROFF = _misc_.SHUTDOWN_POWEROFF
354 SHUTDOWN_REBOOT = _misc_.SHUTDOWN_REBOOT
355
356 def Shutdown(*args, **kwargs):
357 """Shutdown(int wFlags) -> bool"""
358 return _misc_.Shutdown(*args, **kwargs)
359
360 def Sleep(*args, **kwargs):
361 """Sleep(int secs)"""
362 return _misc_.Sleep(*args, **kwargs)
363
364 def MilliSleep(*args, **kwargs):
365 """MilliSleep(unsigned long milliseconds)"""
366 return _misc_.MilliSleep(*args, **kwargs)
367
368 def MicroSleep(*args, **kwargs):
369 """MicroSleep(unsigned long microseconds)"""
370 return _misc_.MicroSleep(*args, **kwargs)
371 Usleep = MilliSleep
372
373 def EnableTopLevelWindows(*args, **kwargs):
374 """EnableTopLevelWindows(bool enable)"""
375 return _misc_.EnableTopLevelWindows(*args, **kwargs)
376
377 def StripMenuCodes(*args, **kwargs):
378 """StripMenuCodes(String in) -> String"""
379 return _misc_.StripMenuCodes(*args, **kwargs)
380
381 def GetEmailAddress(*args, **kwargs):
382 """GetEmailAddress() -> String"""
383 return _misc_.GetEmailAddress(*args, **kwargs)
384
385 def GetHostName(*args, **kwargs):
386 """GetHostName() -> String"""
387 return _misc_.GetHostName(*args, **kwargs)
388
389 def GetFullHostName(*args, **kwargs):
390 """GetFullHostName() -> String"""
391 return _misc_.GetFullHostName(*args, **kwargs)
392
393 def GetUserId(*args, **kwargs):
394 """GetUserId() -> String"""
395 return _misc_.GetUserId(*args, **kwargs)
396
397 def GetUserName(*args, **kwargs):
398 """GetUserName() -> String"""
399 return _misc_.GetUserName(*args, **kwargs)
400
401 def GetHomeDir(*args, **kwargs):
402 """GetHomeDir() -> String"""
403 return _misc_.GetHomeDir(*args, **kwargs)
404
405 def GetUserHome(*args, **kwargs):
406 """GetUserHome(String user=EmptyString) -> String"""
407 return _misc_.GetUserHome(*args, **kwargs)
408
409 def GetProcessId(*args, **kwargs):
410 """GetProcessId() -> unsigned long"""
411 return _misc_.GetProcessId(*args, **kwargs)
412
413 def Trap(*args, **kwargs):
414 """Trap()"""
415 return _misc_.Trap(*args, **kwargs)
416
417 def FileSelector(*args, **kwargs):
418 """
419 FileSelector(String message=FileSelectorPromptStr, String default_path=EmptyString,
420 String default_filename=EmptyString,
421 String default_extension=EmptyString,
422 String wildcard=FileSelectorDefaultWildcardStr,
423 int flags=0, Window parent=None, int x=-1,
424 int y=-1) -> String
425 """
426 return _misc_.FileSelector(*args, **kwargs)
427
428 def LoadFileSelector(*args, **kwargs):
429 """
430 LoadFileSelector(String what, String extension, String default_name=EmptyString,
431 Window parent=None) -> String
432 """
433 return _misc_.LoadFileSelector(*args, **kwargs)
434
435 def SaveFileSelector(*args, **kwargs):
436 """
437 SaveFileSelector(String what, String extension, String default_name=EmptyString,
438 Window parent=None) -> String
439 """
440 return _misc_.SaveFileSelector(*args, **kwargs)
441
442 def DirSelector(*args, **kwargs):
443 """
444 DirSelector(String message=DirSelectorPromptStr, String defaultPath=EmptyString,
445 long style=DD_DEFAULT_STYLE,
446 Point pos=DefaultPosition, Window parent=None) -> String
447 """
448 return _misc_.DirSelector(*args, **kwargs)
449
450 def GetTextFromUser(*args, **kwargs):
451 """
452 GetTextFromUser(String message, String caption=EmptyString, String default_value=EmptyString,
453 Window parent=None,
454 int x=-1, int y=-1, bool centre=True) -> String
455 """
456 return _misc_.GetTextFromUser(*args, **kwargs)
457
458 def GetPasswordFromUser(*args, **kwargs):
459 """
460 GetPasswordFromUser(String message, String caption=EmptyString, String default_value=EmptyString,
461 Window parent=None) -> String
462 """
463 return _misc_.GetPasswordFromUser(*args, **kwargs)
464
465 def GetSingleChoice(*args, **kwargs):
466 """
467 GetSingleChoice(String message, String caption, int choices, Window parent=None,
468 int x=-1, int y=-1, bool centre=True,
469 int width=150, int height=200) -> String
470 """
471 return _misc_.GetSingleChoice(*args, **kwargs)
472
473 def GetSingleChoiceIndex(*args, **kwargs):
474 """
475 GetSingleChoiceIndex(String message, String caption, int choices, Window parent=None,
476 int x=-1, int y=-1, bool centre=True,
477 int width=150, int height=200) -> int
478 """
479 return _misc_.GetSingleChoiceIndex(*args, **kwargs)
480
481 def MessageBox(*args, **kwargs):
482 """
483 MessageBox(String message, String caption=EmptyString, int style=wxOK|wxCENTRE,
484 Window parent=None, int x=-1,
485 int y=-1) -> int
486 """
487 return _misc_.MessageBox(*args, **kwargs)
488
489 def GetNumberFromUser(*args, **kwargs):
490 """
491 GetNumberFromUser(String message, String prompt, String caption, long value,
492 long min=0, long max=100, Window parent=None,
493 Point pos=DefaultPosition) -> long
494 """
495 return _misc_.GetNumberFromUser(*args, **kwargs)
496
497 def ColourDisplay(*args, **kwargs):
498 """ColourDisplay() -> bool"""
499 return _misc_.ColourDisplay(*args, **kwargs)
500
501 def DisplayDepth(*args, **kwargs):
502 """DisplayDepth() -> int"""
503 return _misc_.DisplayDepth(*args, **kwargs)
504
505 def GetDisplayDepth(*args, **kwargs):
506 """GetDisplayDepth() -> int"""
507 return _misc_.GetDisplayDepth(*args, **kwargs)
508
509 def DisplaySize(*args, **kwargs):
510 """DisplaySize() -> (width, height)"""
511 return _misc_.DisplaySize(*args, **kwargs)
512
513 def GetDisplaySize(*args, **kwargs):
514 """GetDisplaySize() -> Size"""
515 return _misc_.GetDisplaySize(*args, **kwargs)
516
517 def DisplaySizeMM(*args, **kwargs):
518 """DisplaySizeMM() -> (width, height)"""
519 return _misc_.DisplaySizeMM(*args, **kwargs)
520
521 def GetDisplaySizeMM(*args, **kwargs):
522 """GetDisplaySizeMM() -> Size"""
523 return _misc_.GetDisplaySizeMM(*args, **kwargs)
524
525 def ClientDisplayRect(*args, **kwargs):
526 """ClientDisplayRect() -> (x, y, width, height)"""
527 return _misc_.ClientDisplayRect(*args, **kwargs)
528
529 def GetClientDisplayRect(*args, **kwargs):
530 """GetClientDisplayRect() -> Rect"""
531 return _misc_.GetClientDisplayRect(*args, **kwargs)
532
533 def SetCursor(*args, **kwargs):
534 """SetCursor(Cursor cursor)"""
535 return _misc_.SetCursor(*args, **kwargs)
536
537 def GetXDisplay(*args, **kwargs):
538 """
539 GetXDisplay() -> void
540
541 Returns a swigified pointer to the X11 display. Returns None on
542 other platforms.
543 """
544 return _misc_.GetXDisplay(*args, **kwargs)
545
546 def BeginBusyCursor(*args, **kwargs):
547 """BeginBusyCursor(Cursor cursor=wxHOURGLASS_CURSOR)"""
548 return _misc_.BeginBusyCursor(*args, **kwargs)
549
550 def GetActiveWindow(*args, **kwargs):
551 """GetActiveWindow() -> Window"""
552 return _misc_.GetActiveWindow(*args, **kwargs)
553
554 def GenericFindWindowAtPoint(*args, **kwargs):
555 """GenericFindWindowAtPoint(Point pt) -> Window"""
556 return _misc_.GenericFindWindowAtPoint(*args, **kwargs)
557
558 def FindWindowAtPoint(*args, **kwargs):
559 """FindWindowAtPoint(Point pt) -> Window"""
560 return _misc_.FindWindowAtPoint(*args, **kwargs)
561
562 def GetTopLevelParent(*args, **kwargs):
563 """GetTopLevelParent(Window win) -> Window"""
564 return _misc_.GetTopLevelParent(*args, **kwargs)
565
566 def LaunchDefaultBrowser(*args, **kwargs):
567 """
568 LaunchDefaultBrowser(String url) -> bool
569
570 Launches the user's default browser and tells it to open the location
571 at ``url``. Returns ``True`` if the application was successfully
572 launched.
573 """
574 return _misc_.LaunchDefaultBrowser(*args, **kwargs)
575
576 def GetKeyState(*args, **kwargs):
577 """
578 GetKeyState(int key) -> bool
579
580 Get the state of a key (true if pressed or toggled on, false if not.)
581 This is generally most useful getting the state of the modifier or
582 toggle keys. On some platforms those may be the only keys that work.
583
584 """
585 return _misc_.GetKeyState(*args, **kwargs)
586
587 def WakeUpMainThread(*args, **kwargs):
588 """WakeUpMainThread()"""
589 return _misc_.WakeUpMainThread(*args, **kwargs)
590
591 def MutexGuiEnter(*args, **kwargs):
592 """MutexGuiEnter()"""
593 return _misc_.MutexGuiEnter(*args, **kwargs)
594
595 def MutexGuiLeave(*args, **kwargs):
596 """MutexGuiLeave()"""
597 return _misc_.MutexGuiLeave(*args, **kwargs)
598 class MutexGuiLocker(object):
599 """Proxy of C++ MutexGuiLocker class"""
600 def __repr__(self):
601 return "<%s.%s; proxy of C++ wxMutexGuiLocker instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
602 def __init__(self, *args, **kwargs):
603 """__init__(self) -> MutexGuiLocker"""
604 newobj = _misc_.new_MutexGuiLocker(*args, **kwargs)
605 self.this = newobj.this
606 self.thisown = 1
607 del newobj.thisown
608 def __del__(self, destroy=_misc_.delete_MutexGuiLocker):
609 """__del__(self)"""
610 try:
611 if self.thisown: destroy(self)
612 except: pass
613
614
615 class MutexGuiLockerPtr(MutexGuiLocker):
616 def __init__(self, this):
617 self.this = this
618 if not hasattr(self,"thisown"): self.thisown = 0
619 self.__class__ = MutexGuiLocker
620 _misc_.MutexGuiLocker_swigregister(MutexGuiLockerPtr)
621 FileSelectorPromptStr = cvar.FileSelectorPromptStr
622 FileSelectorDefaultWildcardStr = cvar.FileSelectorDefaultWildcardStr
623 DirSelectorPromptStr = cvar.DirSelectorPromptStr
624
625
626 def Thread_IsMain(*args, **kwargs):
627 """Thread_IsMain() -> bool"""
628 return _misc_.Thread_IsMain(*args, **kwargs)
629 #---------------------------------------------------------------------------
630
631 class ToolTip(_core.Object):
632 """Proxy of C++ ToolTip class"""
633 def __repr__(self):
634 return "<%s.%s; proxy of C++ wxToolTip instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
635 def __init__(self, *args, **kwargs):
636 """__init__(self, String tip) -> ToolTip"""
637 newobj = _misc_.new_ToolTip(*args, **kwargs)
638 self.this = newobj.this
639 self.thisown = 1
640 del newobj.thisown
641 def SetTip(*args, **kwargs):
642 """SetTip(self, String tip)"""
643 return _misc_.ToolTip_SetTip(*args, **kwargs)
644
645 def GetTip(*args, **kwargs):
646 """GetTip(self) -> String"""
647 return _misc_.ToolTip_GetTip(*args, **kwargs)
648
649 def GetWindow(*args, **kwargs):
650 """GetWindow(self) -> Window"""
651 return _misc_.ToolTip_GetWindow(*args, **kwargs)
652
653 def Enable(*args, **kwargs):
654 """Enable(bool flag)"""
655 return _misc_.ToolTip_Enable(*args, **kwargs)
656
657 Enable = staticmethod(Enable)
658 def SetDelay(*args, **kwargs):
659 """SetDelay(long milliseconds)"""
660 return _misc_.ToolTip_SetDelay(*args, **kwargs)
661
662 SetDelay = staticmethod(SetDelay)
663
664 class ToolTipPtr(ToolTip):
665 def __init__(self, this):
666 self.this = this
667 if not hasattr(self,"thisown"): self.thisown = 0
668 self.__class__ = ToolTip
669 _misc_.ToolTip_swigregister(ToolTipPtr)
670
671 def ToolTip_Enable(*args, **kwargs):
672 """ToolTip_Enable(bool flag)"""
673 return _misc_.ToolTip_Enable(*args, **kwargs)
674
675 def ToolTip_SetDelay(*args, **kwargs):
676 """ToolTip_SetDelay(long milliseconds)"""
677 return _misc_.ToolTip_SetDelay(*args, **kwargs)
678
679 class Caret(object):
680 """Proxy of C++ Caret class"""
681 def __repr__(self):
682 return "<%s.%s; proxy of C++ wxCaret instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
683 def __init__(self, *args, **kwargs):
684 """__init__(self, Window window, Size size) -> Caret"""
685 newobj = _misc_.new_Caret(*args, **kwargs)
686 self.this = newobj.this
687 self.thisown = 1
688 del newobj.thisown
689 def Destroy(*args, **kwargs):
690 """
691 Destroy(self)
692
693 Deletes the C++ object this Python object is a proxy for.
694 """
695 return _misc_.Caret_Destroy(*args, **kwargs)
696
697 def IsOk(*args, **kwargs):
698 """IsOk(self) -> bool"""
699 return _misc_.Caret_IsOk(*args, **kwargs)
700
701 def IsVisible(*args, **kwargs):
702 """IsVisible(self) -> bool"""
703 return _misc_.Caret_IsVisible(*args, **kwargs)
704
705 def GetPosition(*args, **kwargs):
706 """GetPosition(self) -> Point"""
707 return _misc_.Caret_GetPosition(*args, **kwargs)
708
709 def GetPositionTuple(*args, **kwargs):
710 """GetPositionTuple() -> (x,y)"""
711 return _misc_.Caret_GetPositionTuple(*args, **kwargs)
712
713 def GetSize(*args, **kwargs):
714 """GetSize(self) -> Size"""
715 return _misc_.Caret_GetSize(*args, **kwargs)
716
717 def GetSizeTuple(*args, **kwargs):
718 """GetSizeTuple() -> (width, height)"""
719 return _misc_.Caret_GetSizeTuple(*args, **kwargs)
720
721 def GetWindow(*args, **kwargs):
722 """GetWindow(self) -> Window"""
723 return _misc_.Caret_GetWindow(*args, **kwargs)
724
725 def MoveXY(*args, **kwargs):
726 """MoveXY(self, int x, int y)"""
727 return _misc_.Caret_MoveXY(*args, **kwargs)
728
729 def Move(*args, **kwargs):
730 """Move(self, Point pt)"""
731 return _misc_.Caret_Move(*args, **kwargs)
732
733 def SetSizeWH(*args, **kwargs):
734 """SetSizeWH(self, int width, int height)"""
735 return _misc_.Caret_SetSizeWH(*args, **kwargs)
736
737 def SetSize(*args, **kwargs):
738 """SetSize(self, Size size)"""
739 return _misc_.Caret_SetSize(*args, **kwargs)
740
741 def Show(*args, **kwargs):
742 """Show(self, int show=True)"""
743 return _misc_.Caret_Show(*args, **kwargs)
744
745 def Hide(*args, **kwargs):
746 """Hide(self)"""
747 return _misc_.Caret_Hide(*args, **kwargs)
748
749 def __nonzero__(self): return self.IsOk()
750 def GetBlinkTime(*args, **kwargs):
751 """GetBlinkTime() -> int"""
752 return _misc_.Caret_GetBlinkTime(*args, **kwargs)
753
754 GetBlinkTime = staticmethod(GetBlinkTime)
755 def SetBlinkTime(*args, **kwargs):
756 """SetBlinkTime(int milliseconds)"""
757 return _misc_.Caret_SetBlinkTime(*args, **kwargs)
758
759 SetBlinkTime = staticmethod(SetBlinkTime)
760
761 class CaretPtr(Caret):
762 def __init__(self, this):
763 self.this = this
764 if not hasattr(self,"thisown"): self.thisown = 0
765 self.__class__ = Caret
766 _misc_.Caret_swigregister(CaretPtr)
767
768 def Caret_GetBlinkTime(*args, **kwargs):
769 """Caret_GetBlinkTime() -> int"""
770 return _misc_.Caret_GetBlinkTime(*args, **kwargs)
771
772 def Caret_SetBlinkTime(*args, **kwargs):
773 """Caret_SetBlinkTime(int milliseconds)"""
774 return _misc_.Caret_SetBlinkTime(*args, **kwargs)
775
776 class BusyCursor(object):
777 """Proxy of C++ BusyCursor class"""
778 def __repr__(self):
779 return "<%s.%s; proxy of C++ wxBusyCursor instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
780 def __init__(self, *args, **kwargs):
781 """__init__(self, Cursor cursor=wxHOURGLASS_CURSOR) -> BusyCursor"""
782 newobj = _misc_.new_BusyCursor(*args, **kwargs)
783 self.this = newobj.this
784 self.thisown = 1
785 del newobj.thisown
786 def __del__(self, destroy=_misc_.delete_BusyCursor):
787 """__del__(self)"""
788 try:
789 if self.thisown: destroy(self)
790 except: pass
791
792
793 class BusyCursorPtr(BusyCursor):
794 def __init__(self, this):
795 self.this = this
796 if not hasattr(self,"thisown"): self.thisown = 0
797 self.__class__ = BusyCursor
798 _misc_.BusyCursor_swigregister(BusyCursorPtr)
799
800 class WindowDisabler(object):
801 """Proxy of C++ WindowDisabler class"""
802 def __repr__(self):
803 return "<%s.%s; proxy of C++ wxWindowDisabler instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
804 def __init__(self, *args, **kwargs):
805 """__init__(self, Window winToSkip=None) -> WindowDisabler"""
806 newobj = _misc_.new_WindowDisabler(*args, **kwargs)
807 self.this = newobj.this
808 self.thisown = 1
809 del newobj.thisown
810 def __del__(self, destroy=_misc_.delete_WindowDisabler):
811 """__del__(self)"""
812 try:
813 if self.thisown: destroy(self)
814 except: pass
815
816
817 class WindowDisablerPtr(WindowDisabler):
818 def __init__(self, this):
819 self.this = this
820 if not hasattr(self,"thisown"): self.thisown = 0
821 self.__class__ = WindowDisabler
822 _misc_.WindowDisabler_swigregister(WindowDisablerPtr)
823
824 class BusyInfo(_core.Object):
825 """Proxy of C++ BusyInfo class"""
826 def __repr__(self):
827 return "<%s.%s; proxy of C++ wxBusyInfo instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
828 def __init__(self, *args, **kwargs):
829 """__init__(self, String message) -> BusyInfo"""
830 newobj = _misc_.new_BusyInfo(*args, **kwargs)
831 self.this = newobj.this
832 self.thisown = 1
833 del newobj.thisown
834 def __del__(self, destroy=_misc_.delete_BusyInfo):
835 """__del__(self)"""
836 try:
837 if self.thisown: destroy(self)
838 except: pass
839
840
841 class BusyInfoPtr(BusyInfo):
842 def __init__(self, this):
843 self.this = this
844 if not hasattr(self,"thisown"): self.thisown = 0
845 self.__class__ = BusyInfo
846 _misc_.BusyInfo_swigregister(BusyInfoPtr)
847
848 class StopWatch(object):
849 """Proxy of C++ StopWatch class"""
850 def __repr__(self):
851 return "<%s.%s; proxy of C++ wxStopWatch instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
852 def __init__(self, *args, **kwargs):
853 """__init__(self) -> StopWatch"""
854 newobj = _misc_.new_StopWatch(*args, **kwargs)
855 self.this = newobj.this
856 self.thisown = 1
857 del newobj.thisown
858 def Start(*args, **kwargs):
859 """Start(self, long t0=0)"""
860 return _misc_.StopWatch_Start(*args, **kwargs)
861
862 def Pause(*args, **kwargs):
863 """Pause(self)"""
864 return _misc_.StopWatch_Pause(*args, **kwargs)
865
866 def Resume(*args, **kwargs):
867 """Resume(self)"""
868 return _misc_.StopWatch_Resume(*args, **kwargs)
869
870 def Time(*args, **kwargs):
871 """Time(self) -> long"""
872 return _misc_.StopWatch_Time(*args, **kwargs)
873
874
875 class StopWatchPtr(StopWatch):
876 def __init__(self, this):
877 self.this = this
878 if not hasattr(self,"thisown"): self.thisown = 0
879 self.__class__ = StopWatch
880 _misc_.StopWatch_swigregister(StopWatchPtr)
881
882 class FileHistory(_core.Object):
883 """Proxy of C++ FileHistory class"""
884 def __repr__(self):
885 return "<%s.%s; proxy of C++ wxFileHistory instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
886 def __init__(self, *args, **kwargs):
887 """__init__(self, int maxFiles=9, int idBase=ID_FILE1) -> FileHistory"""
888 newobj = _misc_.new_FileHistory(*args, **kwargs)
889 self.this = newobj.this
890 self.thisown = 1
891 del newobj.thisown
892 def __del__(self, destroy=_misc_.delete_FileHistory):
893 """__del__(self)"""
894 try:
895 if self.thisown: destroy(self)
896 except: pass
897
898 def AddFileToHistory(*args, **kwargs):
899 """AddFileToHistory(self, String file)"""
900 return _misc_.FileHistory_AddFileToHistory(*args, **kwargs)
901
902 def RemoveFileFromHistory(*args, **kwargs):
903 """RemoveFileFromHistory(self, int i)"""
904 return _misc_.FileHistory_RemoveFileFromHistory(*args, **kwargs)
905
906 def GetMaxFiles(*args, **kwargs):
907 """GetMaxFiles(self) -> int"""
908 return _misc_.FileHistory_GetMaxFiles(*args, **kwargs)
909
910 def UseMenu(*args, **kwargs):
911 """UseMenu(self, Menu menu)"""
912 return _misc_.FileHistory_UseMenu(*args, **kwargs)
913
914 def RemoveMenu(*args, **kwargs):
915 """RemoveMenu(self, Menu menu)"""
916 return _misc_.FileHistory_RemoveMenu(*args, **kwargs)
917
918 def Load(*args, **kwargs):
919 """Load(self, ConfigBase config)"""
920 return _misc_.FileHistory_Load(*args, **kwargs)
921
922 def Save(*args, **kwargs):
923 """Save(self, ConfigBase config)"""
924 return _misc_.FileHistory_Save(*args, **kwargs)
925
926 def AddFilesToMenu(*args, **kwargs):
927 """AddFilesToMenu(self)"""
928 return _misc_.FileHistory_AddFilesToMenu(*args, **kwargs)
929
930 def AddFilesToThisMenu(*args, **kwargs):
931 """AddFilesToThisMenu(self, Menu menu)"""
932 return _misc_.FileHistory_AddFilesToThisMenu(*args, **kwargs)
933
934 def GetHistoryFile(*args, **kwargs):
935 """GetHistoryFile(self, int i) -> String"""
936 return _misc_.FileHistory_GetHistoryFile(*args, **kwargs)
937
938 def GetCount(*args, **kwargs):
939 """GetCount(self) -> int"""
940 return _misc_.FileHistory_GetCount(*args, **kwargs)
941
942 GetNoHistoryFiles = GetCount
943
944 class FileHistoryPtr(FileHistory):
945 def __init__(self, this):
946 self.this = this
947 if not hasattr(self,"thisown"): self.thisown = 0
948 self.__class__ = FileHistory
949 _misc_.FileHistory_swigregister(FileHistoryPtr)
950
951 class SingleInstanceChecker(object):
952 """Proxy of C++ SingleInstanceChecker class"""
953 def __repr__(self):
954 return "<%s.%s; proxy of C++ wxSingleInstanceChecker instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
955 def __init__(self, *args, **kwargs):
956 """__init__(self, String name, String path=EmptyString) -> SingleInstanceChecker"""
957 newobj = _misc_.new_SingleInstanceChecker(*args, **kwargs)
958 self.this = newobj.this
959 self.thisown = 1
960 del newobj.thisown
961 def __del__(self, destroy=_misc_.delete_SingleInstanceChecker):
962 """__del__(self)"""
963 try:
964 if self.thisown: destroy(self)
965 except: pass
966
967 def Create(*args, **kwargs):
968 """Create(self, String name, String path=EmptyString) -> bool"""
969 return _misc_.SingleInstanceChecker_Create(*args, **kwargs)
970
971 def IsAnotherRunning(*args, **kwargs):
972 """IsAnotherRunning(self) -> bool"""
973 return _misc_.SingleInstanceChecker_IsAnotherRunning(*args, **kwargs)
974
975
976 class SingleInstanceCheckerPtr(SingleInstanceChecker):
977 def __init__(self, this):
978 self.this = this
979 if not hasattr(self,"thisown"): self.thisown = 0
980 self.__class__ = SingleInstanceChecker
981 _misc_.SingleInstanceChecker_swigregister(SingleInstanceCheckerPtr)
982
983 def PreSingleInstanceChecker(*args, **kwargs):
984 """PreSingleInstanceChecker() -> SingleInstanceChecker"""
985 val = _misc_.new_PreSingleInstanceChecker(*args, **kwargs)
986 val.thisown = 1
987 return val
988
989
990 def DrawWindowOnDC(*args, **kwargs):
991 """DrawWindowOnDC(Window window, DC dc) -> bool"""
992 return _misc_.DrawWindowOnDC(*args, **kwargs)
993 #---------------------------------------------------------------------------
994
995 class TipProvider(object):
996 """Proxy of C++ TipProvider class"""
997 def __init__(self): raise RuntimeError, "No constructor defined"
998 def __repr__(self):
999 return "<%s.%s; proxy of C++ wxTipProvider instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
1000 def __del__(self, destroy=_misc_.delete_TipProvider):
1001 """__del__(self)"""
1002 try:
1003 if self.thisown: destroy(self)
1004 except: pass
1005
1006 def GetTip(*args, **kwargs):
1007 """GetTip(self) -> String"""
1008 return _misc_.TipProvider_GetTip(*args, **kwargs)
1009
1010 def GetCurrentTip(*args, **kwargs):
1011 """GetCurrentTip(self) -> size_t"""
1012 return _misc_.TipProvider_GetCurrentTip(*args, **kwargs)
1013
1014 def PreprocessTip(*args, **kwargs):
1015 """PreprocessTip(self, String tip) -> String"""
1016 return _misc_.TipProvider_PreprocessTip(*args, **kwargs)
1017
1018
1019 class TipProviderPtr(TipProvider):
1020 def __init__(self, this):
1021 self.this = this
1022 if not hasattr(self,"thisown"): self.thisown = 0
1023 self.__class__ = TipProvider
1024 _misc_.TipProvider_swigregister(TipProviderPtr)
1025
1026 class PyTipProvider(TipProvider):
1027 """Proxy of C++ PyTipProvider class"""
1028 def __repr__(self):
1029 return "<%s.%s; proxy of C++ wxPyTipProvider instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
1030 def __init__(self, *args, **kwargs):
1031 """__init__(self, size_t currentTip) -> PyTipProvider"""
1032 newobj = _misc_.new_PyTipProvider(*args, **kwargs)
1033 self.this = newobj.this
1034 self.thisown = 1
1035 del newobj.thisown
1036 self._setCallbackInfo(self, PyTipProvider)
1037
1038 def _setCallbackInfo(*args, **kwargs):
1039 """_setCallbackInfo(self, PyObject self, PyObject _class)"""
1040 return _misc_.PyTipProvider__setCallbackInfo(*args, **kwargs)
1041
1042
1043 class PyTipProviderPtr(PyTipProvider):
1044 def __init__(self, this):
1045 self.this = this
1046 if not hasattr(self,"thisown"): self.thisown = 0
1047 self.__class__ = PyTipProvider
1048 _misc_.PyTipProvider_swigregister(PyTipProviderPtr)
1049
1050
1051 def ShowTip(*args, **kwargs):
1052 """ShowTip(Window parent, TipProvider tipProvider, bool showAtStartup=True) -> bool"""
1053 return _misc_.ShowTip(*args, **kwargs)
1054
1055 def CreateFileTipProvider(*args, **kwargs):
1056 """CreateFileTipProvider(String filename, size_t currentTip) -> TipProvider"""
1057 return _misc_.CreateFileTipProvider(*args, **kwargs)
1058 #---------------------------------------------------------------------------
1059
1060 TIMER_CONTINUOUS = _misc_.TIMER_CONTINUOUS
1061 TIMER_ONE_SHOT = _misc_.TIMER_ONE_SHOT
1062 wxEVT_TIMER = _misc_.wxEVT_TIMER
1063 class Timer(_core.EvtHandler):
1064 """Proxy of C++ Timer class"""
1065 def __repr__(self):
1066 return "<%s.%s; proxy of C++ wxPyTimer instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
1067 def __init__(self, *args, **kwargs):
1068 """__init__(self, EvtHandler owner=None, int id=-1) -> Timer"""
1069 newobj = _misc_.new_Timer(*args, **kwargs)
1070 self.this = newobj.this
1071 self.thisown = 1
1072 del newobj.thisown
1073 self._setCallbackInfo(self, Timer, 0); self._setOORInfo(self, 0)
1074
1075 def __del__(self, destroy=_misc_.delete_Timer):
1076 """__del__(self)"""
1077 try:
1078 if self.thisown: destroy(self)
1079 except: pass
1080
1081 def _setCallbackInfo(*args, **kwargs):
1082 """_setCallbackInfo(self, PyObject self, PyObject _class, int incref=1)"""
1083 return _misc_.Timer__setCallbackInfo(*args, **kwargs)
1084
1085 def SetOwner(*args, **kwargs):
1086 """SetOwner(self, EvtHandler owner, int id=-1)"""
1087 return _misc_.Timer_SetOwner(*args, **kwargs)
1088
1089 def GetOwner(*args, **kwargs):
1090 """GetOwner(self) -> EvtHandler"""
1091 return _misc_.Timer_GetOwner(*args, **kwargs)
1092
1093 def Start(*args, **kwargs):
1094 """Start(self, int milliseconds=-1, bool oneShot=False) -> bool"""
1095 return _misc_.Timer_Start(*args, **kwargs)
1096
1097 def Stop(*args, **kwargs):
1098 """Stop(self)"""
1099 return _misc_.Timer_Stop(*args, **kwargs)
1100
1101 def IsRunning(*args, **kwargs):
1102 """IsRunning(self) -> bool"""
1103 return _misc_.Timer_IsRunning(*args, **kwargs)
1104
1105 def GetInterval(*args, **kwargs):
1106 """GetInterval(self) -> int"""
1107 return _misc_.Timer_GetInterval(*args, **kwargs)
1108
1109 def IsOneShot(*args, **kwargs):
1110 """IsOneShot(self) -> bool"""
1111 return _misc_.Timer_IsOneShot(*args, **kwargs)
1112
1113 def GetId(*args, **kwargs):
1114 """GetId(self) -> int"""
1115 return _misc_.Timer_GetId(*args, **kwargs)
1116
1117 def Destroy(self):
1118 """NO-OP: Timers must be destroyed by normal refrence counting"""
1119 pass
1120
1121
1122 class TimerPtr(Timer):
1123 def __init__(self, this):
1124 self.this = this
1125 if not hasattr(self,"thisown"): self.thisown = 0
1126 self.__class__ = Timer
1127 _misc_.Timer_swigregister(TimerPtr)
1128
1129 # For backwards compatibility with 2.4
1130 class PyTimer(Timer):
1131 def __init__(self, notify):
1132 Timer.__init__(self)
1133 self.notify = notify
1134
1135 def Notify(self):
1136 if self.notify:
1137 self.notify()
1138
1139
1140 EVT_TIMER = wx.PyEventBinder( wxEVT_TIMER, 1 )
1141
1142
1143 class TimerEvent(_core.Event):
1144 """Proxy of C++ TimerEvent class"""
1145 def __repr__(self):
1146 return "<%s.%s; proxy of C++ wxTimerEvent instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
1147 def __init__(self, *args, **kwargs):
1148 """__init__(self, int timerid=0, int interval=0) -> TimerEvent"""
1149 newobj = _misc_.new_TimerEvent(*args, **kwargs)
1150 self.this = newobj.this
1151 self.thisown = 1
1152 del newobj.thisown
1153 def GetInterval(*args, **kwargs):
1154 """GetInterval(self) -> int"""
1155 return _misc_.TimerEvent_GetInterval(*args, **kwargs)
1156
1157
1158 class TimerEventPtr(TimerEvent):
1159 def __init__(self, this):
1160 self.this = this
1161 if not hasattr(self,"thisown"): self.thisown = 0
1162 self.__class__ = TimerEvent
1163 _misc_.TimerEvent_swigregister(TimerEventPtr)
1164
1165 class TimerRunner(object):
1166 """Proxy of C++ TimerRunner class"""
1167 def __repr__(self):
1168 return "<%s.%s; proxy of C++ wxTimerRunner instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
1169 def __init__(self, *args):
1170 """
1171 __init__(self, wxTimer timer) -> TimerRunner
1172 __init__(self, wxTimer timer, int milli, bool oneShot=False) -> TimerRunner
1173 """
1174 newobj = _misc_.new_TimerRunner(*args)
1175 self.this = newobj.this
1176 self.thisown = 1
1177 del newobj.thisown
1178 def __del__(self, destroy=_misc_.delete_TimerRunner):
1179 """__del__(self)"""
1180 try:
1181 if self.thisown: destroy(self)
1182 except: pass
1183
1184 def Start(*args, **kwargs):
1185 """Start(self, int milli, bool oneShot=False)"""
1186 return _misc_.TimerRunner_Start(*args, **kwargs)
1187
1188
1189 class TimerRunnerPtr(TimerRunner):
1190 def __init__(self, this):
1191 self.this = this
1192 if not hasattr(self,"thisown"): self.thisown = 0
1193 self.__class__ = TimerRunner
1194 _misc_.TimerRunner_swigregister(TimerRunnerPtr)
1195
1196 #---------------------------------------------------------------------------
1197
1198 LOG_FatalError = _misc_.LOG_FatalError
1199 LOG_Error = _misc_.LOG_Error
1200 LOG_Warning = _misc_.LOG_Warning
1201 LOG_Message = _misc_.LOG_Message
1202 LOG_Status = _misc_.LOG_Status
1203 LOG_Info = _misc_.LOG_Info
1204 LOG_Debug = _misc_.LOG_Debug
1205 LOG_Trace = _misc_.LOG_Trace
1206 LOG_Progress = _misc_.LOG_Progress
1207 LOG_User = _misc_.LOG_User
1208 LOG_Max = _misc_.LOG_Max
1209 TRACE_MemAlloc = _misc_.TRACE_MemAlloc
1210 TRACE_Messages = _misc_.TRACE_Messages
1211 TRACE_ResAlloc = _misc_.TRACE_ResAlloc
1212 TRACE_RefCount = _misc_.TRACE_RefCount
1213 TRACE_OleCalls = _misc_.TRACE_OleCalls
1214 TraceMemAlloc = _misc_.TraceMemAlloc
1215 TraceMessages = _misc_.TraceMessages
1216 TraceResAlloc = _misc_.TraceResAlloc
1217 TraceRefCount = _misc_.TraceRefCount
1218 TraceOleCalls = _misc_.TraceOleCalls
1219 class Log(object):
1220 """Proxy of C++ Log class"""
1221 def __repr__(self):
1222 return "<%s.%s; proxy of C++ wxLog instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
1223 def __init__(self, *args, **kwargs):
1224 """__init__(self) -> Log"""
1225 newobj = _misc_.new_Log(*args, **kwargs)
1226 self.this = newobj.this
1227 self.thisown = 1
1228 del newobj.thisown
1229 def IsEnabled(*args, **kwargs):
1230 """IsEnabled() -> bool"""
1231 return _misc_.Log_IsEnabled(*args, **kwargs)
1232
1233 IsEnabled = staticmethod(IsEnabled)
1234 def EnableLogging(*args, **kwargs):
1235 """EnableLogging(bool doIt=True) -> bool"""
1236 return _misc_.Log_EnableLogging(*args, **kwargs)
1237
1238 EnableLogging = staticmethod(EnableLogging)
1239 def OnLog(*args, **kwargs):
1240 """OnLog(wxLogLevel level, wxChar szString, time_t t)"""
1241 return _misc_.Log_OnLog(*args, **kwargs)
1242
1243 OnLog = staticmethod(OnLog)
1244 def Flush(*args, **kwargs):
1245 """Flush(self)"""
1246 return _misc_.Log_Flush(*args, **kwargs)
1247
1248 def FlushActive(*args, **kwargs):
1249 """FlushActive()"""
1250 return _misc_.Log_FlushActive(*args, **kwargs)
1251
1252 FlushActive = staticmethod(FlushActive)
1253 def GetActiveTarget(*args, **kwargs):
1254 """GetActiveTarget() -> Log"""
1255 return _misc_.Log_GetActiveTarget(*args, **kwargs)
1256
1257 GetActiveTarget = staticmethod(GetActiveTarget)
1258 def SetActiveTarget(*args, **kwargs):
1259 """SetActiveTarget(Log pLogger) -> Log"""
1260 return _misc_.Log_SetActiveTarget(*args, **kwargs)
1261
1262 SetActiveTarget = staticmethod(SetActiveTarget)
1263 def Suspend(*args, **kwargs):
1264 """Suspend()"""
1265 return _misc_.Log_Suspend(*args, **kwargs)
1266
1267 Suspend = staticmethod(Suspend)
1268 def Resume(*args, **kwargs):
1269 """Resume()"""
1270 return _misc_.Log_Resume(*args, **kwargs)
1271
1272 Resume = staticmethod(Resume)
1273 def SetVerbose(*args, **kwargs):
1274 """SetVerbose(bool bVerbose=True)"""
1275 return _misc_.Log_SetVerbose(*args, **kwargs)
1276
1277 SetVerbose = staticmethod(SetVerbose)
1278 def SetLogLevel(*args, **kwargs):
1279 """SetLogLevel(wxLogLevel logLevel)"""
1280 return _misc_.Log_SetLogLevel(*args, **kwargs)
1281
1282 SetLogLevel = staticmethod(SetLogLevel)
1283 def DontCreateOnDemand(*args, **kwargs):
1284 """DontCreateOnDemand()"""
1285 return _misc_.Log_DontCreateOnDemand(*args, **kwargs)
1286
1287 DontCreateOnDemand = staticmethod(DontCreateOnDemand)
1288 def SetTraceMask(*args, **kwargs):
1289 """SetTraceMask(wxTraceMask ulMask)"""
1290 return _misc_.Log_SetTraceMask(*args, **kwargs)
1291
1292 SetTraceMask = staticmethod(SetTraceMask)
1293 def AddTraceMask(*args, **kwargs):
1294 """AddTraceMask(String str)"""
1295 return _misc_.Log_AddTraceMask(*args, **kwargs)
1296
1297 AddTraceMask = staticmethod(AddTraceMask)
1298 def RemoveTraceMask(*args, **kwargs):
1299 """RemoveTraceMask(String str)"""
1300 return _misc_.Log_RemoveTraceMask(*args, **kwargs)
1301
1302 RemoveTraceMask = staticmethod(RemoveTraceMask)
1303 def ClearTraceMasks(*args, **kwargs):
1304 """ClearTraceMasks()"""
1305 return _misc_.Log_ClearTraceMasks(*args, **kwargs)
1306
1307 ClearTraceMasks = staticmethod(ClearTraceMasks)
1308 def GetTraceMasks(*args, **kwargs):
1309 """GetTraceMasks() -> wxArrayString"""
1310 return _misc_.Log_GetTraceMasks(*args, **kwargs)
1311
1312 GetTraceMasks = staticmethod(GetTraceMasks)
1313 def SetTimestamp(*args, **kwargs):
1314 """SetTimestamp(wxChar ts)"""
1315 return _misc_.Log_SetTimestamp(*args, **kwargs)
1316
1317 SetTimestamp = staticmethod(SetTimestamp)
1318 def GetVerbose(*args, **kwargs):
1319 """GetVerbose() -> bool"""
1320 return _misc_.Log_GetVerbose(*args, **kwargs)
1321
1322 GetVerbose = staticmethod(GetVerbose)
1323 def GetTraceMask(*args, **kwargs):
1324 """GetTraceMask() -> wxTraceMask"""
1325 return _misc_.Log_GetTraceMask(*args, **kwargs)
1326
1327 GetTraceMask = staticmethod(GetTraceMask)
1328 def IsAllowedTraceMask(*args, **kwargs):
1329 """IsAllowedTraceMask(wxChar mask) -> bool"""
1330 return _misc_.Log_IsAllowedTraceMask(*args, **kwargs)
1331
1332 IsAllowedTraceMask = staticmethod(IsAllowedTraceMask)
1333 def GetLogLevel(*args, **kwargs):
1334 """GetLogLevel() -> wxLogLevel"""
1335 return _misc_.Log_GetLogLevel(*args, **kwargs)
1336
1337 GetLogLevel = staticmethod(GetLogLevel)
1338 def GetTimestamp(*args, **kwargs):
1339 """GetTimestamp() -> wxChar"""
1340 return _misc_.Log_GetTimestamp(*args, **kwargs)
1341
1342 GetTimestamp = staticmethod(GetTimestamp)
1343 def TimeStamp(*args, **kwargs):
1344 """TimeStamp() -> String"""
1345 return _misc_.Log_TimeStamp(*args, **kwargs)
1346
1347 TimeStamp = staticmethod(TimeStamp)
1348 def Destroy(*args, **kwargs):
1349 """Destroy(self)"""
1350 return _misc_.Log_Destroy(*args, **kwargs)
1351
1352
1353 class LogPtr(Log):
1354 def __init__(self, this):
1355 self.this = this
1356 if not hasattr(self,"thisown"): self.thisown = 0
1357 self.__class__ = Log
1358 _misc_.Log_swigregister(LogPtr)
1359
1360 def Log_IsEnabled(*args, **kwargs):
1361 """Log_IsEnabled() -> bool"""
1362 return _misc_.Log_IsEnabled(*args, **kwargs)
1363
1364 def Log_EnableLogging(*args, **kwargs):
1365 """Log_EnableLogging(bool doIt=True) -> bool"""
1366 return _misc_.Log_EnableLogging(*args, **kwargs)
1367
1368 def Log_OnLog(*args, **kwargs):
1369 """Log_OnLog(wxLogLevel level, wxChar szString, time_t t)"""
1370 return _misc_.Log_OnLog(*args, **kwargs)
1371
1372 def Log_FlushActive(*args, **kwargs):
1373 """Log_FlushActive()"""
1374 return _misc_.Log_FlushActive(*args, **kwargs)
1375
1376 def Log_GetActiveTarget(*args, **kwargs):
1377 """Log_GetActiveTarget() -> Log"""
1378 return _misc_.Log_GetActiveTarget(*args, **kwargs)
1379
1380 def Log_SetActiveTarget(*args, **kwargs):
1381 """Log_SetActiveTarget(Log pLogger) -> Log"""
1382 return _misc_.Log_SetActiveTarget(*args, **kwargs)
1383
1384 def Log_Suspend(*args, **kwargs):
1385 """Log_Suspend()"""
1386 return _misc_.Log_Suspend(*args, **kwargs)
1387
1388 def Log_Resume(*args, **kwargs):
1389 """Log_Resume()"""
1390 return _misc_.Log_Resume(*args, **kwargs)
1391
1392 def Log_SetVerbose(*args, **kwargs):
1393 """Log_SetVerbose(bool bVerbose=True)"""
1394 return _misc_.Log_SetVerbose(*args, **kwargs)
1395
1396 def Log_SetLogLevel(*args, **kwargs):
1397 """Log_SetLogLevel(wxLogLevel logLevel)"""
1398 return _misc_.Log_SetLogLevel(*args, **kwargs)
1399
1400 def Log_DontCreateOnDemand(*args, **kwargs):
1401 """Log_DontCreateOnDemand()"""
1402 return _misc_.Log_DontCreateOnDemand(*args, **kwargs)
1403
1404 def Log_SetTraceMask(*args, **kwargs):
1405 """Log_SetTraceMask(wxTraceMask ulMask)"""
1406 return _misc_.Log_SetTraceMask(*args, **kwargs)
1407
1408 def Log_AddTraceMask(*args, **kwargs):
1409 """Log_AddTraceMask(String str)"""
1410 return _misc_.Log_AddTraceMask(*args, **kwargs)
1411
1412 def Log_RemoveTraceMask(*args, **kwargs):
1413 """Log_RemoveTraceMask(String str)"""
1414 return _misc_.Log_RemoveTraceMask(*args, **kwargs)
1415
1416 def Log_ClearTraceMasks(*args, **kwargs):
1417 """Log_ClearTraceMasks()"""
1418 return _misc_.Log_ClearTraceMasks(*args, **kwargs)
1419
1420 def Log_GetTraceMasks(*args, **kwargs):
1421 """Log_GetTraceMasks() -> wxArrayString"""
1422 return _misc_.Log_GetTraceMasks(*args, **kwargs)
1423
1424 def Log_SetTimestamp(*args, **kwargs):
1425 """Log_SetTimestamp(wxChar ts)"""
1426 return _misc_.Log_SetTimestamp(*args, **kwargs)
1427
1428 def Log_GetVerbose(*args, **kwargs):
1429 """Log_GetVerbose() -> bool"""
1430 return _misc_.Log_GetVerbose(*args, **kwargs)
1431
1432 def Log_GetTraceMask(*args, **kwargs):
1433 """Log_GetTraceMask() -> wxTraceMask"""
1434 return _misc_.Log_GetTraceMask(*args, **kwargs)
1435
1436 def Log_IsAllowedTraceMask(*args, **kwargs):
1437 """Log_IsAllowedTraceMask(wxChar mask) -> bool"""
1438 return _misc_.Log_IsAllowedTraceMask(*args, **kwargs)
1439
1440 def Log_GetLogLevel(*args, **kwargs):
1441 """Log_GetLogLevel() -> wxLogLevel"""
1442 return _misc_.Log_GetLogLevel(*args, **kwargs)
1443
1444 def Log_GetTimestamp(*args, **kwargs):
1445 """Log_GetTimestamp() -> wxChar"""
1446 return _misc_.Log_GetTimestamp(*args, **kwargs)
1447
1448 def Log_TimeStamp(*args, **kwargs):
1449 """Log_TimeStamp() -> String"""
1450 return _misc_.Log_TimeStamp(*args, **kwargs)
1451
1452 class LogStderr(Log):
1453 """Proxy of C++ LogStderr class"""
1454 def __repr__(self):
1455 return "<%s.%s; proxy of C++ wxLogStderr instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
1456 def __init__(self, *args, **kwargs):
1457 """__init__(self) -> LogStderr"""
1458 newobj = _misc_.new_LogStderr(*args, **kwargs)
1459 self.this = newobj.this
1460 self.thisown = 1
1461 del newobj.thisown
1462
1463 class LogStderrPtr(LogStderr):
1464 def __init__(self, this):
1465 self.this = this
1466 if not hasattr(self,"thisown"): self.thisown = 0
1467 self.__class__ = LogStderr
1468 _misc_.LogStderr_swigregister(LogStderrPtr)
1469
1470 class LogTextCtrl(Log):
1471 """Proxy of C++ LogTextCtrl class"""
1472 def __repr__(self):
1473 return "<%s.%s; proxy of C++ wxLogTextCtrl instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
1474 def __init__(self, *args, **kwargs):
1475 """__init__(self, wxTextCtrl pTextCtrl) -> LogTextCtrl"""
1476 newobj = _misc_.new_LogTextCtrl(*args, **kwargs)
1477 self.this = newobj.this
1478 self.thisown = 1
1479 del newobj.thisown
1480
1481 class LogTextCtrlPtr(LogTextCtrl):
1482 def __init__(self, this):
1483 self.this = this
1484 if not hasattr(self,"thisown"): self.thisown = 0
1485 self.__class__ = LogTextCtrl
1486 _misc_.LogTextCtrl_swigregister(LogTextCtrlPtr)
1487
1488 class LogGui(Log):
1489 """Proxy of C++ LogGui class"""
1490 def __repr__(self):
1491 return "<%s.%s; proxy of C++ wxLogGui instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
1492 def __init__(self, *args, **kwargs):
1493 """__init__(self) -> LogGui"""
1494 newobj = _misc_.new_LogGui(*args, **kwargs)
1495 self.this = newobj.this
1496 self.thisown = 1
1497 del newobj.thisown
1498
1499 class LogGuiPtr(LogGui):
1500 def __init__(self, this):
1501 self.this = this
1502 if not hasattr(self,"thisown"): self.thisown = 0
1503 self.__class__ = LogGui
1504 _misc_.LogGui_swigregister(LogGuiPtr)
1505
1506 class LogWindow(Log):
1507 """Proxy of C++ LogWindow class"""
1508 def __repr__(self):
1509 return "<%s.%s; proxy of C++ wxLogWindow instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
1510 def __init__(self, *args, **kwargs):
1511 """__init__(self, wxFrame pParent, String szTitle, bool bShow=True, bool bPassToOld=True) -> LogWindow"""
1512 newobj = _misc_.new_LogWindow(*args, **kwargs)
1513 self.this = newobj.this
1514 self.thisown = 1
1515 del newobj.thisown
1516 def Show(*args, **kwargs):
1517 """Show(self, bool bShow=True)"""
1518 return _misc_.LogWindow_Show(*args, **kwargs)
1519
1520 def GetFrame(*args, **kwargs):
1521 """GetFrame(self) -> wxFrame"""
1522 return _misc_.LogWindow_GetFrame(*args, **kwargs)
1523
1524 def GetOldLog(*args, **kwargs):
1525 """GetOldLog(self) -> Log"""
1526 return _misc_.LogWindow_GetOldLog(*args, **kwargs)
1527
1528 def IsPassingMessages(*args, **kwargs):
1529 """IsPassingMessages(self) -> bool"""
1530 return _misc_.LogWindow_IsPassingMessages(*args, **kwargs)
1531
1532 def PassMessages(*args, **kwargs):
1533 """PassMessages(self, bool bDoPass)"""
1534 return _misc_.LogWindow_PassMessages(*args, **kwargs)
1535
1536
1537 class LogWindowPtr(LogWindow):
1538 def __init__(self, this):
1539 self.this = this
1540 if not hasattr(self,"thisown"): self.thisown = 0
1541 self.__class__ = LogWindow
1542 _misc_.LogWindow_swigregister(LogWindowPtr)
1543
1544 class LogChain(Log):
1545 """Proxy of C++ LogChain class"""
1546 def __repr__(self):
1547 return "<%s.%s; proxy of C++ wxLogChain instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
1548 def __init__(self, *args, **kwargs):
1549 """__init__(self, Log logger) -> LogChain"""
1550 newobj = _misc_.new_LogChain(*args, **kwargs)
1551 self.this = newobj.this
1552 self.thisown = 1
1553 del newobj.thisown
1554 def SetLog(*args, **kwargs):
1555 """SetLog(self, Log logger)"""
1556 return _misc_.LogChain_SetLog(*args, **kwargs)
1557
1558 def PassMessages(*args, **kwargs):
1559 """PassMessages(self, bool bDoPass)"""
1560 return _misc_.LogChain_PassMessages(*args, **kwargs)
1561
1562 def IsPassingMessages(*args, **kwargs):
1563 """IsPassingMessages(self) -> bool"""
1564 return _misc_.LogChain_IsPassingMessages(*args, **kwargs)
1565
1566 def GetOldLog(*args, **kwargs):
1567 """GetOldLog(self) -> Log"""
1568 return _misc_.LogChain_GetOldLog(*args, **kwargs)
1569
1570
1571 class LogChainPtr(LogChain):
1572 def __init__(self, this):
1573 self.this = this
1574 if not hasattr(self,"thisown"): self.thisown = 0
1575 self.__class__ = LogChain
1576 _misc_.LogChain_swigregister(LogChainPtr)
1577
1578 class LogBuffer(Log):
1579 """Proxy of C++ LogBuffer class"""
1580 def __repr__(self):
1581 return "<%s.%s; proxy of C++ wxLogBuffer instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
1582 def __init__(self, *args, **kwargs):
1583 """__init__(self) -> LogBuffer"""
1584 newobj = _misc_.new_LogBuffer(*args, **kwargs)
1585 self.this = newobj.this
1586 self.thisown = 1
1587 del newobj.thisown
1588 def GetBuffer(*args, **kwargs):
1589 """GetBuffer(self) -> String"""
1590 return _misc_.LogBuffer_GetBuffer(*args, **kwargs)
1591
1592 def Flush(*args, **kwargs):
1593 """Flush(self)"""
1594 return _misc_.LogBuffer_Flush(*args, **kwargs)
1595
1596
1597 class LogBufferPtr(LogBuffer):
1598 def __init__(self, this):
1599 self.this = this
1600 if not hasattr(self,"thisown"): self.thisown = 0
1601 self.__class__ = LogBuffer
1602 _misc_.LogBuffer_swigregister(LogBufferPtr)
1603
1604
1605 def SysErrorCode(*args, **kwargs):
1606 """SysErrorCode() -> unsigned long"""
1607 return _misc_.SysErrorCode(*args, **kwargs)
1608
1609 def SysErrorMsg(*args, **kwargs):
1610 """SysErrorMsg(unsigned long nErrCode=0) -> String"""
1611 return _misc_.SysErrorMsg(*args, **kwargs)
1612
1613 def LogFatalError(*args, **kwargs):
1614 """LogFatalError(String msg)"""
1615 return _misc_.LogFatalError(*args, **kwargs)
1616
1617 def LogError(*args, **kwargs):
1618 """LogError(String msg)"""
1619 return _misc_.LogError(*args, **kwargs)
1620
1621 def LogWarning(*args, **kwargs):
1622 """LogWarning(String msg)"""
1623 return _misc_.LogWarning(*args, **kwargs)
1624
1625 def LogMessage(*args, **kwargs):
1626 """LogMessage(String msg)"""
1627 return _misc_.LogMessage(*args, **kwargs)
1628
1629 def LogInfo(*args, **kwargs):
1630 """LogInfo(String msg)"""
1631 return _misc_.LogInfo(*args, **kwargs)
1632
1633 def LogDebug(*args, **kwargs):
1634 """LogDebug(String msg)"""
1635 return _misc_.LogDebug(*args, **kwargs)
1636
1637 def LogVerbose(*args, **kwargs):
1638 """LogVerbose(String msg)"""
1639 return _misc_.LogVerbose(*args, **kwargs)
1640
1641 def LogStatus(*args, **kwargs):
1642 """LogStatus(String msg)"""
1643 return _misc_.LogStatus(*args, **kwargs)
1644
1645 def LogStatusFrame(*args, **kwargs):
1646 """LogStatusFrame(wxFrame pFrame, String msg)"""
1647 return _misc_.LogStatusFrame(*args, **kwargs)
1648
1649 def LogSysError(*args, **kwargs):
1650 """LogSysError(String msg)"""
1651 return _misc_.LogSysError(*args, **kwargs)
1652
1653 def LogGeneric(*args, **kwargs):
1654 """LogGeneric(unsigned long level, String msg)"""
1655 return _misc_.LogGeneric(*args, **kwargs)
1656
1657 def SafeShowMessage(*args, **kwargs):
1658 """SafeShowMessage(String title, String text)"""
1659 return _misc_.SafeShowMessage(*args, **kwargs)
1660 class LogNull(object):
1661 """Proxy of C++ LogNull class"""
1662 def __repr__(self):
1663 return "<%s.%s; proxy of C++ wxLogNull instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
1664 def __init__(self, *args, **kwargs):
1665 """__init__(self) -> LogNull"""
1666 newobj = _misc_.new_LogNull(*args, **kwargs)
1667 self.this = newobj.this
1668 self.thisown = 1
1669 del newobj.thisown
1670 def __del__(self, destroy=_misc_.delete_LogNull):
1671 """__del__(self)"""
1672 try:
1673 if self.thisown: destroy(self)
1674 except: pass
1675
1676
1677 class LogNullPtr(LogNull):
1678 def __init__(self, this):
1679 self.this = this
1680 if not hasattr(self,"thisown"): self.thisown = 0
1681 self.__class__ = LogNull
1682 _misc_.LogNull_swigregister(LogNullPtr)
1683
1684 def LogTrace(*args):
1685 """
1686 LogTrace(unsigned long mask, String msg)
1687 LogTrace(String mask, String msg)
1688 """
1689 return _misc_.LogTrace(*args)
1690
1691 class PyLog(Log):
1692 """Proxy of C++ PyLog class"""
1693 def __repr__(self):
1694 return "<%s.%s; proxy of C++ wxPyLog instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
1695 def __init__(self, *args, **kwargs):
1696 """__init__(self) -> PyLog"""
1697 newobj = _misc_.new_PyLog(*args, **kwargs)
1698 self.this = newobj.this
1699 self.thisown = 1
1700 del newobj.thisown
1701 self._setCallbackInfo(self, PyLog)
1702
1703 def _setCallbackInfo(*args, **kwargs):
1704 """_setCallbackInfo(self, PyObject self, PyObject _class)"""
1705 return _misc_.PyLog__setCallbackInfo(*args, **kwargs)
1706
1707
1708 class PyLogPtr(PyLog):
1709 def __init__(self, this):
1710 self.this = this
1711 if not hasattr(self,"thisown"): self.thisown = 0
1712 self.__class__ = PyLog
1713 _misc_.PyLog_swigregister(PyLogPtr)
1714
1715 #---------------------------------------------------------------------------
1716
1717 PROCESS_DEFAULT = _misc_.PROCESS_DEFAULT
1718 PROCESS_REDIRECT = _misc_.PROCESS_REDIRECT
1719 KILL_OK = _misc_.KILL_OK
1720 KILL_BAD_SIGNAL = _misc_.KILL_BAD_SIGNAL
1721 KILL_ACCESS_DENIED = _misc_.KILL_ACCESS_DENIED
1722 KILL_NO_PROCESS = _misc_.KILL_NO_PROCESS
1723 KILL_ERROR = _misc_.KILL_ERROR
1724 KILL_NOCHILDREN = _misc_.KILL_NOCHILDREN
1725 KILL_CHILDREN = _misc_.KILL_CHILDREN
1726 SIGNONE = _misc_.SIGNONE
1727 SIGHUP = _misc_.SIGHUP
1728 SIGINT = _misc_.SIGINT
1729 SIGQUIT = _misc_.SIGQUIT
1730 SIGILL = _misc_.SIGILL
1731 SIGTRAP = _misc_.SIGTRAP
1732 SIGABRT = _misc_.SIGABRT
1733 SIGIOT = _misc_.SIGIOT
1734 SIGEMT = _misc_.SIGEMT
1735 SIGFPE = _misc_.SIGFPE
1736 SIGKILL = _misc_.SIGKILL
1737 SIGBUS = _misc_.SIGBUS
1738 SIGSEGV = _misc_.SIGSEGV
1739 SIGSYS = _misc_.SIGSYS
1740 SIGPIPE = _misc_.SIGPIPE
1741 SIGALRM = _misc_.SIGALRM
1742 SIGTERM = _misc_.SIGTERM
1743 class Process(_core.EvtHandler):
1744 """Proxy of C++ Process class"""
1745 def __repr__(self):
1746 return "<%s.%s; proxy of C++ wxPyProcess instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
1747 def Kill(*args, **kwargs):
1748 """Kill(int pid, int sig=SIGTERM, int flags=KILL_NOCHILDREN) -> int"""
1749 return _misc_.Process_Kill(*args, **kwargs)
1750
1751 Kill = staticmethod(Kill)
1752 def Exists(*args, **kwargs):
1753 """Exists(int pid) -> bool"""
1754 return _misc_.Process_Exists(*args, **kwargs)
1755
1756 Exists = staticmethod(Exists)
1757 def Open(*args, **kwargs):
1758 """Open(String cmd, int flags=EXEC_ASYNC) -> Process"""
1759 return _misc_.Process_Open(*args, **kwargs)
1760
1761 Open = staticmethod(Open)
1762 def __init__(self, *args, **kwargs):
1763 """__init__(self, EvtHandler parent=None, int id=-1) -> Process"""
1764 newobj = _misc_.new_Process(*args, **kwargs)
1765 self.this = newobj.this
1766 self.thisown = 1
1767 del newobj.thisown
1768 self._setCallbackInfo(self, Process)
1769
1770 def _setCallbackInfo(*args, **kwargs):
1771 """_setCallbackInfo(self, PyObject self, PyObject _class)"""
1772 return _misc_.Process__setCallbackInfo(*args, **kwargs)
1773
1774 def base_OnTerminate(*args, **kwargs):
1775 """base_OnTerminate(self, int pid, int status)"""
1776 return _misc_.Process_base_OnTerminate(*args, **kwargs)
1777
1778 def Redirect(*args, **kwargs):
1779 """Redirect(self)"""
1780 return _misc_.Process_Redirect(*args, **kwargs)
1781
1782 def IsRedirected(*args, **kwargs):
1783 """IsRedirected(self) -> bool"""
1784 return _misc_.Process_IsRedirected(*args, **kwargs)
1785
1786 def Detach(*args, **kwargs):
1787 """Detach(self)"""
1788 return _misc_.Process_Detach(*args, **kwargs)
1789
1790 def GetInputStream(*args, **kwargs):
1791 """GetInputStream(self) -> InputStream"""
1792 return _misc_.Process_GetInputStream(*args, **kwargs)
1793
1794 def GetErrorStream(*args, **kwargs):
1795 """GetErrorStream(self) -> InputStream"""
1796 return _misc_.Process_GetErrorStream(*args, **kwargs)
1797
1798 def GetOutputStream(*args, **kwargs):
1799 """GetOutputStream(self) -> OutputStream"""
1800 return _misc_.Process_GetOutputStream(*args, **kwargs)
1801
1802 def CloseOutput(*args, **kwargs):
1803 """CloseOutput(self)"""
1804 return _misc_.Process_CloseOutput(*args, **kwargs)
1805
1806 def IsInputOpened(*args, **kwargs):
1807 """IsInputOpened(self) -> bool"""
1808 return _misc_.Process_IsInputOpened(*args, **kwargs)
1809
1810 def IsInputAvailable(*args, **kwargs):
1811 """IsInputAvailable(self) -> bool"""
1812 return _misc_.Process_IsInputAvailable(*args, **kwargs)
1813
1814 def IsErrorAvailable(*args, **kwargs):
1815 """IsErrorAvailable(self) -> bool"""
1816 return _misc_.Process_IsErrorAvailable(*args, **kwargs)
1817
1818
1819 class ProcessPtr(Process):
1820 def __init__(self, this):
1821 self.this = this
1822 if not hasattr(self,"thisown"): self.thisown = 0
1823 self.__class__ = Process
1824 _misc_.Process_swigregister(ProcessPtr)
1825
1826 def Process_Kill(*args, **kwargs):
1827 """Process_Kill(int pid, int sig=SIGTERM, int flags=KILL_NOCHILDREN) -> int"""
1828 return _misc_.Process_Kill(*args, **kwargs)
1829
1830 def Process_Exists(*args, **kwargs):
1831 """Process_Exists(int pid) -> bool"""
1832 return _misc_.Process_Exists(*args, **kwargs)
1833
1834 def Process_Open(*args, **kwargs):
1835 """Process_Open(String cmd, int flags=EXEC_ASYNC) -> Process"""
1836 return _misc_.Process_Open(*args, **kwargs)
1837
1838 class ProcessEvent(_core.Event):
1839 """Proxy of C++ ProcessEvent class"""
1840 def __repr__(self):
1841 return "<%s.%s; proxy of C++ wxProcessEvent instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
1842 def __init__(self, *args, **kwargs):
1843 """__init__(self, int id=0, int pid=0, int exitcode=0) -> ProcessEvent"""
1844 newobj = _misc_.new_ProcessEvent(*args, **kwargs)
1845 self.this = newobj.this
1846 self.thisown = 1
1847 del newobj.thisown
1848 def GetPid(*args, **kwargs):
1849 """GetPid(self) -> int"""
1850 return _misc_.ProcessEvent_GetPid(*args, **kwargs)
1851
1852 def GetExitCode(*args, **kwargs):
1853 """GetExitCode(self) -> int"""
1854 return _misc_.ProcessEvent_GetExitCode(*args, **kwargs)
1855
1856 m_pid = property(_misc_.ProcessEvent_m_pid_get, _misc_.ProcessEvent_m_pid_set)
1857 m_exitcode = property(_misc_.ProcessEvent_m_exitcode_get, _misc_.ProcessEvent_m_exitcode_set)
1858
1859 class ProcessEventPtr(ProcessEvent):
1860 def __init__(self, this):
1861 self.this = this
1862 if not hasattr(self,"thisown"): self.thisown = 0
1863 self.__class__ = ProcessEvent
1864 _misc_.ProcessEvent_swigregister(ProcessEventPtr)
1865
1866 wxEVT_END_PROCESS = _misc_.wxEVT_END_PROCESS
1867 EVT_END_PROCESS = wx.PyEventBinder( wxEVT_END_PROCESS, 1 )
1868
1869 EXEC_ASYNC = _misc_.EXEC_ASYNC
1870 EXEC_SYNC = _misc_.EXEC_SYNC
1871 EXEC_NOHIDE = _misc_.EXEC_NOHIDE
1872 EXEC_MAKE_GROUP_LEADER = _misc_.EXEC_MAKE_GROUP_LEADER
1873 EXEC_NODISABLE = _misc_.EXEC_NODISABLE
1874
1875 def Execute(*args, **kwargs):
1876 """Execute(String command, int flags=EXEC_ASYNC, Process process=None) -> long"""
1877 return _misc_.Execute(*args, **kwargs)
1878
1879 def Kill(*args, **kwargs):
1880 """Kill(long pid, int sig=SIGTERM, int rc, int flags=KILL_NOCHILDREN) -> int"""
1881 return _misc_.Kill(*args, **kwargs)
1882 #---------------------------------------------------------------------------
1883
1884 JOYSTICK1 = _misc_.JOYSTICK1
1885 JOYSTICK2 = _misc_.JOYSTICK2
1886 JOY_BUTTON_ANY = _misc_.JOY_BUTTON_ANY
1887 JOY_BUTTON1 = _misc_.JOY_BUTTON1
1888 JOY_BUTTON2 = _misc_.JOY_BUTTON2
1889 JOY_BUTTON3 = _misc_.JOY_BUTTON3
1890 JOY_BUTTON4 = _misc_.JOY_BUTTON4
1891 class Joystick(object):
1892 """Proxy of C++ Joystick class"""
1893 def __repr__(self):
1894 return "<%s.%s; proxy of C++ wxJoystick instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
1895 def __init__(self, *args, **kwargs):
1896 """__init__(self, int joystick=JOYSTICK1) -> Joystick"""
1897 newobj = _misc_.new_Joystick(*args, **kwargs)
1898 self.this = newobj.this
1899 self.thisown = 1
1900 del newobj.thisown
1901 def __del__(self, destroy=_misc_.delete_Joystick):
1902 """__del__(self)"""
1903 try:
1904 if self.thisown: destroy(self)
1905 except: pass
1906
1907 def GetPosition(*args, **kwargs):
1908 """GetPosition(self) -> Point"""
1909 return _misc_.Joystick_GetPosition(*args, **kwargs)
1910
1911 def GetZPosition(*args, **kwargs):
1912 """GetZPosition(self) -> int"""
1913 return _misc_.Joystick_GetZPosition(*args, **kwargs)
1914
1915 def GetButtonState(*args, **kwargs):
1916 """GetButtonState(self) -> int"""
1917 return _misc_.Joystick_GetButtonState(*args, **kwargs)
1918
1919 def GetPOVPosition(*args, **kwargs):
1920 """GetPOVPosition(self) -> int"""
1921 return _misc_.Joystick_GetPOVPosition(*args, **kwargs)
1922
1923 def GetPOVCTSPosition(*args, **kwargs):
1924 """GetPOVCTSPosition(self) -> int"""
1925 return _misc_.Joystick_GetPOVCTSPosition(*args, **kwargs)
1926
1927 def GetRudderPosition(*args, **kwargs):
1928 """GetRudderPosition(self) -> int"""
1929 return _misc_.Joystick_GetRudderPosition(*args, **kwargs)
1930
1931 def GetUPosition(*args, **kwargs):
1932 """GetUPosition(self) -> int"""
1933 return _misc_.Joystick_GetUPosition(*args, **kwargs)
1934
1935 def GetVPosition(*args, **kwargs):
1936 """GetVPosition(self) -> int"""
1937 return _misc_.Joystick_GetVPosition(*args, **kwargs)
1938
1939 def GetMovementThreshold(*args, **kwargs):
1940 """GetMovementThreshold(self) -> int"""
1941 return _misc_.Joystick_GetMovementThreshold(*args, **kwargs)
1942
1943 def SetMovementThreshold(*args, **kwargs):
1944 """SetMovementThreshold(self, int threshold)"""
1945 return _misc_.Joystick_SetMovementThreshold(*args, **kwargs)
1946
1947 def IsOk(*args, **kwargs):
1948 """IsOk(self) -> bool"""
1949 return _misc_.Joystick_IsOk(*args, **kwargs)
1950
1951 def GetNumberJoysticks(*args, **kwargs):
1952 """GetNumberJoysticks(self) -> int"""
1953 return _misc_.Joystick_GetNumberJoysticks(*args, **kwargs)
1954
1955 def GetManufacturerId(*args, **kwargs):
1956 """GetManufacturerId(self) -> int"""
1957 return _misc_.Joystick_GetManufacturerId(*args, **kwargs)
1958
1959 def GetProductId(*args, **kwargs):
1960 """GetProductId(self) -> int"""
1961 return _misc_.Joystick_GetProductId(*args, **kwargs)
1962
1963 def GetProductName(*args, **kwargs):
1964 """GetProductName(self) -> String"""
1965 return _misc_.Joystick_GetProductName(*args, **kwargs)
1966
1967 def GetXMin(*args, **kwargs):
1968 """GetXMin(self) -> int"""
1969 return _misc_.Joystick_GetXMin(*args, **kwargs)
1970
1971 def GetYMin(*args, **kwargs):
1972 """GetYMin(self) -> int"""
1973 return _misc_.Joystick_GetYMin(*args, **kwargs)
1974
1975 def GetZMin(*args, **kwargs):
1976 """GetZMin(self) -> int"""
1977 return _misc_.Joystick_GetZMin(*args, **kwargs)
1978
1979 def GetXMax(*args, **kwargs):
1980 """GetXMax(self) -> int"""
1981 return _misc_.Joystick_GetXMax(*args, **kwargs)
1982
1983 def GetYMax(*args, **kwargs):
1984 """GetYMax(self) -> int"""
1985 return _misc_.Joystick_GetYMax(*args, **kwargs)
1986
1987 def GetZMax(*args, **kwargs):
1988 """GetZMax(self) -> int"""
1989 return _misc_.Joystick_GetZMax(*args, **kwargs)
1990
1991 def GetNumberButtons(*args, **kwargs):
1992 """GetNumberButtons(self) -> int"""
1993 return _misc_.Joystick_GetNumberButtons(*args, **kwargs)
1994
1995 def GetNumberAxes(*args, **kwargs):
1996 """GetNumberAxes(self) -> int"""
1997 return _misc_.Joystick_GetNumberAxes(*args, **kwargs)
1998
1999 def GetMaxButtons(*args, **kwargs):
2000 """GetMaxButtons(self) -> int"""
2001 return _misc_.Joystick_GetMaxButtons(*args, **kwargs)
2002
2003 def GetMaxAxes(*args, **kwargs):
2004 """GetMaxAxes(self) -> int"""
2005 return _misc_.Joystick_GetMaxAxes(*args, **kwargs)
2006
2007 def GetPollingMin(*args, **kwargs):
2008 """GetPollingMin(self) -> int"""
2009 return _misc_.Joystick_GetPollingMin(*args, **kwargs)
2010
2011 def GetPollingMax(*args, **kwargs):
2012 """GetPollingMax(self) -> int"""
2013 return _misc_.Joystick_GetPollingMax(*args, **kwargs)
2014
2015 def GetRudderMin(*args, **kwargs):
2016 """GetRudderMin(self) -> int"""
2017 return _misc_.Joystick_GetRudderMin(*args, **kwargs)
2018
2019 def GetRudderMax(*args, **kwargs):
2020 """GetRudderMax(self) -> int"""
2021 return _misc_.Joystick_GetRudderMax(*args, **kwargs)
2022
2023 def GetUMin(*args, **kwargs):
2024 """GetUMin(self) -> int"""
2025 return _misc_.Joystick_GetUMin(*args, **kwargs)
2026
2027 def GetUMax(*args, **kwargs):
2028 """GetUMax(self) -> int"""
2029 return _misc_.Joystick_GetUMax(*args, **kwargs)
2030
2031 def GetVMin(*args, **kwargs):
2032 """GetVMin(self) -> int"""
2033 return _misc_.Joystick_GetVMin(*args, **kwargs)
2034
2035 def GetVMax(*args, **kwargs):
2036 """GetVMax(self) -> int"""
2037 return _misc_.Joystick_GetVMax(*args, **kwargs)
2038
2039 def HasRudder(*args, **kwargs):
2040 """HasRudder(self) -> bool"""
2041 return _misc_.Joystick_HasRudder(*args, **kwargs)
2042
2043 def HasZ(*args, **kwargs):
2044 """HasZ(self) -> bool"""
2045 return _misc_.Joystick_HasZ(*args, **kwargs)
2046
2047 def HasU(*args, **kwargs):
2048 """HasU(self) -> bool"""
2049 return _misc_.Joystick_HasU(*args, **kwargs)
2050
2051 def HasV(*args, **kwargs):
2052 """HasV(self) -> bool"""
2053 return _misc_.Joystick_HasV(*args, **kwargs)
2054
2055 def HasPOV(*args, **kwargs):
2056 """HasPOV(self) -> bool"""
2057 return _misc_.Joystick_HasPOV(*args, **kwargs)
2058
2059 def HasPOV4Dir(*args, **kwargs):
2060 """HasPOV4Dir(self) -> bool"""
2061 return _misc_.Joystick_HasPOV4Dir(*args, **kwargs)
2062
2063 def HasPOVCTS(*args, **kwargs):
2064 """HasPOVCTS(self) -> bool"""
2065 return _misc_.Joystick_HasPOVCTS(*args, **kwargs)
2066
2067 def SetCapture(*args, **kwargs):
2068 """SetCapture(self, Window win, int pollingFreq=0) -> bool"""
2069 return _misc_.Joystick_SetCapture(*args, **kwargs)
2070
2071 def ReleaseCapture(*args, **kwargs):
2072 """ReleaseCapture(self) -> bool"""
2073 return _misc_.Joystick_ReleaseCapture(*args, **kwargs)
2074
2075 def __nonzero__(self): return self.IsOk()
2076
2077 class JoystickPtr(Joystick):
2078 def __init__(self, this):
2079 self.this = this
2080 if not hasattr(self,"thisown"): self.thisown = 0
2081 self.__class__ = Joystick
2082 _misc_.Joystick_swigregister(JoystickPtr)
2083
2084 wxEVT_JOY_BUTTON_DOWN = _misc_.wxEVT_JOY_BUTTON_DOWN
2085 wxEVT_JOY_BUTTON_UP = _misc_.wxEVT_JOY_BUTTON_UP
2086 wxEVT_JOY_MOVE = _misc_.wxEVT_JOY_MOVE
2087 wxEVT_JOY_ZMOVE = _misc_.wxEVT_JOY_ZMOVE
2088 class JoystickEvent(_core.Event):
2089 """Proxy of C++ JoystickEvent class"""
2090 def __repr__(self):
2091 return "<%s.%s; proxy of C++ wxJoystickEvent instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
2092 def __init__(self, *args, **kwargs):
2093 """
2094 __init__(self, wxEventType type=wxEVT_NULL, int state=0, int joystick=JOYSTICK1,
2095 int change=0) -> JoystickEvent
2096 """
2097 newobj = _misc_.new_JoystickEvent(*args, **kwargs)
2098 self.this = newobj.this
2099 self.thisown = 1
2100 del newobj.thisown
2101 def GetPosition(*args, **kwargs):
2102 """GetPosition(self) -> Point"""
2103 return _misc_.JoystickEvent_GetPosition(*args, **kwargs)
2104
2105 def GetZPosition(*args, **kwargs):
2106 """GetZPosition(self) -> int"""
2107 return _misc_.JoystickEvent_GetZPosition(*args, **kwargs)
2108
2109 def GetButtonState(*args, **kwargs):
2110 """GetButtonState(self) -> int"""
2111 return _misc_.JoystickEvent_GetButtonState(*args, **kwargs)
2112
2113 def GetButtonChange(*args, **kwargs):
2114 """GetButtonChange(self) -> int"""
2115 return _misc_.JoystickEvent_GetButtonChange(*args, **kwargs)
2116
2117 def GetJoystick(*args, **kwargs):
2118 """GetJoystick(self) -> int"""
2119 return _misc_.JoystickEvent_GetJoystick(*args, **kwargs)
2120
2121 def SetJoystick(*args, **kwargs):
2122 """SetJoystick(self, int stick)"""
2123 return _misc_.JoystickEvent_SetJoystick(*args, **kwargs)
2124
2125 def SetButtonState(*args, **kwargs):
2126 """SetButtonState(self, int state)"""
2127 return _misc_.JoystickEvent_SetButtonState(*args, **kwargs)
2128
2129 def SetButtonChange(*args, **kwargs):
2130 """SetButtonChange(self, int change)"""
2131 return _misc_.JoystickEvent_SetButtonChange(*args, **kwargs)
2132
2133 def SetPosition(*args, **kwargs):
2134 """SetPosition(self, Point pos)"""
2135 return _misc_.JoystickEvent_SetPosition(*args, **kwargs)
2136
2137 def SetZPosition(*args, **kwargs):
2138 """SetZPosition(self, int zPos)"""
2139 return _misc_.JoystickEvent_SetZPosition(*args, **kwargs)
2140
2141 def IsButton(*args, **kwargs):
2142 """IsButton(self) -> bool"""
2143 return _misc_.JoystickEvent_IsButton(*args, **kwargs)
2144
2145 def IsMove(*args, **kwargs):
2146 """IsMove(self) -> bool"""
2147 return _misc_.JoystickEvent_IsMove(*args, **kwargs)
2148
2149 def IsZMove(*args, **kwargs):
2150 """IsZMove(self) -> bool"""
2151 return _misc_.JoystickEvent_IsZMove(*args, **kwargs)
2152
2153 def ButtonDown(*args, **kwargs):
2154 """ButtonDown(self, int but=JOY_BUTTON_ANY) -> bool"""
2155 return _misc_.JoystickEvent_ButtonDown(*args, **kwargs)
2156
2157 def ButtonUp(*args, **kwargs):
2158 """ButtonUp(self, int but=JOY_BUTTON_ANY) -> bool"""
2159 return _misc_.JoystickEvent_ButtonUp(*args, **kwargs)
2160
2161 def ButtonIsDown(*args, **kwargs):
2162 """ButtonIsDown(self, int but=JOY_BUTTON_ANY) -> bool"""
2163 return _misc_.JoystickEvent_ButtonIsDown(*args, **kwargs)
2164
2165 m_pos = property(GetPosition, SetPosition)
2166 m_zPosition = property(GetZPosition, SetZPosition)
2167 m_buttonChange = property(GetButtonChange, SetButtonChange)
2168 m_buttonState = property(GetButtonState, SetButtonState)
2169 m_joyStick = property(GetJoystick, SetJoystick)
2170
2171
2172 class JoystickEventPtr(JoystickEvent):
2173 def __init__(self, this):
2174 self.this = this
2175 if not hasattr(self,"thisown"): self.thisown = 0
2176 self.__class__ = JoystickEvent
2177 _misc_.JoystickEvent_swigregister(JoystickEventPtr)
2178
2179 EVT_JOY_BUTTON_DOWN = wx.PyEventBinder( wxEVT_JOY_BUTTON_DOWN )
2180 EVT_JOY_BUTTON_UP = wx.PyEventBinder( wxEVT_JOY_BUTTON_UP )
2181 EVT_JOY_MOVE = wx.PyEventBinder( wxEVT_JOY_MOVE )
2182 EVT_JOY_ZMOVE = wx.PyEventBinder( wxEVT_JOY_ZMOVE )
2183
2184 EVT_JOYSTICK_EVENTS = wx.PyEventBinder([ wxEVT_JOY_BUTTON_DOWN,
2185 wxEVT_JOY_BUTTON_UP,
2186 wxEVT_JOY_MOVE,
2187 wxEVT_JOY_ZMOVE,
2188 ])
2189
2190
2191 #---------------------------------------------------------------------------
2192
2193 SOUND_SYNC = _misc_.SOUND_SYNC
2194 SOUND_ASYNC = _misc_.SOUND_ASYNC
2195 SOUND_LOOP = _misc_.SOUND_LOOP
2196 class Sound(object):
2197 """Proxy of C++ Sound class"""
2198 def __repr__(self):
2199 return "<%s.%s; proxy of C++ wxSound instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
2200 def __init__(self, *args, **kwargs):
2201 """__init__(self, String fileName=EmptyString) -> Sound"""
2202 newobj = _misc_.new_Sound(*args, **kwargs)
2203 self.this = newobj.this
2204 self.thisown = 1
2205 del newobj.thisown
2206 def __del__(self, destroy=_misc_.delete_Sound):
2207 """__del__(self)"""
2208 try:
2209 if self.thisown: destroy(self)
2210 except: pass
2211
2212 def Create(*args, **kwargs):
2213 """Create(self, String fileName) -> bool"""
2214 return _misc_.Sound_Create(*args, **kwargs)
2215
2216 def CreateFromData(*args, **kwargs):
2217 """CreateFromData(self, PyObject data) -> bool"""
2218 return _misc_.Sound_CreateFromData(*args, **kwargs)
2219
2220 def IsOk(*args, **kwargs):
2221 """IsOk(self) -> bool"""
2222 return _misc_.Sound_IsOk(*args, **kwargs)
2223
2224 def Play(*args, **kwargs):
2225 """Play(self, unsigned int flags=SOUND_ASYNC) -> bool"""
2226 return _misc_.Sound_Play(*args, **kwargs)
2227
2228 def PlaySound(*args, **kwargs):
2229 """PlaySound(String filename, unsigned int flags=SOUND_ASYNC) -> bool"""
2230 return _misc_.Sound_PlaySound(*args, **kwargs)
2231
2232 PlaySound = staticmethod(PlaySound)
2233 def Stop(*args, **kwargs):
2234 """Stop()"""
2235 return _misc_.Sound_Stop(*args, **kwargs)
2236
2237 Stop = staticmethod(Stop)
2238 def __nonzero__(self): return self.IsOk()
2239
2240 class SoundPtr(Sound):
2241 def __init__(self, this):
2242 self.this = this
2243 if not hasattr(self,"thisown"): self.thisown = 0
2244 self.__class__ = Sound
2245 _misc_.Sound_swigregister(SoundPtr)
2246
2247 def SoundFromData(*args, **kwargs):
2248 """SoundFromData(PyObject data) -> Sound"""
2249 val = _misc_.new_SoundFromData(*args, **kwargs)
2250 val.thisown = 1
2251 return val
2252
2253 def Sound_PlaySound(*args, **kwargs):
2254 """Sound_PlaySound(String filename, unsigned int flags=SOUND_ASYNC) -> bool"""
2255 return _misc_.Sound_PlaySound(*args, **kwargs)
2256
2257 def Sound_Stop(*args, **kwargs):
2258 """Sound_Stop()"""
2259 return _misc_.Sound_Stop(*args, **kwargs)
2260
2261 #---------------------------------------------------------------------------
2262
2263 MAILCAP_STANDARD = _misc_.MAILCAP_STANDARD
2264 MAILCAP_NETSCAPE = _misc_.MAILCAP_NETSCAPE
2265 MAILCAP_KDE = _misc_.MAILCAP_KDE
2266 MAILCAP_GNOME = _misc_.MAILCAP_GNOME
2267 MAILCAP_ALL = _misc_.MAILCAP_ALL
2268 class FileTypeInfo(object):
2269 """Proxy of C++ FileTypeInfo class"""
2270 def __repr__(self):
2271 return "<%s.%s; proxy of C++ wxFileTypeInfo instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
2272 def __init__(self, *args, **kwargs):
2273 """__init__(self, String mimeType, String openCmd, String printCmd, String desc) -> FileTypeInfo"""
2274 newobj = _misc_.new_FileTypeInfo(*args, **kwargs)
2275 self.this = newobj.this
2276 self.thisown = 1
2277 del newobj.thisown
2278 def IsValid(*args, **kwargs):
2279 """IsValid(self) -> bool"""
2280 return _misc_.FileTypeInfo_IsValid(*args, **kwargs)
2281
2282 def SetIcon(*args, **kwargs):
2283 """SetIcon(self, String iconFile, int iconIndex=0)"""
2284 return _misc_.FileTypeInfo_SetIcon(*args, **kwargs)
2285
2286 def SetShortDesc(*args, **kwargs):
2287 """SetShortDesc(self, String shortDesc)"""
2288 return _misc_.FileTypeInfo_SetShortDesc(*args, **kwargs)
2289
2290 def GetMimeType(*args, **kwargs):
2291 """GetMimeType(self) -> String"""
2292 return _misc_.FileTypeInfo_GetMimeType(*args, **kwargs)
2293
2294 def GetOpenCommand(*args, **kwargs):
2295 """GetOpenCommand(self) -> String"""
2296 return _misc_.FileTypeInfo_GetOpenCommand(*args, **kwargs)
2297
2298 def GetPrintCommand(*args, **kwargs):
2299 """GetPrintCommand(self) -> String"""
2300 return _misc_.FileTypeInfo_GetPrintCommand(*args, **kwargs)
2301
2302 def GetShortDesc(*args, **kwargs):
2303 """GetShortDesc(self) -> String"""
2304 return _misc_.FileTypeInfo_GetShortDesc(*args, **kwargs)
2305
2306 def GetDescription(*args, **kwargs):
2307 """GetDescription(self) -> String"""
2308 return _misc_.FileTypeInfo_GetDescription(*args, **kwargs)
2309
2310 def GetExtensions(*args, **kwargs):
2311 """GetExtensions(self) -> wxArrayString"""
2312 return _misc_.FileTypeInfo_GetExtensions(*args, **kwargs)
2313
2314 def GetExtensionsCount(*args, **kwargs):
2315 """GetExtensionsCount(self) -> int"""
2316 return _misc_.FileTypeInfo_GetExtensionsCount(*args, **kwargs)
2317
2318 def GetIconFile(*args, **kwargs):
2319 """GetIconFile(self) -> String"""
2320 return _misc_.FileTypeInfo_GetIconFile(*args, **kwargs)
2321
2322 def GetIconIndex(*args, **kwargs):
2323 """GetIconIndex(self) -> int"""
2324 return _misc_.FileTypeInfo_GetIconIndex(*args, **kwargs)
2325
2326
2327 class FileTypeInfoPtr(FileTypeInfo):
2328 def __init__(self, this):
2329 self.this = this
2330 if not hasattr(self,"thisown"): self.thisown = 0
2331 self.__class__ = FileTypeInfo
2332 _misc_.FileTypeInfo_swigregister(FileTypeInfoPtr)
2333
2334 def FileTypeInfoSequence(*args, **kwargs):
2335 """FileTypeInfoSequence(wxArrayString sArray) -> FileTypeInfo"""
2336 val = _misc_.new_FileTypeInfoSequence(*args, **kwargs)
2337 val.thisown = 1
2338 return val
2339
2340 def NullFileTypeInfo(*args, **kwargs):
2341 """NullFileTypeInfo() -> FileTypeInfo"""
2342 val = _misc_.new_NullFileTypeInfo(*args, **kwargs)
2343 val.thisown = 1
2344 return val
2345
2346 class FileType(object):
2347 """Proxy of C++ FileType class"""
2348 def __repr__(self):
2349 return "<%s.%s; proxy of C++ wxFileType instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
2350 def __init__(self, *args, **kwargs):
2351 """__init__(self, FileTypeInfo ftInfo) -> FileType"""
2352 newobj = _misc_.new_FileType(*args, **kwargs)
2353 self.this = newobj.this
2354 self.thisown = 1
2355 del newobj.thisown
2356 def __del__(self, destroy=_misc_.delete_FileType):
2357 """__del__(self)"""
2358 try:
2359 if self.thisown: destroy(self)
2360 except: pass
2361
2362 def GetMimeType(*args, **kwargs):
2363 """GetMimeType(self) -> PyObject"""
2364 return _misc_.FileType_GetMimeType(*args, **kwargs)
2365
2366 def GetMimeTypes(*args, **kwargs):
2367 """GetMimeTypes(self) -> PyObject"""
2368 return _misc_.FileType_GetMimeTypes(*args, **kwargs)
2369
2370 def GetExtensions(*args, **kwargs):
2371 """GetExtensions(self) -> PyObject"""
2372 return _misc_.FileType_GetExtensions(*args, **kwargs)
2373
2374 def GetIcon(*args, **kwargs):
2375 """GetIcon(self) -> Icon"""
2376 return _misc_.FileType_GetIcon(*args, **kwargs)
2377
2378 def GetIconInfo(*args, **kwargs):
2379 """GetIconInfo(self) -> PyObject"""
2380 return _misc_.FileType_GetIconInfo(*args, **kwargs)
2381
2382 def GetDescription(*args, **kwargs):
2383 """GetDescription(self) -> PyObject"""
2384 return _misc_.FileType_GetDescription(*args, **kwargs)
2385
2386 def GetOpenCommand(*args, **kwargs):
2387 """GetOpenCommand(self, String filename, String mimetype=EmptyString) -> PyObject"""
2388 return _misc_.FileType_GetOpenCommand(*args, **kwargs)
2389
2390 def GetPrintCommand(*args, **kwargs):
2391 """GetPrintCommand(self, String filename, String mimetype=EmptyString) -> PyObject"""
2392 return _misc_.FileType_GetPrintCommand(*args, **kwargs)
2393
2394 def GetAllCommands(*args, **kwargs):
2395 """GetAllCommands(self, String filename, String mimetype=EmptyString) -> PyObject"""
2396 return _misc_.FileType_GetAllCommands(*args, **kwargs)
2397
2398 def SetCommand(*args, **kwargs):
2399 """SetCommand(self, String cmd, String verb, bool overwriteprompt=True) -> bool"""
2400 return _misc_.FileType_SetCommand(*args, **kwargs)
2401
2402 def SetDefaultIcon(*args, **kwargs):
2403 """SetDefaultIcon(self, String cmd=EmptyString, int index=0) -> bool"""
2404 return _misc_.FileType_SetDefaultIcon(*args, **kwargs)
2405
2406 def Unassociate(*args, **kwargs):
2407 """Unassociate(self) -> bool"""
2408 return _misc_.FileType_Unassociate(*args, **kwargs)
2409
2410 def ExpandCommand(*args, **kwargs):
2411 """ExpandCommand(String command, String filename, String mimetype=EmptyString) -> String"""
2412 return _misc_.FileType_ExpandCommand(*args, **kwargs)
2413
2414 ExpandCommand = staticmethod(ExpandCommand)
2415
2416 class FileTypePtr(FileType):
2417 def __init__(self, this):
2418 self.this = this
2419 if not hasattr(self,"thisown"): self.thisown = 0
2420 self.__class__ = FileType
2421 _misc_.FileType_swigregister(FileTypePtr)
2422
2423 def FileType_ExpandCommand(*args, **kwargs):
2424 """FileType_ExpandCommand(String command, String filename, String mimetype=EmptyString) -> String"""
2425 return _misc_.FileType_ExpandCommand(*args, **kwargs)
2426
2427 class MimeTypesManager(object):
2428 """Proxy of C++ MimeTypesManager class"""
2429 def __repr__(self):
2430 return "<%s.%s; proxy of C++ wxMimeTypesManager instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
2431 def IsOfType(*args, **kwargs):
2432 """IsOfType(String mimeType, String wildcard) -> bool"""
2433 return _misc_.MimeTypesManager_IsOfType(*args, **kwargs)
2434
2435 IsOfType = staticmethod(IsOfType)
2436 def __init__(self, *args, **kwargs):
2437 """__init__(self) -> MimeTypesManager"""
2438 newobj = _misc_.new_MimeTypesManager(*args, **kwargs)
2439 self.this = newobj.this
2440 self.thisown = 1
2441 del newobj.thisown
2442 def Initialize(*args, **kwargs):
2443 """Initialize(self, int mailcapStyle=MAILCAP_ALL, String extraDir=EmptyString)"""
2444 return _misc_.MimeTypesManager_Initialize(*args, **kwargs)
2445
2446 def ClearData(*args, **kwargs):
2447 """ClearData(self)"""
2448 return _misc_.MimeTypesManager_ClearData(*args, **kwargs)
2449
2450 def GetFileTypeFromExtension(*args, **kwargs):
2451 """GetFileTypeFromExtension(self, String ext) -> FileType"""
2452 return _misc_.MimeTypesManager_GetFileTypeFromExtension(*args, **kwargs)
2453
2454 def GetFileTypeFromMimeType(*args, **kwargs):
2455 """GetFileTypeFromMimeType(self, String mimeType) -> FileType"""
2456 return _misc_.MimeTypesManager_GetFileTypeFromMimeType(*args, **kwargs)
2457
2458 def ReadMailcap(*args, **kwargs):
2459 """ReadMailcap(self, String filename, bool fallback=False) -> bool"""
2460 return _misc_.MimeTypesManager_ReadMailcap(*args, **kwargs)
2461
2462 def ReadMimeTypes(*args, **kwargs):
2463 """ReadMimeTypes(self, String filename) -> bool"""
2464 return _misc_.MimeTypesManager_ReadMimeTypes(*args, **kwargs)
2465
2466 def EnumAllFileTypes(*args, **kwargs):
2467 """EnumAllFileTypes(self) -> PyObject"""
2468 return _misc_.MimeTypesManager_EnumAllFileTypes(*args, **kwargs)
2469
2470 def AddFallback(*args, **kwargs):
2471 """AddFallback(self, FileTypeInfo ft)"""
2472 return _misc_.MimeTypesManager_AddFallback(*args, **kwargs)
2473
2474 def Associate(*args, **kwargs):
2475 """Associate(self, FileTypeInfo ftInfo) -> FileType"""
2476 return _misc_.MimeTypesManager_Associate(*args, **kwargs)
2477
2478 def Unassociate(*args, **kwargs):
2479 """Unassociate(self, FileType ft) -> bool"""
2480 return _misc_.MimeTypesManager_Unassociate(*args, **kwargs)
2481
2482 def __del__(self, destroy=_misc_.delete_MimeTypesManager):
2483 """__del__(self)"""
2484 try:
2485 if self.thisown: destroy(self)
2486 except: pass
2487
2488
2489 class MimeTypesManagerPtr(MimeTypesManager):
2490 def __init__(self, this):
2491 self.this = this
2492 if not hasattr(self,"thisown"): self.thisown = 0
2493 self.__class__ = MimeTypesManager
2494 _misc_.MimeTypesManager_swigregister(MimeTypesManagerPtr)
2495 TheMimeTypesManager = cvar.TheMimeTypesManager
2496
2497 def MimeTypesManager_IsOfType(*args, **kwargs):
2498 """MimeTypesManager_IsOfType(String mimeType, String wildcard) -> bool"""
2499 return _misc_.MimeTypesManager_IsOfType(*args, **kwargs)
2500
2501 #---------------------------------------------------------------------------
2502
2503 class ArtProvider(object):
2504 """
2505 The wx.ArtProvider class is used to customize the look of wxWidgets
2506 application. When wxWidgets needs to display an icon or a bitmap (e.g.
2507 in the standard file dialog), it does not use hard-coded resource but
2508 asks wx.ArtProvider for it instead. This way the users can plug in
2509 their own wx.ArtProvider class and easily replace standard art with
2510 his/her own version. It is easy thing to do: all that is needed is
2511 to derive a class from wx.ArtProvider, override it's CreateBitmap
2512 method and register the provider with wx.ArtProvider.PushProvider::
2513
2514 class MyArtProvider(wx.ArtProvider):
2515 def __init__(self):
2516 wx.ArtProvider.__init__(self)
2517
2518 def CreateBitmap(self, artid, client, size):
2519 ...
2520 return bmp
2521
2522 """
2523 def __repr__(self):
2524 return "<%s.%s; proxy of C++ wxPyArtProvider instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
2525 def __init__(self, *args, **kwargs):
2526 """
2527 __init__(self) -> ArtProvider
2528
2529 The wx.ArtProvider class is used to customize the look of wxWidgets
2530 application. When wxWidgets needs to display an icon or a bitmap (e.g.
2531 in the standard file dialog), it does not use hard-coded resource but
2532 asks wx.ArtProvider for it instead. This way the users can plug in
2533 their own wx.ArtProvider class and easily replace standard art with
2534 his/her own version. It is easy thing to do: all that is needed is
2535 to derive a class from wx.ArtProvider, override it's CreateBitmap
2536 method and register the provider with wx.ArtProvider.PushProvider::
2537
2538 class MyArtProvider(wx.ArtProvider):
2539 def __init__(self):
2540 wx.ArtProvider.__init__(self)
2541
2542 def CreateBitmap(self, artid, client, size):
2543 ...
2544 return bmp
2545
2546 """
2547 newobj = _misc_.new_ArtProvider(*args, **kwargs)
2548 self.this = newobj.this
2549 self.thisown = 1
2550 del newobj.thisown
2551 self._setCallbackInfo(self, ArtProvider)
2552
2553 def _setCallbackInfo(*args, **kwargs):
2554 """_setCallbackInfo(self, PyObject self, PyObject _class)"""
2555 return _misc_.ArtProvider__setCallbackInfo(*args, **kwargs)
2556
2557 def PushProvider(*args, **kwargs):
2558 """
2559 PushProvider(ArtProvider provider)
2560
2561 Add new provider to the top of providers stack.
2562 """
2563 return _misc_.ArtProvider_PushProvider(*args, **kwargs)
2564
2565 PushProvider = staticmethod(PushProvider)
2566 def PopProvider(*args, **kwargs):
2567 """
2568 PopProvider() -> bool
2569
2570 Remove latest added provider and delete it.
2571 """
2572 return _misc_.ArtProvider_PopProvider(*args, **kwargs)
2573
2574 PopProvider = staticmethod(PopProvider)
2575 def RemoveProvider(*args, **kwargs):
2576 """
2577 RemoveProvider(ArtProvider provider) -> bool
2578
2579 Remove provider. The provider must have been added previously! The
2580 provider is _not_ deleted.
2581 """
2582 return _misc_.ArtProvider_RemoveProvider(*args, **kwargs)
2583
2584 RemoveProvider = staticmethod(RemoveProvider)
2585 def GetBitmap(*args, **kwargs):
2586 """
2587 GetBitmap(String id, String client=ART_OTHER, Size size=DefaultSize) -> Bitmap
2588
2589 Query the providers for bitmap with given ID and return it. Return
2590 wx.NullBitmap if no provider provides it.
2591 """
2592 return _misc_.ArtProvider_GetBitmap(*args, **kwargs)
2593
2594 GetBitmap = staticmethod(GetBitmap)
2595 def GetIcon(*args, **kwargs):
2596 """
2597 GetIcon(String id, String client=ART_OTHER, Size size=DefaultSize) -> Icon
2598
2599 Query the providers for icon with given ID and return it. Return
2600 wx.NullIcon if no provider provides it.
2601 """
2602 return _misc_.ArtProvider_GetIcon(*args, **kwargs)
2603
2604 GetIcon = staticmethod(GetIcon)
2605 def GetSizeHint(*args, **kwargs):
2606 """
2607 GetSizeHint(String client, bool platform_dependent=False) -> Size
2608
2609 Get the size hint of an icon from a specific Art Client, queries the
2610 topmost provider if platform_dependent = false
2611 """
2612 return _misc_.ArtProvider_GetSizeHint(*args, **kwargs)
2613
2614 GetSizeHint = staticmethod(GetSizeHint)
2615 def Destroy(*args, **kwargs):
2616 """Destroy(self)"""
2617 return _misc_.ArtProvider_Destroy(*args, **kwargs)
2618
2619
2620 class ArtProviderPtr(ArtProvider):
2621 def __init__(self, this):
2622 self.this = this
2623 if not hasattr(self,"thisown"): self.thisown = 0
2624 self.__class__ = ArtProvider
2625 _misc_.ArtProvider_swigregister(ArtProviderPtr)
2626 ART_TOOLBAR = cvar.ART_TOOLBAR
2627 ART_MENU = cvar.ART_MENU
2628 ART_FRAME_ICON = cvar.ART_FRAME_ICON
2629 ART_CMN_DIALOG = cvar.ART_CMN_DIALOG
2630 ART_HELP_BROWSER = cvar.ART_HELP_BROWSER
2631 ART_MESSAGE_BOX = cvar.ART_MESSAGE_BOX
2632 ART_BUTTON = cvar.ART_BUTTON
2633 ART_OTHER = cvar.ART_OTHER
2634 ART_ADD_BOOKMARK = cvar.ART_ADD_BOOKMARK
2635 ART_DEL_BOOKMARK = cvar.ART_DEL_BOOKMARK
2636 ART_HELP_SIDE_PANEL = cvar.ART_HELP_SIDE_PANEL
2637 ART_HELP_SETTINGS = cvar.ART_HELP_SETTINGS
2638 ART_HELP_BOOK = cvar.ART_HELP_BOOK
2639 ART_HELP_FOLDER = cvar.ART_HELP_FOLDER
2640 ART_HELP_PAGE = cvar.ART_HELP_PAGE
2641 ART_GO_BACK = cvar.ART_GO_BACK
2642 ART_GO_FORWARD = cvar.ART_GO_FORWARD
2643 ART_GO_UP = cvar.ART_GO_UP
2644 ART_GO_DOWN = cvar.ART_GO_DOWN
2645 ART_GO_TO_PARENT = cvar.ART_GO_TO_PARENT
2646 ART_GO_HOME = cvar.ART_GO_HOME
2647 ART_FILE_OPEN = cvar.ART_FILE_OPEN
2648 ART_FILE_SAVE = cvar.ART_FILE_SAVE
2649 ART_FILE_SAVE_AS = cvar.ART_FILE_SAVE_AS
2650 ART_PRINT = cvar.ART_PRINT
2651 ART_HELP = cvar.ART_HELP
2652 ART_TIP = cvar.ART_TIP
2653 ART_REPORT_VIEW = cvar.ART_REPORT_VIEW
2654 ART_LIST_VIEW = cvar.ART_LIST_VIEW
2655 ART_NEW_DIR = cvar.ART_NEW_DIR
2656 ART_HARDDISK = cvar.ART_HARDDISK
2657 ART_FLOPPY = cvar.ART_FLOPPY
2658 ART_CDROM = cvar.ART_CDROM
2659 ART_REMOVABLE = cvar.ART_REMOVABLE
2660 ART_FOLDER = cvar.ART_FOLDER
2661 ART_FOLDER_OPEN = cvar.ART_FOLDER_OPEN
2662 ART_GO_DIR_UP = cvar.ART_GO_DIR_UP
2663 ART_EXECUTABLE_FILE = cvar.ART_EXECUTABLE_FILE
2664 ART_NORMAL_FILE = cvar.ART_NORMAL_FILE
2665 ART_TICK_MARK = cvar.ART_TICK_MARK
2666 ART_CROSS_MARK = cvar.ART_CROSS_MARK
2667 ART_ERROR = cvar.ART_ERROR
2668 ART_QUESTION = cvar.ART_QUESTION
2669 ART_WARNING = cvar.ART_WARNING
2670 ART_INFORMATION = cvar.ART_INFORMATION
2671 ART_MISSING_IMAGE = cvar.ART_MISSING_IMAGE
2672 ART_COPY = cvar.ART_COPY
2673 ART_CUT = cvar.ART_CUT
2674 ART_PASTE = cvar.ART_PASTE
2675 ART_DELETE = cvar.ART_DELETE
2676 ART_NEW = cvar.ART_NEW
2677 ART_UNDO = cvar.ART_UNDO
2678 ART_REDO = cvar.ART_REDO
2679 ART_QUIT = cvar.ART_QUIT
2680 ART_FIND = cvar.ART_FIND
2681 ART_FIND_AND_REPLACE = cvar.ART_FIND_AND_REPLACE
2682
2683 def ArtProvider_PushProvider(*args, **kwargs):
2684 """
2685 ArtProvider_PushProvider(ArtProvider provider)
2686
2687 Add new provider to the top of providers stack.
2688 """
2689 return _misc_.ArtProvider_PushProvider(*args, **kwargs)
2690
2691 def ArtProvider_PopProvider(*args, **kwargs):
2692 """
2693 ArtProvider_PopProvider() -> bool
2694
2695 Remove latest added provider and delete it.
2696 """
2697 return _misc_.ArtProvider_PopProvider(*args, **kwargs)
2698
2699 def ArtProvider_RemoveProvider(*args, **kwargs):
2700 """
2701 ArtProvider_RemoveProvider(ArtProvider provider) -> bool
2702
2703 Remove provider. The provider must have been added previously! The
2704 provider is _not_ deleted.
2705 """
2706 return _misc_.ArtProvider_RemoveProvider(*args, **kwargs)
2707
2708 def ArtProvider_GetBitmap(*args, **kwargs):
2709 """
2710 ArtProvider_GetBitmap(String id, String client=ART_OTHER, Size size=DefaultSize) -> Bitmap
2711
2712 Query the providers for bitmap with given ID and return it. Return
2713 wx.NullBitmap if no provider provides it.
2714 """
2715 return _misc_.ArtProvider_GetBitmap(*args, **kwargs)
2716
2717 def ArtProvider_GetIcon(*args, **kwargs):
2718 """
2719 ArtProvider_GetIcon(String id, String client=ART_OTHER, Size size=DefaultSize) -> Icon
2720
2721 Query the providers for icon with given ID and return it. Return
2722 wx.NullIcon if no provider provides it.
2723 """
2724 return _misc_.ArtProvider_GetIcon(*args, **kwargs)
2725
2726 def ArtProvider_GetSizeHint(*args, **kwargs):
2727 """
2728 ArtProvider_GetSizeHint(String client, bool platform_dependent=False) -> Size
2729
2730 Get the size hint of an icon from a specific Art Client, queries the
2731 topmost provider if platform_dependent = false
2732 """
2733 return _misc_.ArtProvider_GetSizeHint(*args, **kwargs)
2734
2735 #---------------------------------------------------------------------------
2736
2737 CONFIG_USE_LOCAL_FILE = _misc_.CONFIG_USE_LOCAL_FILE
2738 CONFIG_USE_GLOBAL_FILE = _misc_.CONFIG_USE_GLOBAL_FILE
2739 CONFIG_USE_RELATIVE_PATH = _misc_.CONFIG_USE_RELATIVE_PATH
2740 CONFIG_USE_NO_ESCAPE_CHARACTERS = _misc_.CONFIG_USE_NO_ESCAPE_CHARACTERS
2741 class ConfigBase(object):
2742 """
2743 wx.ConfigBase class defines the basic interface of all config
2744 classes. It can not be used by itself (it is an abstract base class)
2745 and you will always use one of its derivations: wx.Config or
2746 wx.FileConfig.
2747
2748 wx.ConfigBase organizes the items in a tree-like structure, modeled
2749 after the Unix/Dos filesystem. There are groups that act like
2750 directories and entries, key/value pairs that act like files. There
2751 is always one current group given by the current path. As in the file
2752 system case, to specify a key in the config class you must use a path
2753 to it. Config classes also support the notion of the current group,
2754 which makes it possible to use relative paths.
2755
2756 Keys are pairs "key_name = value" where value may be of string,
2757 integer floating point or boolean, you can not store binary data
2758 without first encoding it as a string. For performance reasons items
2759 should be kept small, no more than a couple kilobytes.
2760
2761 """
2762 def __init__(self): raise RuntimeError, "No constructor defined"
2763 def __repr__(self):
2764 return "<%s.%s; proxy of C++ wxConfigBase instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
2765 def __del__(self, destroy=_misc_.delete_ConfigBase):
2766 """__del__(self)"""
2767 try:
2768 if self.thisown: destroy(self)
2769 except: pass
2770
2771 Type_Unknown = _misc_.ConfigBase_Type_Unknown
2772 Type_String = _misc_.ConfigBase_Type_String
2773 Type_Boolean = _misc_.ConfigBase_Type_Boolean
2774 Type_Integer = _misc_.ConfigBase_Type_Integer
2775 Type_Float = _misc_.ConfigBase_Type_Float
2776 def Set(*args, **kwargs):
2777 """
2778 Set(ConfigBase config) -> ConfigBase
2779
2780 Sets the global config object (the one returned by Get) and returns a
2781 reference to the previous global config object.
2782 """
2783 return _misc_.ConfigBase_Set(*args, **kwargs)
2784
2785 Set = staticmethod(Set)
2786 def Get(*args, **kwargs):
2787 """
2788 Get(bool createOnDemand=True) -> ConfigBase
2789
2790 Returns the current global config object, creating one if neccessary.
2791 """
2792 return _misc_.ConfigBase_Get(*args, **kwargs)
2793
2794 Get = staticmethod(Get)
2795 def Create(*args, **kwargs):
2796 """
2797 Create() -> ConfigBase
2798
2799 Create and return a new global config object. This function will
2800 create the "best" implementation of wx.Config available for the
2801 current platform.
2802 """
2803 return _misc_.ConfigBase_Create(*args, **kwargs)
2804
2805 Create = staticmethod(Create)
2806 def DontCreateOnDemand(*args, **kwargs):
2807 """
2808 DontCreateOnDemand()
2809
2810 Should Get() try to create a new log object if there isn't a current
2811 one?
2812 """
2813 return _misc_.ConfigBase_DontCreateOnDemand(*args, **kwargs)
2814
2815 DontCreateOnDemand = staticmethod(DontCreateOnDemand)
2816 def SetPath(*args, **kwargs):
2817 """
2818 SetPath(self, String path)
2819
2820 Set current path: if the first character is '/', it's the absolute
2821 path, otherwise it's a relative path. '..' is supported. If the
2822 strPath doesn't exist it is created.
2823 """
2824 return _misc_.ConfigBase_SetPath(*args, **kwargs)
2825
2826 def GetPath(*args, **kwargs):
2827 """
2828 GetPath(self) -> String
2829
2830 Retrieve the current path (always as absolute path)
2831 """
2832 return _misc_.ConfigBase_GetPath(*args, **kwargs)
2833
2834 def GetFirstGroup(*args, **kwargs):
2835 """
2836 GetFirstGroup() -> (more, value, index)
2837
2838 Allows enumerating the subgroups in a config object. Returns a tuple
2839 containing a flag indicating there are more items, the name of the
2840 current item, and an index to pass to GetNextGroup to fetch the next
2841 item.
2842 """
2843 return _misc_.ConfigBase_GetFirstGroup(*args, **kwargs)
2844
2845 def GetNextGroup(*args, **kwargs):
2846 """
2847 GetNextGroup(long index) -> (more, value, index)
2848
2849 Allows enumerating the subgroups in a config object. Returns a tuple
2850 containing a flag indicating there are more items, the name of the
2851 current item, and an index to pass to GetNextGroup to fetch the next
2852 item.
2853 """
2854 return _misc_.ConfigBase_GetNextGroup(*args, **kwargs)
2855
2856 def GetFirstEntry(*args, **kwargs):
2857 """
2858 GetFirstEntry() -> (more, value, index)
2859
2860 Allows enumerating the entries in the current group in a config
2861 object. Returns a tuple containing a flag indicating there are more
2862 items, the name of the current item, and an index to pass to
2863 GetNextGroup to fetch the next item.
2864 """
2865 return _misc_.ConfigBase_GetFirstEntry(*args, **kwargs)
2866
2867 def GetNextEntry(*args, **kwargs):
2868 """
2869 GetNextEntry(long index) -> (more, value, index)
2870
2871 Allows enumerating the entries in the current group in a config
2872 object. Returns a tuple containing a flag indicating there are more
2873 items, the name of the current item, and an index to pass to
2874 GetNextGroup to fetch the next item.
2875 """
2876 return _misc_.ConfigBase_GetNextEntry(*args, **kwargs)
2877
2878 def GetNumberOfEntries(*args, **kwargs):
2879 """
2880 GetNumberOfEntries(self, bool recursive=False) -> size_t
2881
2882 Get the number of entries in the current group, with or without its
2883 subgroups.
2884 """
2885 return _misc_.ConfigBase_GetNumberOfEntries(*args, **kwargs)
2886
2887 def GetNumberOfGroups(*args, **kwargs):
2888 """
2889 GetNumberOfGroups(self, bool recursive=False) -> size_t
2890
2891 Get the number of subgroups in the current group, with or without its
2892 subgroups.
2893 """
2894 return _misc_.ConfigBase_GetNumberOfGroups(*args, **kwargs)
2895
2896 def HasGroup(*args, **kwargs):
2897 """
2898 HasGroup(self, String name) -> bool
2899
2900 Returns True if the group by this name exists
2901 """
2902 return _misc_.ConfigBase_HasGroup(*args, **kwargs)
2903
2904 def HasEntry(*args, **kwargs):
2905 """
2906 HasEntry(self, String name) -> bool
2907
2908 Returns True if the entry by this name exists
2909 """
2910 return _misc_.ConfigBase_HasEntry(*args, **kwargs)
2911
2912 def Exists(*args, **kwargs):
2913 """
2914 Exists(self, String name) -> bool
2915
2916 Returns True if either a group or an entry with a given name exists
2917 """
2918 return _misc_.ConfigBase_Exists(*args, **kwargs)
2919
2920 def GetEntryType(*args, **kwargs):
2921 """
2922 GetEntryType(self, String name) -> int
2923
2924 Get the type of the entry. Returns one of the wx.Config.Type_XXX values.
2925 """
2926 return _misc_.ConfigBase_GetEntryType(*args, **kwargs)
2927
2928 def Read(*args, **kwargs):
2929 """
2930 Read(self, String key, String defaultVal=EmptyString) -> String
2931
2932 Returns the value of key if it exists, defaultVal otherwise.
2933 """
2934 return _misc_.ConfigBase_Read(*args, **kwargs)
2935
2936 def ReadInt(*args, **kwargs):
2937 """
2938 ReadInt(self, String key, long defaultVal=0) -> long
2939
2940 Returns the value of key if it exists, defaultVal otherwise.
2941 """
2942 return _misc_.ConfigBase_ReadInt(*args, **kwargs)
2943
2944 def ReadFloat(*args, **kwargs):
2945 """
2946 ReadFloat(self, String key, double defaultVal=0.0) -> double
2947
2948 Returns the value of key if it exists, defaultVal otherwise.
2949 """
2950 return _misc_.ConfigBase_ReadFloat(*args, **kwargs)
2951
2952 def ReadBool(*args, **kwargs):
2953 """
2954 ReadBool(self, String key, bool defaultVal=False) -> bool
2955
2956 Returns the value of key if it exists, defaultVal otherwise.
2957 """
2958 return _misc_.ConfigBase_ReadBool(*args, **kwargs)
2959
2960 def Write(*args, **kwargs):
2961 """
2962 Write(self, String key, String value) -> bool
2963
2964 write the value (return True on success)
2965 """
2966 return _misc_.ConfigBase_Write(*args, **kwargs)
2967
2968 def WriteInt(*args, **kwargs):
2969 """
2970 WriteInt(self, String key, long value) -> bool
2971
2972 write the value (return True on success)
2973 """
2974 return _misc_.ConfigBase_WriteInt(*args, **kwargs)
2975
2976 def WriteFloat(*args, **kwargs):
2977 """
2978 WriteFloat(self, String key, double value) -> bool
2979
2980 write the value (return True on success)
2981 """
2982 return _misc_.ConfigBase_WriteFloat(*args, **kwargs)
2983
2984 def WriteBool(*args, **kwargs):
2985 """
2986 WriteBool(self, String key, bool value) -> bool
2987
2988 write the value (return True on success)
2989 """
2990 return _misc_.ConfigBase_WriteBool(*args, **kwargs)
2991
2992 def Flush(*args, **kwargs):
2993 """
2994 Flush(self, bool currentOnly=False) -> bool
2995
2996 permanently writes all changes
2997 """
2998 return _misc_.ConfigBase_Flush(*args, **kwargs)
2999
3000 def RenameEntry(*args, **kwargs):
3001 """
3002 RenameEntry(self, String oldName, String newName) -> bool
3003
3004 Rename an entry. Returns False on failure (probably because the new
3005 name is already taken by an existing entry)
3006 """
3007 return _misc_.ConfigBase_RenameEntry(*args, **kwargs)
3008
3009 def RenameGroup(*args, **kwargs):
3010 """
3011 RenameGroup(self, String oldName, String newName) -> bool
3012
3013 Rename a group. Returns False on failure (probably because the new
3014 name is already taken by an existing entry)
3015 """
3016 return _misc_.ConfigBase_RenameGroup(*args, **kwargs)
3017
3018 def DeleteEntry(*args, **kwargs):
3019 """
3020 DeleteEntry(self, String key, bool deleteGroupIfEmpty=True) -> bool
3021
3022 Deletes the specified entry and the group it belongs to if it was the
3023 last key in it and the second parameter is True
3024 """
3025 return _misc_.ConfigBase_DeleteEntry(*args, **kwargs)
3026
3027 def DeleteGroup(*args, **kwargs):
3028 """
3029 DeleteGroup(self, String key) -> bool
3030
3031 Delete the group (with all subgroups)
3032 """
3033 return _misc_.ConfigBase_DeleteGroup(*args, **kwargs)
3034
3035 def DeleteAll(*args, **kwargs):
3036 """
3037 DeleteAll(self) -> bool
3038
3039 Delete the whole underlying object (disk file, registry key, ...)
3040 primarly intended for use by deinstallation routine.
3041 """
3042 return _misc_.ConfigBase_DeleteAll(*args, **kwargs)
3043
3044 def SetExpandEnvVars(*args, **kwargs):
3045 """
3046 SetExpandEnvVars(self, bool doIt=True)
3047
3048 We can automatically expand environment variables in the config
3049 entries this option is on by default, you can turn it on/off at any
3050 time)
3051 """
3052 return _misc_.ConfigBase_SetExpandEnvVars(*args, **kwargs)
3053
3054 def IsExpandingEnvVars(*args, **kwargs):
3055 """
3056 IsExpandingEnvVars(self) -> bool
3057
3058 Are we currently expanding environment variables?
3059 """
3060 return _misc_.ConfigBase_IsExpandingEnvVars(*args, **kwargs)
3061
3062 def SetRecordDefaults(*args, **kwargs):
3063 """
3064 SetRecordDefaults(self, bool doIt=True)
3065
3066 Set whether the config objec should record default values.
3067 """
3068 return _misc_.ConfigBase_SetRecordDefaults(*args, **kwargs)
3069
3070 def IsRecordingDefaults(*args, **kwargs):
3071 """
3072 IsRecordingDefaults(self) -> bool
3073
3074 Are we currently recording default values?
3075 """
3076 return _misc_.ConfigBase_IsRecordingDefaults(*args, **kwargs)
3077
3078 def ExpandEnvVars(*args, **kwargs):
3079 """
3080 ExpandEnvVars(self, String str) -> String
3081
3082 Expand any environment variables in str and return the result
3083 """
3084 return _misc_.ConfigBase_ExpandEnvVars(*args, **kwargs)
3085
3086 def GetAppName(*args, **kwargs):
3087 """GetAppName(self) -> String"""
3088 return _misc_.ConfigBase_GetAppName(*args, **kwargs)
3089
3090 def GetVendorName(*args, **kwargs):
3091 """GetVendorName(self) -> String"""
3092 return _misc_.ConfigBase_GetVendorName(*args, **kwargs)
3093
3094 def SetAppName(*args, **kwargs):
3095 """SetAppName(self, String appName)"""
3096 return _misc_.ConfigBase_SetAppName(*args, **kwargs)
3097
3098 def SetVendorName(*args, **kwargs):
3099 """SetVendorName(self, String vendorName)"""
3100 return _misc_.ConfigBase_SetVendorName(*args, **kwargs)
3101
3102 def SetStyle(*args, **kwargs):
3103 """SetStyle(self, long style)"""
3104 return _misc_.ConfigBase_SetStyle(*args, **kwargs)
3105
3106 def GetStyle(*args, **kwargs):
3107 """GetStyle(self) -> long"""
3108 return _misc_.ConfigBase_GetStyle(*args, **kwargs)
3109
3110
3111 class ConfigBasePtr(ConfigBase):
3112 def __init__(self, this):
3113 self.this = this
3114 if not hasattr(self,"thisown"): self.thisown = 0
3115 self.__class__ = ConfigBase
3116 _misc_.ConfigBase_swigregister(ConfigBasePtr)
3117
3118 def ConfigBase_Set(*args, **kwargs):
3119 """
3120 ConfigBase_Set(ConfigBase config) -> ConfigBase
3121
3122 Sets the global config object (the one returned by Get) and returns a
3123 reference to the previous global config object.
3124 """
3125 return _misc_.ConfigBase_Set(*args, **kwargs)
3126
3127 def ConfigBase_Get(*args, **kwargs):
3128 """
3129 ConfigBase_Get(bool createOnDemand=True) -> ConfigBase
3130
3131 Returns the current global config object, creating one if neccessary.
3132 """
3133 return _misc_.ConfigBase_Get(*args, **kwargs)
3134
3135 def ConfigBase_Create(*args, **kwargs):
3136 """
3137 ConfigBase_Create() -> ConfigBase
3138
3139 Create and return a new global config object. This function will
3140 create the "best" implementation of wx.Config available for the
3141 current platform.
3142 """
3143 return _misc_.ConfigBase_Create(*args, **kwargs)
3144
3145 def ConfigBase_DontCreateOnDemand(*args, **kwargs):
3146 """
3147 ConfigBase_DontCreateOnDemand()
3148
3149 Should Get() try to create a new log object if there isn't a current
3150 one?
3151 """
3152 return _misc_.ConfigBase_DontCreateOnDemand(*args, **kwargs)
3153
3154 class Config(ConfigBase):
3155 """
3156 This ConfigBase-derived class will use the registry on Windows,
3157 and will be a wx.FileConfig on other platforms.
3158 """
3159 def __repr__(self):
3160 return "<%s.%s; proxy of C++ wxConfig instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
3161 def __init__(self, *args, **kwargs):
3162 """
3163 __init__(self, String appName=EmptyString, String vendorName=EmptyString,
3164 String localFilename=EmptyString, String globalFilename=EmptyString,
3165 long style=wxCONFIG_USE_LOCAL_FILE|wxCONFIG_USE_GLOBAL_FILE) -> Config
3166 """
3167 newobj = _misc_.new_Config(*args, **kwargs)
3168 self.this = newobj.this
3169 self.thisown = 1
3170 del newobj.thisown
3171 def __del__(self, destroy=_misc_.delete_Config):
3172 """__del__(self)"""
3173 try:
3174 if self.thisown: destroy(self)
3175 except: pass
3176
3177
3178 class ConfigPtr(Config):
3179 def __init__(self, this):
3180 self.this = this
3181 if not hasattr(self,"thisown"): self.thisown = 0
3182 self.__class__ = Config
3183 _misc_.Config_swigregister(ConfigPtr)
3184
3185 class FileConfig(ConfigBase):
3186 """This config class will use a file for storage on all platforms."""
3187 def __repr__(self):
3188 return "<%s.%s; proxy of C++ wxFileConfig instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
3189 def __init__(self, *args, **kwargs):
3190 """
3191 __init__(self, String appName=EmptyString, String vendorName=EmptyString,
3192 String localFilename=EmptyString, String globalFilename=EmptyString,
3193 long style=wxCONFIG_USE_LOCAL_FILE|wxCONFIG_USE_GLOBAL_FILE) -> FileConfig
3194 """
3195 newobj = _misc_.new_FileConfig(*args, **kwargs)
3196 self.this = newobj.this
3197 self.thisown = 1
3198 del newobj.thisown
3199 def __del__(self, destroy=_misc_.delete_FileConfig):
3200 """__del__(self)"""
3201 try:
3202 if self.thisown: destroy(self)
3203 except: pass
3204
3205
3206 class FileConfigPtr(FileConfig):
3207 def __init__(self, this):
3208 self.this = this
3209 if not hasattr(self,"thisown"): self.thisown = 0
3210 self.__class__ = FileConfig
3211 _misc_.FileConfig_swigregister(FileConfigPtr)
3212
3213 class ConfigPathChanger(object):
3214 """
3215 A handy little class which changes current path to the path of given
3216 entry and restores it in the destructoir: so if you declare a local
3217 variable of this type, you work in the entry directory and the path is
3218 automatically restored when the function returns.
3219 """
3220 def __repr__(self):
3221 return "<%s.%s; proxy of C++ wxConfigPathChanger instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
3222 def __init__(self, *args, **kwargs):
3223 """__init__(self, ConfigBase config, String entry) -> ConfigPathChanger"""
3224 newobj = _misc_.new_ConfigPathChanger(*args, **kwargs)
3225 self.this = newobj.this
3226 self.thisown = 1
3227 del newobj.thisown
3228 def __del__(self, destroy=_misc_.delete_ConfigPathChanger):
3229 """__del__(self)"""
3230 try:
3231 if self.thisown: destroy(self)
3232 except: pass
3233
3234 def Name(*args, **kwargs):
3235 """
3236 Name(self) -> String
3237
3238 Get the key name
3239 """
3240 return _misc_.ConfigPathChanger_Name(*args, **kwargs)
3241
3242
3243 class ConfigPathChangerPtr(ConfigPathChanger):
3244 def __init__(self, this):
3245 self.this = this
3246 if not hasattr(self,"thisown"): self.thisown = 0
3247 self.__class__ = ConfigPathChanger
3248 _misc_.ConfigPathChanger_swigregister(ConfigPathChangerPtr)
3249
3250
3251 def ExpandEnvVars(*args, **kwargs):
3252 """
3253 ExpandEnvVars(String sz) -> String
3254
3255 Replace environment variables ($SOMETHING) with their values. The
3256 format is $VARNAME or ${VARNAME} where VARNAME contains alphanumeric
3257 characters and '_' only. '$' must be escaped ('\$') in order to be
3258 taken literally.
3259 """
3260 return _misc_.ExpandEnvVars(*args, **kwargs)
3261 #---------------------------------------------------------------------------
3262
3263 class DateTime(object):
3264 """Proxy of C++ DateTime class"""
3265 def __repr__(self):
3266 return "<%s.%s; proxy of C++ wxDateTime instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
3267 Local = _misc_.DateTime_Local
3268 GMT_12 = _misc_.DateTime_GMT_12
3269 GMT_11 = _misc_.DateTime_GMT_11
3270 GMT_10 = _misc_.DateTime_GMT_10
3271 GMT_9 = _misc_.DateTime_GMT_9
3272 GMT_8 = _misc_.DateTime_GMT_8
3273 GMT_7 = _misc_.DateTime_GMT_7
3274 GMT_6 = _misc_.DateTime_GMT_6
3275 GMT_5 = _misc_.DateTime_GMT_5
3276 GMT_4 = _misc_.DateTime_GMT_4
3277 GMT_3 = _misc_.DateTime_GMT_3
3278 GMT_2 = _misc_.DateTime_GMT_2
3279 GMT_1 = _misc_.DateTime_GMT_1
3280 GMT0 = _misc_.DateTime_GMT0
3281 GMT1 = _misc_.DateTime_GMT1
3282 GMT2 = _misc_.DateTime_GMT2
3283 GMT3 = _misc_.DateTime_GMT3
3284 GMT4 = _misc_.DateTime_GMT4
3285 GMT5 = _misc_.DateTime_GMT5
3286 GMT6 = _misc_.DateTime_GMT6
3287 GMT7 = _misc_.DateTime_GMT7
3288 GMT8 = _misc_.DateTime_GMT8
3289 GMT9 = _misc_.DateTime_GMT9
3290 GMT10 = _misc_.DateTime_GMT10
3291 GMT11 = _misc_.DateTime_GMT11
3292 GMT12 = _misc_.DateTime_GMT12
3293 WET = _misc_.DateTime_WET
3294 WEST = _misc_.DateTime_WEST
3295 CET = _misc_.DateTime_CET
3296 CEST = _misc_.DateTime_CEST
3297 EET = _misc_.DateTime_EET
3298 EEST = _misc_.DateTime_EEST
3299 MSK = _misc_.DateTime_MSK
3300 MSD = _misc_.DateTime_MSD
3301 AST = _misc_.DateTime_AST
3302 ADT = _misc_.DateTime_ADT
3303 EST = _misc_.DateTime_EST
3304 EDT = _misc_.DateTime_EDT
3305 CST = _misc_.DateTime_CST
3306 CDT = _misc_.DateTime_CDT
3307 MST = _misc_.DateTime_MST
3308 MDT = _misc_.DateTime_MDT
3309 PST = _misc_.DateTime_PST
3310 PDT = _misc_.DateTime_PDT
3311 HST = _misc_.DateTime_HST
3312 AKST = _misc_.DateTime_AKST
3313 AKDT = _misc_.DateTime_AKDT
3314 A_WST = _misc_.DateTime_A_WST
3315 A_CST = _misc_.DateTime_A_CST
3316 A_EST = _misc_.DateTime_A_EST
3317 A_ESST = _misc_.DateTime_A_ESST
3318 UTC = _misc_.DateTime_UTC
3319 Gregorian = _misc_.DateTime_Gregorian
3320 Julian = _misc_.DateTime_Julian
3321 Gr_Unknown = _misc_.DateTime_Gr_Unknown
3322 Gr_Standard = _misc_.DateTime_Gr_Standard
3323 Gr_Alaska = _misc_.DateTime_Gr_Alaska
3324 Gr_Albania = _misc_.DateTime_Gr_Albania
3325 Gr_Austria = _misc_.DateTime_Gr_Austria
3326 Gr_Austria_Brixen = _misc_.DateTime_Gr_Austria_Brixen
3327 Gr_Austria_Salzburg = _misc_.DateTime_Gr_Austria_Salzburg
3328 Gr_Austria_Tyrol = _misc_.DateTime_Gr_Austria_Tyrol
3329 Gr_Austria_Carinthia = _misc_.DateTime_Gr_Austria_Carinthia
3330 Gr_Austria_Styria = _misc_.DateTime_Gr_Austria_Styria
3331 Gr_Belgium = _misc_.DateTime_Gr_Belgium
3332 Gr_Bulgaria = _misc_.DateTime_Gr_Bulgaria
3333 Gr_Bulgaria_1 = _misc_.DateTime_Gr_Bulgaria_1
3334 Gr_Bulgaria_2 = _misc_.DateTime_Gr_Bulgaria_2
3335 Gr_Bulgaria_3 = _misc_.DateTime_Gr_Bulgaria_3
3336 Gr_Canada = _misc_.DateTime_Gr_Canada
3337 Gr_China = _misc_.DateTime_Gr_China
3338 Gr_China_1 = _misc_.DateTime_Gr_China_1
3339 Gr_China_2 = _misc_.DateTime_Gr_China_2
3340 Gr_Czechoslovakia = _misc_.DateTime_Gr_Czechoslovakia
3341 Gr_Denmark = _misc_.DateTime_Gr_Denmark
3342 Gr_Egypt = _misc_.DateTime_Gr_Egypt
3343 Gr_Estonia = _misc_.DateTime_Gr_Estonia
3344 Gr_Finland = _misc_.DateTime_Gr_Finland
3345 Gr_France = _misc_.DateTime_Gr_France
3346 Gr_France_Alsace = _misc_.DateTime_Gr_France_Alsace
3347 Gr_France_Lorraine = _misc_.DateTime_Gr_France_Lorraine
3348 Gr_France_Strasbourg = _misc_.DateTime_Gr_France_Strasbourg
3349 Gr_Germany = _misc_.DateTime_Gr_Germany
3350 Gr_Germany_Catholic = _misc_.DateTime_Gr_Germany_Catholic
3351 Gr_Germany_Prussia = _misc_.DateTime_Gr_Germany_Prussia
3352 Gr_Germany_Protestant = _misc_.DateTime_Gr_Germany_Protestant
3353 Gr_GreatBritain = _misc_.DateTime_Gr_GreatBritain
3354 Gr_Greece = _misc_.DateTime_Gr_Greece
3355 Gr_Hungary = _misc_.DateTime_Gr_Hungary
3356 Gr_Ireland = _misc_.DateTime_Gr_Ireland
3357 Gr_Italy = _misc_.DateTime_Gr_Italy
3358 Gr_Japan = _misc_.DateTime_Gr_Japan
3359 Gr_Japan_1 = _misc_.DateTime_Gr_Japan_1
3360 Gr_Japan_2 = _misc_.DateTime_Gr_Japan_2
3361 Gr_Japan_3 = _misc_.DateTime_Gr_Japan_3
3362 Gr_Latvia = _misc_.DateTime_Gr_Latvia
3363 Gr_Lithuania = _misc_.DateTime_Gr_Lithuania
3364 Gr_Luxemburg = _misc_.DateTime_Gr_Luxemburg
3365 Gr_Netherlands = _misc_.DateTime_Gr_Netherlands
3366 Gr_Netherlands_Groningen = _misc_.DateTime_Gr_Netherlands_Groningen
3367 Gr_Netherlands_Gelderland = _misc_.DateTime_Gr_Netherlands_Gelderland
3368 Gr_Netherlands_Utrecht = _misc_.DateTime_Gr_Netherlands_Utrecht
3369 Gr_Netherlands_Friesland = _misc_.DateTime_Gr_Netherlands_Friesland
3370 Gr_Norway = _misc_.DateTime_Gr_Norway
3371 Gr_Poland = _misc_.DateTime_Gr_Poland
3372 Gr_Portugal = _misc_.DateTime_Gr_Portugal
3373 Gr_Romania = _misc_.DateTime_Gr_Romania
3374 Gr_Russia = _misc_.DateTime_Gr_Russia
3375 Gr_Scotland = _misc_.DateTime_Gr_Scotland
3376 Gr_Spain = _misc_.DateTime_Gr_Spain
3377 Gr_Sweden = _misc_.DateTime_Gr_Sweden
3378 Gr_Switzerland = _misc_.DateTime_Gr_Switzerland
3379 Gr_Switzerland_Catholic = _misc_.DateTime_Gr_Switzerland_Catholic
3380 Gr_Switzerland_Protestant = _misc_.DateTime_Gr_Switzerland_Protestant
3381 Gr_Turkey = _misc_.DateTime_Gr_Turkey
3382 Gr_USA = _misc_.DateTime_Gr_USA
3383 Gr_Wales = _misc_.DateTime_Gr_Wales
3384 Gr_Yugoslavia = _misc_.DateTime_Gr_Yugoslavia
3385 Country_Unknown = _misc_.DateTime_Country_Unknown
3386 Country_Default = _misc_.DateTime_Country_Default
3387 Country_WesternEurope_Start = _misc_.DateTime_Country_WesternEurope_Start
3388 Country_EEC = _misc_.DateTime_Country_EEC
3389 France = _misc_.DateTime_France
3390 Germany = _misc_.DateTime_Germany
3391 UK = _misc_.DateTime_UK
3392 Country_WesternEurope_End = _misc_.DateTime_Country_WesternEurope_End
3393 Russia = _misc_.DateTime_Russia
3394 USA = _misc_.DateTime_USA
3395 Jan = _misc_.DateTime_Jan
3396 Feb = _misc_.DateTime_Feb
3397 Mar = _misc_.DateTime_Mar
3398 Apr = _misc_.DateTime_Apr
3399 May = _misc_.DateTime_May
3400 Jun = _misc_.DateTime_Jun
3401 Jul = _misc_.DateTime_Jul
3402 Aug = _misc_.DateTime_Aug
3403 Sep = _misc_.DateTime_Sep
3404 Oct = _misc_.DateTime_Oct
3405 Nov = _misc_.DateTime_Nov
3406 Dec = _misc_.DateTime_Dec
3407 Inv_Month = _misc_.DateTime_Inv_Month
3408 Sun = _misc_.DateTime_Sun
3409 Mon = _misc_.DateTime_Mon
3410 Tue = _misc_.DateTime_Tue
3411 Wed = _misc_.DateTime_Wed
3412 Thu = _misc_.DateTime_Thu
3413 Fri = _misc_.DateTime_Fri
3414 Sat = _misc_.DateTime_Sat
3415 Inv_WeekDay = _misc_.DateTime_Inv_WeekDay
3416 Inv_Year = _misc_.DateTime_Inv_Year
3417 Name_Full = _misc_.DateTime_Name_Full
3418 Name_Abbr = _misc_.DateTime_Name_Abbr
3419 Default_First = _misc_.DateTime_Default_First
3420 Monday_First = _misc_.DateTime_Monday_First
3421 Sunday_First = _misc_.DateTime_Sunday_First
3422 def SetCountry(*args, **kwargs):
3423 """SetCountry(int country)"""
3424 return _misc_.DateTime_SetCountry(*args, **kwargs)
3425
3426 SetCountry = staticmethod(SetCountry)
3427 def GetCountry(*args, **kwargs):
3428 """GetCountry() -> int"""
3429 return _misc_.DateTime_GetCountry(*args, **kwargs)
3430
3431 GetCountry = staticmethod(GetCountry)
3432 def IsWestEuropeanCountry(*args, **kwargs):
3433 """IsWestEuropeanCountry(int country=Country_Default) -> bool"""
3434 return _misc_.DateTime_IsWestEuropeanCountry(*args, **kwargs)
3435
3436 IsWestEuropeanCountry = staticmethod(IsWestEuropeanCountry)
3437 def GetCurrentYear(*args, **kwargs):
3438 """GetCurrentYear(int cal=Gregorian) -> int"""
3439 return _misc_.DateTime_GetCurrentYear(*args, **kwargs)
3440
3441 GetCurrentYear = staticmethod(GetCurrentYear)
3442 def ConvertYearToBC(*args, **kwargs):
3443 """ConvertYearToBC(int year) -> int"""
3444 return _misc_.DateTime_ConvertYearToBC(*args, **kwargs)
3445
3446 ConvertYearToBC = staticmethod(ConvertYearToBC)
3447 def GetCurrentMonth(*args, **kwargs):
3448 """GetCurrentMonth(int cal=Gregorian) -> int"""
3449 return _misc_.DateTime_GetCurrentMonth(*args, **kwargs)
3450
3451 GetCurrentMonth = staticmethod(GetCurrentMonth)
3452 def IsLeapYear(*args, **kwargs):
3453 """IsLeapYear(int year=Inv_Year, int cal=Gregorian) -> bool"""
3454 return _misc_.DateTime_IsLeapYear(*args, **kwargs)
3455
3456 IsLeapYear = staticmethod(IsLeapYear)
3457 def GetCentury(*args, **kwargs):
3458 """GetCentury(int year=Inv_Year) -> int"""
3459 return _misc_.DateTime_GetCentury(*args, **kwargs)
3460
3461 GetCentury = staticmethod(GetCentury)
3462 def GetNumberOfDaysinYear(*args, **kwargs):
3463 """GetNumberOfDaysinYear(int year, int cal=Gregorian) -> int"""
3464 return _misc_.DateTime_GetNumberOfDaysinYear(*args, **kwargs)
3465
3466 GetNumberOfDaysinYear = staticmethod(GetNumberOfDaysinYear)
3467 def GetNumberOfDaysInMonth(*args, **kwargs):
3468 """GetNumberOfDaysInMonth(int month, int year=Inv_Year, int cal=Gregorian) -> int"""
3469 return _misc_.DateTime_GetNumberOfDaysInMonth(*args, **kwargs)
3470
3471 GetNumberOfDaysInMonth = staticmethod(GetNumberOfDaysInMonth)
3472 def GetMonthName(*args, **kwargs):
3473 """GetMonthName(int month, int flags=Name_Full) -> String"""
3474 return _misc_.DateTime_GetMonthName(*args, **kwargs)
3475
3476 GetMonthName = staticmethod(GetMonthName)
3477 def GetWeekDayName(*args, **kwargs):
3478 """GetWeekDayName(int weekday, int flags=Name_Full) -> String"""
3479 return _misc_.DateTime_GetWeekDayName(*args, **kwargs)
3480
3481 GetWeekDayName = staticmethod(GetWeekDayName)
3482 def GetAmPmStrings(*args, **kwargs):
3483 """
3484 GetAmPmStrings() -> (am, pm)
3485
3486 Get the AM and PM strings in the current locale (may be empty)
3487 """
3488 return _misc_.DateTime_GetAmPmStrings(*args, **kwargs)
3489
3490 GetAmPmStrings = staticmethod(GetAmPmStrings)
3491 def IsDSTApplicable(*args, **kwargs):
3492 """IsDSTApplicable(int year=Inv_Year, int country=Country_Default) -> bool"""
3493 return _misc_.DateTime_IsDSTApplicable(*args, **kwargs)
3494
3495 IsDSTApplicable = staticmethod(IsDSTApplicable)
3496 def GetBeginDST(*args, **kwargs):
3497 """GetBeginDST(int year=Inv_Year, int country=Country_Default) -> DateTime"""
3498 return _misc_.DateTime_GetBeginDST(*args, **kwargs)
3499
3500 GetBeginDST = staticmethod(GetBeginDST)
3501 def GetEndDST(*args, **kwargs):
3502 """GetEndDST(int year=Inv_Year, int country=Country_Default) -> DateTime"""
3503 return _misc_.DateTime_GetEndDST(*args, **kwargs)
3504
3505 GetEndDST = staticmethod(GetEndDST)
3506 def Now(*args, **kwargs):
3507 """Now() -> DateTime"""
3508 return _misc_.DateTime_Now(*args, **kwargs)
3509
3510 Now = staticmethod(Now)
3511 def UNow(*args, **kwargs):
3512 """UNow() -> DateTime"""
3513 return _misc_.DateTime_UNow(*args, **kwargs)
3514
3515 UNow = staticmethod(UNow)
3516 def Today(*args, **kwargs):
3517 """Today() -> DateTime"""
3518 return _misc_.DateTime_Today(*args, **kwargs)
3519
3520 Today = staticmethod(Today)
3521 def __init__(self, *args, **kwargs):
3522 """__init__(self) -> DateTime"""
3523 newobj = _misc_.new_DateTime(*args, **kwargs)
3524 self.this = newobj.this
3525 self.thisown = 1
3526 del newobj.thisown
3527 def __del__(self, destroy=_misc_.delete_DateTime):
3528 """__del__(self)"""
3529 try:
3530 if self.thisown: destroy(self)
3531 except: pass
3532
3533 def SetToCurrent(*args, **kwargs):
3534 """SetToCurrent(self) -> DateTime"""
3535 return _misc_.DateTime_SetToCurrent(*args, **kwargs)
3536
3537 def SetTimeT(*args, **kwargs):
3538 """SetTimeT(self, time_t timet) -> DateTime"""
3539 return _misc_.DateTime_SetTimeT(*args, **kwargs)
3540
3541 def SetJDN(*args, **kwargs):
3542 """SetJDN(self, double jdn) -> DateTime"""
3543 return _misc_.DateTime_SetJDN(*args, **kwargs)
3544
3545 def SetHMS(*args, **kwargs):
3546 """SetHMS(self, int hour, int minute=0, int second=0, int millisec=0) -> DateTime"""
3547 return _misc_.DateTime_SetHMS(*args, **kwargs)
3548
3549 def Set(*args, **kwargs):
3550 """
3551 Set(self, int day, int month=Inv_Month, int year=Inv_Year, int hour=0,
3552 int minute=0, int second=0, int millisec=0) -> DateTime
3553 """
3554 return _misc_.DateTime_Set(*args, **kwargs)
3555
3556 def ResetTime(*args, **kwargs):
3557 """ResetTime(self) -> DateTime"""
3558 return _misc_.DateTime_ResetTime(*args, **kwargs)
3559
3560 def SetYear(*args, **kwargs):
3561 """SetYear(self, int year) -> DateTime"""
3562 return _misc_.DateTime_SetYear(*args, **kwargs)
3563
3564 def SetMonth(*args, **kwargs):
3565 """SetMonth(self, int month) -> DateTime"""
3566 return _misc_.DateTime_SetMonth(*args, **kwargs)
3567
3568 def SetDay(*args, **kwargs):
3569 """SetDay(self, int day) -> DateTime"""
3570 return _misc_.DateTime_SetDay(*args, **kwargs)
3571
3572 def SetHour(*args, **kwargs):
3573 """SetHour(self, int hour) -> DateTime"""
3574 return _misc_.DateTime_SetHour(*args, **kwargs)
3575
3576 def SetMinute(*args, **kwargs):
3577 """SetMinute(self, int minute) -> DateTime"""
3578 return _misc_.DateTime_SetMinute(*args, **kwargs)
3579
3580 def SetSecond(*args, **kwargs):
3581 """SetSecond(self, int second) -> DateTime"""
3582 return _misc_.DateTime_SetSecond(*args, **kwargs)
3583
3584 def SetMillisecond(*args, **kwargs):
3585 """SetMillisecond(self, int millisecond) -> DateTime"""
3586 return _misc_.DateTime_SetMillisecond(*args, **kwargs)
3587
3588 def SetToWeekDayInSameWeek(*args, **kwargs):
3589 """SetToWeekDayInSameWeek(self, int weekday, int flags=Monday_First) -> DateTime"""
3590 return _misc_.DateTime_SetToWeekDayInSameWeek(*args, **kwargs)
3591
3592 def GetWeekDayInSameWeek(*args, **kwargs):
3593 """GetWeekDayInSameWeek(self, int weekday, int flags=Monday_First) -> DateTime"""
3594 return _misc_.DateTime_GetWeekDayInSameWeek(*args, **kwargs)
3595
3596 def SetToNextWeekDay(*args, **kwargs):
3597 """SetToNextWeekDay(self, int weekday) -> DateTime"""
3598 return _misc_.DateTime_SetToNextWeekDay(*args, **kwargs)
3599
3600 def GetNextWeekDay(*args, **kwargs):
3601 """GetNextWeekDay(self, int weekday) -> DateTime"""
3602 return _misc_.DateTime_GetNextWeekDay(*args, **kwargs)
3603
3604 def SetToPrevWeekDay(*args, **kwargs):
3605 """SetToPrevWeekDay(self, int weekday) -> DateTime"""
3606 return _misc_.DateTime_SetToPrevWeekDay(*args, **kwargs)
3607
3608 def GetPrevWeekDay(*args, **kwargs):
3609 """GetPrevWeekDay(self, int weekday) -> DateTime"""
3610 return _misc_.DateTime_GetPrevWeekDay(*args, **kwargs)
3611
3612 def SetToWeekDay(*args, **kwargs):
3613 """SetToWeekDay(self, int weekday, int n=1, int month=Inv_Month, int year=Inv_Year) -> bool"""
3614 return _misc_.DateTime_SetToWeekDay(*args, **kwargs)
3615
3616 def SetToLastWeekDay(*args, **kwargs):
3617 """SetToLastWeekDay(self, int weekday, int month=Inv_Month, int year=Inv_Year) -> bool"""
3618 return _misc_.DateTime_SetToLastWeekDay(*args, **kwargs)
3619
3620 def GetLastWeekDay(*args, **kwargs):
3621 """GetLastWeekDay(self, int weekday, int month=Inv_Month, int year=Inv_Year) -> DateTime"""
3622 return _misc_.DateTime_GetLastWeekDay(*args, **kwargs)
3623
3624 def SetToTheWeek(*args, **kwargs):
3625 """SetToTheWeek(self, int numWeek, int weekday=Mon, int flags=Monday_First) -> bool"""
3626 return _misc_.DateTime_SetToTheWeek(*args, **kwargs)
3627
3628 def GetWeek(*args, **kwargs):
3629 """GetWeek(self, int numWeek, int weekday=Mon, int flags=Monday_First) -> DateTime"""
3630 return _misc_.DateTime_GetWeek(*args, **kwargs)
3631
3632 SetToTheWeek = wx._deprecated(SetToTheWeek, "SetToTheWeek is deprecated, use (static) SetToWeekOfYear instead")
3633 GetWeek = wx._deprecated(GetWeek, "GetWeek is deprecated, use GetWeekOfYear instead")
3634
3635 def SetToWeekOfYear(*args, **kwargs):
3636 """SetToWeekOfYear(int year, int numWeek, int weekday=Mon) -> DateTime"""
3637 return _misc_.DateTime_SetToWeekOfYear(*args, **kwargs)
3638
3639 SetToWeekOfYear = staticmethod(SetToWeekOfYear)
3640 def SetToLastMonthDay(*args, **kwargs):
3641 """SetToLastMonthDay(self, int month=Inv_Month, int year=Inv_Year) -> DateTime"""
3642 return _misc_.DateTime_SetToLastMonthDay(*args, **kwargs)
3643
3644 def GetLastMonthDay(*args, **kwargs):
3645 """GetLastMonthDay(self, int month=Inv_Month, int year=Inv_Year) -> DateTime"""
3646 return _misc_.DateTime_GetLastMonthDay(*args, **kwargs)
3647
3648 def SetToYearDay(*args, **kwargs):
3649 """SetToYearDay(self, int yday) -> DateTime"""
3650 return _misc_.DateTime_SetToYearDay(*args, **kwargs)
3651
3652 def GetYearDay(*args, **kwargs):
3653 """GetYearDay(self, int yday) -> DateTime"""
3654 return _misc_.DateTime_GetYearDay(*args, **kwargs)
3655
3656 def GetJulianDayNumber(*args, **kwargs):
3657 """GetJulianDayNumber(self) -> double"""
3658 return _misc_.DateTime_GetJulianDayNumber(*args, **kwargs)
3659
3660 def GetJDN(*args, **kwargs):
3661 """GetJDN(self) -> double"""
3662 return _misc_.DateTime_GetJDN(*args, **kwargs)
3663
3664 def GetModifiedJulianDayNumber(*args, **kwargs):
3665 """GetModifiedJulianDayNumber(self) -> double"""
3666 return _misc_.DateTime_GetModifiedJulianDayNumber(*args, **kwargs)
3667
3668 def GetMJD(*args, **kwargs):
3669 """GetMJD(self) -> double"""
3670 return _misc_.DateTime_GetMJD(*args, **kwargs)
3671
3672 def GetRataDie(*args, **kwargs):
3673 """GetRataDie(self) -> double"""
3674 return _misc_.DateTime_GetRataDie(*args, **kwargs)
3675
3676 def ToTimezone(*args, **kwargs):
3677 """ToTimezone(self, wxDateTime::TimeZone tz, bool noDST=False) -> DateTime"""
3678 return _misc_.DateTime_ToTimezone(*args, **kwargs)
3679
3680 def MakeTimezone(*args, **kwargs):
3681 """MakeTimezone(self, wxDateTime::TimeZone tz, bool noDST=False) -> DateTime"""
3682 return _misc_.DateTime_MakeTimezone(*args, **kwargs)
3683
3684 def ToGMT(*args, **kwargs):
3685 """ToGMT(self, bool noDST=False) -> DateTime"""
3686 return _misc_.DateTime_ToGMT(*args, **kwargs)
3687
3688 def MakeGMT(*args, **kwargs):
3689 """MakeGMT(self, bool noDST=False) -> DateTime"""
3690 return _misc_.DateTime_MakeGMT(*args, **kwargs)
3691
3692 def IsDST(*args, **kwargs):
3693 """IsDST(self, int country=Country_Default) -> int"""
3694 return _misc_.DateTime_IsDST(*args, **kwargs)
3695
3696 def IsValid(*args, **kwargs):
3697 """IsValid(self) -> bool"""
3698 return _misc_.DateTime_IsValid(*args, **kwargs)
3699
3700 Ok = IsValid
3701 def __nonzero__(self): return self.Ok()
3702 def GetTicks(*args, **kwargs):
3703 """GetTicks(self) -> time_t"""
3704 return _misc_.DateTime_GetTicks(*args, **kwargs)
3705
3706 def GetYear(*args, **kwargs):
3707 """GetYear(self, wxDateTime::TimeZone tz=LOCAL_TZ) -> int"""
3708 return _misc_.DateTime_GetYear(*args, **kwargs)
3709
3710 def GetMonth(*args, **kwargs):
3711 """GetMonth(self, wxDateTime::TimeZone tz=LOCAL_TZ) -> int"""
3712 return _misc_.DateTime_GetMonth(*args, **kwargs)
3713
3714 def GetDay(*args, **kwargs):
3715 """GetDay(self, wxDateTime::TimeZone tz=LOCAL_TZ) -> int"""
3716 return _misc_.DateTime_GetDay(*args, **kwargs)
3717
3718 def GetWeekDay(*args, **kwargs):
3719 """GetWeekDay(self, wxDateTime::TimeZone tz=LOCAL_TZ) -> int"""
3720 return _misc_.DateTime_GetWeekDay(*args, **kwargs)
3721
3722 def GetHour(*args, **kwargs):
3723 """GetHour(self, wxDateTime::TimeZone tz=LOCAL_TZ) -> int"""
3724 return _misc_.DateTime_GetHour(*args, **kwargs)
3725
3726 def GetMinute(*args, **kwargs):
3727 """GetMinute(self, wxDateTime::TimeZone tz=LOCAL_TZ) -> int"""
3728 return _misc_.DateTime_GetMinute(*args, **kwargs)
3729
3730 def GetSecond(*args, **kwargs):
3731 """GetSecond(self, wxDateTime::TimeZone tz=LOCAL_TZ) -> int"""
3732 return _misc_.DateTime_GetSecond(*args, **kwargs)
3733
3734 def GetMillisecond(*args, **kwargs):
3735 """GetMillisecond(self, wxDateTime::TimeZone tz=LOCAL_TZ) -> int"""
3736 return _misc_.DateTime_GetMillisecond(*args, **kwargs)
3737
3738 def GetDayOfYear(*args, **kwargs):
3739 """GetDayOfYear(self, wxDateTime::TimeZone tz=LOCAL_TZ) -> int"""
3740 return _misc_.DateTime_GetDayOfYear(*args, **kwargs)
3741
3742 def GetWeekOfYear(*args, **kwargs):
3743 """GetWeekOfYear(self, int flags=Monday_First, wxDateTime::TimeZone tz=LOCAL_TZ) -> int"""
3744 return _misc_.DateTime_GetWeekOfYear(*args, **kwargs)
3745
3746 def GetWeekOfMonth(*args, **kwargs):
3747 """GetWeekOfMonth(self, int flags=Monday_First, wxDateTime::TimeZone tz=LOCAL_TZ) -> int"""
3748 return _misc_.DateTime_GetWeekOfMonth(*args, **kwargs)
3749
3750 def IsWorkDay(*args, **kwargs):
3751 """IsWorkDay(self, int country=Country_Default) -> bool"""
3752 return _misc_.DateTime_IsWorkDay(*args, **kwargs)
3753
3754 def IsEqualTo(*args, **kwargs):
3755 """IsEqualTo(self, DateTime datetime) -> bool"""
3756 return _misc_.DateTime_IsEqualTo(*args, **kwargs)
3757
3758 def IsEarlierThan(*args, **kwargs):
3759 """IsEarlierThan(self, DateTime datetime) -> bool"""
3760 return _misc_.DateTime_IsEarlierThan(*args, **kwargs)
3761
3762 def IsLaterThan(*args, **kwargs):
3763 """IsLaterThan(self, DateTime datetime) -> bool"""
3764 return _misc_.DateTime_IsLaterThan(*args, **kwargs)
3765
3766 def IsStrictlyBetween(*args, **kwargs):
3767 """IsStrictlyBetween(self, DateTime t1, DateTime t2) -> bool"""
3768 return _misc_.DateTime_IsStrictlyBetween(*args, **kwargs)
3769
3770 def IsBetween(*args, **kwargs):
3771 """IsBetween(self, DateTime t1, DateTime t2) -> bool"""
3772 return _misc_.DateTime_IsBetween(*args, **kwargs)
3773
3774 def IsSameDate(*args, **kwargs):
3775 """IsSameDate(self, DateTime dt) -> bool"""
3776 return _misc_.DateTime_IsSameDate(*args, **kwargs)
3777
3778 def IsSameTime(*args, **kwargs):
3779 """IsSameTime(self, DateTime dt) -> bool"""
3780 return _misc_.DateTime_IsSameTime(*args, **kwargs)
3781
3782 def IsEqualUpTo(*args, **kwargs):
3783 """IsEqualUpTo(self, DateTime dt, TimeSpan ts) -> bool"""
3784 return _misc_.DateTime_IsEqualUpTo(*args, **kwargs)
3785
3786 def AddTS(*args, **kwargs):
3787 """AddTS(self, TimeSpan diff) -> DateTime"""
3788 return _misc_.DateTime_AddTS(*args, **kwargs)
3789
3790 def AddDS(*args, **kwargs):
3791 """AddDS(self, DateSpan diff) -> DateTime"""
3792 return _misc_.DateTime_AddDS(*args, **kwargs)
3793
3794 def SubtractTS(*args, **kwargs):
3795 """SubtractTS(self, TimeSpan diff) -> DateTime"""
3796 return _misc_.DateTime_SubtractTS(*args, **kwargs)
3797
3798 def SubtractDS(*args, **kwargs):
3799 """SubtractDS(self, DateSpan diff) -> DateTime"""
3800 return _misc_.DateTime_SubtractDS(*args, **kwargs)
3801
3802 def Subtract(*args, **kwargs):
3803 """Subtract(self, DateTime dt) -> TimeSpan"""
3804 return _misc_.DateTime_Subtract(*args, **kwargs)
3805
3806 def __iadd__(*args):
3807 """
3808 __iadd__(self, TimeSpan diff) -> DateTime
3809 __iadd__(self, DateSpan diff) -> DateTime
3810 """
3811 return _misc_.DateTime___iadd__(*args)
3812
3813 def __isub__(*args):
3814 """
3815 __isub__(self, TimeSpan diff) -> DateTime
3816 __isub__(self, DateSpan diff) -> DateTime
3817 """
3818 return _misc_.DateTime___isub__(*args)
3819
3820 def __add__(*args):
3821 """
3822 __add__(self, TimeSpan other) -> DateTime
3823 __add__(self, DateSpan other) -> DateTime
3824 """
3825 return _misc_.DateTime___add__(*args)
3826
3827 def __sub__(*args):
3828 """
3829 __sub__(self, DateTime other) -> TimeSpan
3830 __sub__(self, TimeSpan other) -> DateTime
3831 __sub__(self, DateSpan other) -> DateTime
3832 """
3833 return _misc_.DateTime___sub__(*args)
3834
3835 def __lt__(*args, **kwargs):
3836 """__lt__(self, DateTime other) -> bool"""
3837 return _misc_.DateTime___lt__(*args, **kwargs)
3838
3839 def __le__(*args, **kwargs):
3840 """__le__(self, DateTime other) -> bool"""
3841 return _misc_.DateTime___le__(*args, **kwargs)
3842
3843 def __gt__(*args, **kwargs):
3844 """__gt__(self, DateTime other) -> bool"""
3845 return _misc_.DateTime___gt__(*args, **kwargs)
3846
3847 def __ge__(*args, **kwargs):
3848 """__ge__(self, DateTime other) -> bool"""
3849 return _misc_.DateTime___ge__(*args, **kwargs)
3850
3851 def __eq__(*args, **kwargs):
3852 """__eq__(self, DateTime other) -> bool"""
3853 return _misc_.DateTime___eq__(*args, **kwargs)
3854
3855 def __ne__(*args, **kwargs):
3856 """__ne__(self, DateTime other) -> bool"""
3857 return _misc_.DateTime___ne__(*args, **kwargs)
3858
3859 def ParseRfc822Date(*args, **kwargs):
3860 """ParseRfc822Date(self, String date) -> int"""
3861 return _misc_.DateTime_ParseRfc822Date(*args, **kwargs)
3862
3863 def ParseFormat(*args, **kwargs):
3864 """ParseFormat(self, String date, String format=DefaultDateTimeFormat, DateTime dateDef=DefaultDateTime) -> int"""
3865 return _misc_.DateTime_ParseFormat(*args, **kwargs)
3866
3867 def ParseDateTime(*args, **kwargs):
3868 """ParseDateTime(self, String datetime) -> int"""
3869 return _misc_.DateTime_ParseDateTime(*args, **kwargs)
3870
3871 def ParseDate(*args, **kwargs):
3872 """ParseDate(self, String date) -> int"""
3873 return _misc_.DateTime_ParseDate(*args, **kwargs)
3874
3875 def ParseTime(*args, **kwargs):
3876 """ParseTime(self, String time) -> int"""
3877 return _misc_.DateTime_ParseTime(*args, **kwargs)
3878
3879 def Format(*args, **kwargs):
3880 """Format(self, String format=DefaultDateTimeFormat, wxDateTime::TimeZone tz=LOCAL_TZ) -> String"""
3881 return _misc_.DateTime_Format(*args, **kwargs)
3882
3883 def FormatDate(*args, **kwargs):
3884 """FormatDate(self) -> String"""
3885 return _misc_.DateTime_FormatDate(*args, **kwargs)
3886
3887 def FormatTime(*args, **kwargs):
3888 """FormatTime(self) -> String"""
3889 return _misc_.DateTime_FormatTime(*args, **kwargs)
3890
3891 def FormatISODate(*args, **kwargs):
3892 """FormatISODate(self) -> String"""
3893 return _misc_.DateTime_FormatISODate(*args, **kwargs)
3894
3895 def FormatISOTime(*args, **kwargs):
3896 """FormatISOTime(self) -> String"""
3897 return _misc_.DateTime_FormatISOTime(*args, **kwargs)
3898
3899 def __repr__(self):
3900 if self.IsValid():
3901 f = self.Format().encode(wx.GetDefaultPyEncoding())
3902 return '<wx.DateTime: \"%s\" at %s>' % ( f, self.this)
3903 else:
3904 return '<wx.DateTime: \"INVALID\" at %s>' % self.this
3905 def __str__(self):
3906 if self.IsValid():
3907 return self.Format().encode(wx.GetDefaultPyEncoding())
3908 else:
3909 return "INVALID DateTime"
3910
3911
3912 class DateTimePtr(DateTime):
3913 def __init__(self, this):
3914 self.this = this
3915 if not hasattr(self,"thisown"): self.thisown = 0
3916 self.__class__ = DateTime
3917 _misc_.DateTime_swigregister(DateTimePtr)
3918 DefaultDateTimeFormat = cvar.DefaultDateTimeFormat
3919 DefaultTimeSpanFormat = cvar.DefaultTimeSpanFormat
3920
3921 def DateTime_SetCountry(*args, **kwargs):
3922 """DateTime_SetCountry(int country)"""
3923 return _misc_.DateTime_SetCountry(*args, **kwargs)
3924
3925 def DateTime_GetCountry(*args, **kwargs):
3926 """DateTime_GetCountry() -> int"""
3927 return _misc_.DateTime_GetCountry(*args, **kwargs)
3928
3929 def DateTime_IsWestEuropeanCountry(*args, **kwargs):
3930 """DateTime_IsWestEuropeanCountry(int country=Country_Default) -> bool"""
3931 return _misc_.DateTime_IsWestEuropeanCountry(*args, **kwargs)
3932
3933 def DateTime_GetCurrentYear(*args, **kwargs):
3934 """DateTime_GetCurrentYear(int cal=Gregorian) -> int"""
3935 return _misc_.DateTime_GetCurrentYear(*args, **kwargs)
3936
3937 def DateTime_ConvertYearToBC(*args, **kwargs):
3938 """DateTime_ConvertYearToBC(int year) -> int"""
3939 return _misc_.DateTime_ConvertYearToBC(*args, **kwargs)
3940
3941 def DateTime_GetCurrentMonth(*args, **kwargs):
3942 """DateTime_GetCurrentMonth(int cal=Gregorian) -> int"""
3943 return _misc_.DateTime_GetCurrentMonth(*args, **kwargs)
3944
3945 def DateTime_IsLeapYear(*args, **kwargs):
3946 """DateTime_IsLeapYear(int year=Inv_Year, int cal=Gregorian) -> bool"""
3947 return _misc_.DateTime_IsLeapYear(*args, **kwargs)
3948
3949 def DateTime_GetCentury(*args, **kwargs):
3950 """DateTime_GetCentury(int year=Inv_Year) -> int"""
3951 return _misc_.DateTime_GetCentury(*args, **kwargs)
3952
3953 def DateTime_GetNumberOfDaysinYear(*args, **kwargs):
3954 """DateTime_GetNumberOfDaysinYear(int year, int cal=Gregorian) -> int"""
3955 return _misc_.DateTime_GetNumberOfDaysinYear(*args, **kwargs)
3956
3957 def DateTime_GetNumberOfDaysInMonth(*args, **kwargs):
3958 """DateTime_GetNumberOfDaysInMonth(int month, int year=Inv_Year, int cal=Gregorian) -> int"""
3959 return _misc_.DateTime_GetNumberOfDaysInMonth(*args, **kwargs)
3960
3961 def DateTime_GetMonthName(*args, **kwargs):
3962 """DateTime_GetMonthName(int month, int flags=Name_Full) -> String"""
3963 return _misc_.DateTime_GetMonthName(*args, **kwargs)
3964
3965 def DateTime_GetWeekDayName(*args, **kwargs):
3966 """DateTime_GetWeekDayName(int weekday, int flags=Name_Full) -> String"""
3967 return _misc_.DateTime_GetWeekDayName(*args, **kwargs)
3968
3969 def DateTime_GetAmPmStrings(*args, **kwargs):
3970 """
3971 GetAmPmStrings() -> (am, pm)
3972
3973 Get the AM and PM strings in the current locale (may be empty)
3974 """
3975 return _misc_.DateTime_GetAmPmStrings(*args, **kwargs)
3976
3977 def DateTime_IsDSTApplicable(*args, **kwargs):
3978 """DateTime_IsDSTApplicable(int year=Inv_Year, int country=Country_Default) -> bool"""
3979 return _misc_.DateTime_IsDSTApplicable(*args, **kwargs)
3980
3981 def DateTime_GetBeginDST(*args, **kwargs):
3982 """DateTime_GetBeginDST(int year=Inv_Year, int country=Country_Default) -> DateTime"""
3983 return _misc_.DateTime_GetBeginDST(*args, **kwargs)
3984
3985 def DateTime_GetEndDST(*args, **kwargs):
3986 """DateTime_GetEndDST(int year=Inv_Year, int country=Country_Default) -> DateTime"""
3987 return _misc_.DateTime_GetEndDST(*args, **kwargs)
3988
3989 def DateTime_Now(*args, **kwargs):
3990 """DateTime_Now() -> DateTime"""
3991 return _misc_.DateTime_Now(*args, **kwargs)
3992
3993 def DateTime_UNow(*args, **kwargs):
3994 """DateTime_UNow() -> DateTime"""
3995 return _misc_.DateTime_UNow(*args, **kwargs)
3996
3997 def DateTime_Today(*args, **kwargs):
3998 """DateTime_Today() -> DateTime"""
3999 return _misc_.DateTime_Today(*args, **kwargs)
4000
4001 def DateTimeFromTimeT(*args, **kwargs):
4002 """DateTimeFromTimeT(time_t timet) -> DateTime"""
4003 val = _misc_.new_DateTimeFromTimeT(*args, **kwargs)
4004 val.thisown = 1
4005 return val
4006
4007 def DateTimeFromJDN(*args, **kwargs):
4008 """DateTimeFromJDN(double jdn) -> DateTime"""
4009 val = _misc_.new_DateTimeFromJDN(*args, **kwargs)
4010 val.thisown = 1
4011 return val
4012
4013 def DateTimeFromHMS(*args, **kwargs):
4014 """DateTimeFromHMS(int hour, int minute=0, int second=0, int millisec=0) -> DateTime"""
4015 val = _misc_.new_DateTimeFromHMS(*args, **kwargs)
4016 val.thisown = 1
4017 return val
4018
4019 def DateTimeFromDMY(*args, **kwargs):
4020 """
4021 DateTimeFromDMY(int day, int month=Inv_Month, int year=Inv_Year, int hour=0,
4022 int minute=0, int second=0, int millisec=0) -> DateTime
4023 """
4024 val = _misc_.new_DateTimeFromDMY(*args, **kwargs)
4025 val.thisown = 1
4026 return val
4027
4028 def DateTime_SetToWeekOfYear(*args, **kwargs):
4029 """DateTime_SetToWeekOfYear(int year, int numWeek, int weekday=Mon) -> DateTime"""
4030 return _misc_.DateTime_SetToWeekOfYear(*args, **kwargs)
4031
4032 class TimeSpan(object):
4033 """Proxy of C++ TimeSpan class"""
4034 def __repr__(self):
4035 return "<%s.%s; proxy of C++ wxTimeSpan instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
4036 def Seconds(*args, **kwargs):
4037 """Seconds(long sec) -> TimeSpan"""
4038 return _misc_.TimeSpan_Seconds(*args, **kwargs)
4039
4040 Seconds = staticmethod(Seconds)
4041 def Second(*args, **kwargs):
4042 """Second() -> TimeSpan"""
4043 return _misc_.TimeSpan_Second(*args, **kwargs)
4044
4045 Second = staticmethod(Second)
4046 def Minutes(*args, **kwargs):
4047 """Minutes(long min) -> TimeSpan"""
4048 return _misc_.TimeSpan_Minutes(*args, **kwargs)
4049
4050 Minutes = staticmethod(Minutes)
4051 def Minute(*args, **kwargs):
4052 """Minute() -> TimeSpan"""
4053 return _misc_.TimeSpan_Minute(*args, **kwargs)
4054
4055 Minute = staticmethod(Minute)
4056 def Hours(*args, **kwargs):
4057 """Hours(long hours) -> TimeSpan"""
4058 return _misc_.TimeSpan_Hours(*args, **kwargs)
4059
4060 Hours = staticmethod(Hours)
4061 def Hour(*args, **kwargs):
4062 """Hour() -> TimeSpan"""
4063 return _misc_.TimeSpan_Hour(*args, **kwargs)
4064
4065 Hour = staticmethod(Hour)
4066 def Days(*args, **kwargs):
4067 """Days(long days) -> TimeSpan"""
4068 return _misc_.TimeSpan_Days(*args, **kwargs)
4069
4070 Days = staticmethod(Days)
4071 def Day(*args, **kwargs):
4072 """Day() -> TimeSpan"""
4073 return _misc_.TimeSpan_Day(*args, **kwargs)
4074
4075 Day = staticmethod(Day)
4076 def Weeks(*args, **kwargs):
4077 """Weeks(long days) -> TimeSpan"""
4078 return _misc_.TimeSpan_Weeks(*args, **kwargs)
4079
4080 Weeks = staticmethod(Weeks)
4081 def Week(*args, **kwargs):
4082 """Week() -> TimeSpan"""
4083 return _misc_.TimeSpan_Week(*args, **kwargs)
4084
4085 Week = staticmethod(Week)
4086 def __init__(self, *args, **kwargs):
4087 """__init__(self, long hours=0, long minutes=0, long seconds=0, long milliseconds=0) -> TimeSpan"""
4088 newobj = _misc_.new_TimeSpan(*args, **kwargs)
4089 self.this = newobj.this
4090 self.thisown = 1
4091 del newobj.thisown
4092 def __del__(self, destroy=_misc_.delete_TimeSpan):
4093 """__del__(self)"""
4094 try:
4095 if self.thisown: destroy(self)
4096 except: pass
4097
4098 def Add(*args, **kwargs):
4099 """Add(self, TimeSpan diff) -> TimeSpan"""
4100 return _misc_.TimeSpan_Add(*args, **kwargs)
4101
4102 def Subtract(*args, **kwargs):
4103 """Subtract(self, TimeSpan diff) -> TimeSpan"""
4104 return _misc_.TimeSpan_Subtract(*args, **kwargs)
4105
4106 def Multiply(*args, **kwargs):
4107 """Multiply(self, int n) -> TimeSpan"""
4108 return _misc_.TimeSpan_Multiply(*args, **kwargs)
4109
4110 def Neg(*args, **kwargs):
4111 """Neg(self) -> TimeSpan"""
4112 return _misc_.TimeSpan_Neg(*args, **kwargs)
4113
4114 def Abs(*args, **kwargs):
4115 """Abs(self) -> TimeSpan"""
4116 return _misc_.TimeSpan_Abs(*args, **kwargs)
4117
4118 def __iadd__(*args, **kwargs):
4119 """__iadd__(self, TimeSpan diff) -> TimeSpan"""
4120 return _misc_.TimeSpan___iadd__(*args, **kwargs)
4121
4122 def __isub__(*args, **kwargs):
4123 """__isub__(self, TimeSpan diff) -> TimeSpan"""
4124 return _misc_.TimeSpan___isub__(*args, **kwargs)
4125
4126 def __imul__(*args, **kwargs):
4127 """__imul__(self, int n) -> TimeSpan"""
4128 return _misc_.TimeSpan___imul__(*args, **kwargs)
4129
4130 def __neg__(*args, **kwargs):
4131 """__neg__(self) -> TimeSpan"""
4132 return _misc_.TimeSpan___neg__(*args, **kwargs)
4133
4134 def __add__(*args, **kwargs):
4135 """__add__(self, TimeSpan other) -> TimeSpan"""
4136 return _misc_.TimeSpan___add__(*args, **kwargs)
4137
4138 def __sub__(*args, **kwargs):
4139 """__sub__(self, TimeSpan other) -> TimeSpan"""
4140 return _misc_.TimeSpan___sub__(*args, **kwargs)
4141
4142 def __mul__(*args, **kwargs):
4143 """__mul__(self, int n) -> TimeSpan"""
4144 return _misc_.TimeSpan___mul__(*args, **kwargs)
4145
4146 def __rmul__(*args, **kwargs):
4147 """__rmul__(self, int n) -> TimeSpan"""
4148 return _misc_.TimeSpan___rmul__(*args, **kwargs)
4149
4150 def __lt__(*args, **kwargs):
4151 """__lt__(self, TimeSpan other) -> bool"""
4152 return _misc_.TimeSpan___lt__(*args, **kwargs)
4153
4154 def __le__(*args, **kwargs):
4155 """__le__(self, TimeSpan other) -> bool"""
4156 return _misc_.TimeSpan___le__(*args, **kwargs)
4157
4158 def __gt__(*args, **kwargs):
4159 """__gt__(self, TimeSpan other) -> bool"""
4160 return _misc_.TimeSpan___gt__(*args, **kwargs)
4161
4162 def __ge__(*args, **kwargs):
4163 """__ge__(self, TimeSpan other) -> bool"""
4164 return _misc_.TimeSpan___ge__(*args, **kwargs)
4165
4166 def __eq__(*args, **kwargs):
4167 """__eq__(self, TimeSpan other) -> bool"""
4168 return _misc_.TimeSpan___eq__(*args, **kwargs)
4169
4170 def __ne__(*args, **kwargs):
4171 """__ne__(self, TimeSpan other) -> bool"""
4172 return _misc_.TimeSpan___ne__(*args, **kwargs)
4173
4174 def IsNull(*args, **kwargs):
4175 """IsNull(self) -> bool"""
4176 return _misc_.TimeSpan_IsNull(*args, **kwargs)
4177
4178 def IsPositive(*args, **kwargs):
4179 """IsPositive(self) -> bool"""
4180 return _misc_.TimeSpan_IsPositive(*args, **kwargs)
4181
4182 def IsNegative(*args, **kwargs):
4183 """IsNegative(self) -> bool"""
4184 return _misc_.TimeSpan_IsNegative(*args, **kwargs)
4185
4186 def IsEqualTo(*args, **kwargs):
4187 """IsEqualTo(self, TimeSpan ts) -> bool"""
4188 return _misc_.TimeSpan_IsEqualTo(*args, **kwargs)
4189
4190 def IsLongerThan(*args, **kwargs):
4191 """IsLongerThan(self, TimeSpan ts) -> bool"""
4192 return _misc_.TimeSpan_IsLongerThan(*args, **kwargs)
4193
4194 def IsShorterThan(*args, **kwargs):
4195 """IsShorterThan(self, TimeSpan t) -> bool"""
4196 return _misc_.TimeSpan_IsShorterThan(*args, **kwargs)
4197
4198 def GetWeeks(*args, **kwargs):
4199 """GetWeeks(self) -> int"""
4200 return _misc_.TimeSpan_GetWeeks(*args, **kwargs)
4201
4202 def GetDays(*args, **kwargs):
4203 """GetDays(self) -> int"""
4204 return _misc_.TimeSpan_GetDays(*args, **kwargs)
4205
4206 def GetHours(*args, **kwargs):
4207 """GetHours(self) -> int"""
4208 return _misc_.TimeSpan_GetHours(*args, **kwargs)
4209
4210 def GetMinutes(*args, **kwargs):
4211 """GetMinutes(self) -> int"""
4212 return _misc_.TimeSpan_GetMinutes(*args, **kwargs)
4213
4214 def GetSeconds(*args, **kwargs):
4215 """GetSeconds(self) -> wxLongLong"""
4216 return _misc_.TimeSpan_GetSeconds(*args, **kwargs)
4217
4218 def GetMilliseconds(*args, **kwargs):
4219 """GetMilliseconds(self) -> wxLongLong"""
4220 return _misc_.TimeSpan_GetMilliseconds(*args, **kwargs)
4221
4222 def Format(*args, **kwargs):
4223 """Format(self, String format=DefaultTimeSpanFormat) -> String"""
4224 return _misc_.TimeSpan_Format(*args, **kwargs)
4225
4226 def __repr__(self):
4227 f = self.Format().encode(wx.GetDefaultPyEncoding())
4228 return '<wx.TimeSpan: \"%s\" at %s>' % ( f, self.this)
4229 def __str__(self):
4230 return self.Format().encode(wx.GetDefaultPyEncoding())
4231
4232
4233 class TimeSpanPtr(TimeSpan):
4234 def __init__(self, this):
4235 self.this = this
4236 if not hasattr(self,"thisown"): self.thisown = 0
4237 self.__class__ = TimeSpan
4238 _misc_.TimeSpan_swigregister(TimeSpanPtr)
4239
4240 def TimeSpan_Seconds(*args, **kwargs):
4241 """TimeSpan_Seconds(long sec) -> TimeSpan"""
4242 return _misc_.TimeSpan_Seconds(*args, **kwargs)
4243
4244 def TimeSpan_Second(*args, **kwargs):
4245 """TimeSpan_Second() -> TimeSpan"""
4246 return _misc_.TimeSpan_Second(*args, **kwargs)
4247
4248 def TimeSpan_Minutes(*args, **kwargs):
4249 """TimeSpan_Minutes(long min) -> TimeSpan"""
4250 return _misc_.TimeSpan_Minutes(*args, **kwargs)
4251
4252 def TimeSpan_Minute(*args, **kwargs):
4253 """TimeSpan_Minute() -> TimeSpan"""
4254 return _misc_.TimeSpan_Minute(*args, **kwargs)
4255
4256 def TimeSpan_Hours(*args, **kwargs):
4257 """TimeSpan_Hours(long hours) -> TimeSpan"""
4258 return _misc_.TimeSpan_Hours(*args, **kwargs)
4259
4260 def TimeSpan_Hour(*args, **kwargs):
4261 """TimeSpan_Hour() -> TimeSpan"""
4262 return _misc_.TimeSpan_Hour(*args, **kwargs)
4263
4264 def TimeSpan_Days(*args, **kwargs):
4265 """TimeSpan_Days(long days) -> TimeSpan"""
4266 return _misc_.TimeSpan_Days(*args, **kwargs)
4267
4268 def TimeSpan_Day(*args, **kwargs):
4269 """TimeSpan_Day() -> TimeSpan"""
4270 return _misc_.TimeSpan_Day(*args, **kwargs)
4271
4272 def TimeSpan_Weeks(*args, **kwargs):
4273 """TimeSpan_Weeks(long days) -> TimeSpan"""
4274 return _misc_.TimeSpan_Weeks(*args, **kwargs)
4275
4276 def TimeSpan_Week(*args, **kwargs):
4277 """TimeSpan_Week() -> TimeSpan"""
4278 return _misc_.TimeSpan_Week(*args, **kwargs)
4279
4280 class DateSpan(object):
4281 """Proxy of C++ DateSpan class"""
4282 def __repr__(self):
4283 return "<%s.%s; proxy of C++ wxDateSpan instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
4284 def __init__(self, *args, **kwargs):
4285 """__init__(self, int years=0, int months=0, int weeks=0, int days=0) -> DateSpan"""
4286 newobj = _misc_.new_DateSpan(*args, **kwargs)
4287 self.this = newobj.this
4288 self.thisown = 1
4289 del newobj.thisown
4290 def __del__(self, destroy=_misc_.delete_DateSpan):
4291 """__del__(self)"""
4292 try:
4293 if self.thisown: destroy(self)
4294 except: pass
4295
4296 def Days(*args, **kwargs):
4297 """Days(int days) -> DateSpan"""
4298 return _misc_.DateSpan_Days(*args, **kwargs)
4299
4300 Days = staticmethod(Days)
4301 def Day(*args, **kwargs):
4302 """Day() -> DateSpan"""
4303 return _misc_.DateSpan_Day(*args, **kwargs)
4304
4305 Day = staticmethod(Day)
4306 def Weeks(*args, **kwargs):
4307 """Weeks(int weeks) -> DateSpan"""
4308 return _misc_.DateSpan_Weeks(*args, **kwargs)
4309
4310 Weeks = staticmethod(Weeks)
4311 def Week(*args, **kwargs):
4312 """Week() -> DateSpan"""
4313 return _misc_.DateSpan_Week(*args, **kwargs)
4314
4315 Week = staticmethod(Week)
4316 def Months(*args, **kwargs):
4317 """Months(int mon) -> DateSpan"""
4318 return _misc_.DateSpan_Months(*args, **kwargs)
4319
4320 Months = staticmethod(Months)
4321 def Month(*args, **kwargs):
4322 """Month() -> DateSpan"""
4323 return _misc_.DateSpan_Month(*args, **kwargs)
4324
4325 Month = staticmethod(Month)
4326 def Years(*args, **kwargs):
4327 """Years(int years) -> DateSpan"""
4328 return _misc_.DateSpan_Years(*args, **kwargs)
4329
4330 Years = staticmethod(Years)
4331 def Year(*args, **kwargs):
4332 """Year() -> DateSpan"""
4333 return _misc_.DateSpan_Year(*args, **kwargs)
4334
4335 Year = staticmethod(Year)
4336 def SetYears(*args, **kwargs):
4337 """SetYears(self, int n) -> DateSpan"""
4338 return _misc_.DateSpan_SetYears(*args, **kwargs)
4339
4340 def SetMonths(*args, **kwargs):
4341 """SetMonths(self, int n) -> DateSpan"""
4342 return _misc_.DateSpan_SetMonths(*args, **kwargs)
4343
4344 def SetWeeks(*args, **kwargs):
4345 """SetWeeks(self, int n) -> DateSpan"""
4346 return _misc_.DateSpan_SetWeeks(*args, **kwargs)
4347
4348 def SetDays(*args, **kwargs):
4349 """SetDays(self, int n) -> DateSpan"""
4350 return _misc_.DateSpan_SetDays(*args, **kwargs)
4351
4352 def GetYears(*args, **kwargs):
4353 """GetYears(self) -> int"""
4354 return _misc_.DateSpan_GetYears(*args, **kwargs)
4355
4356 def GetMonths(*args, **kwargs):
4357 """GetMonths(self) -> int"""
4358 return _misc_.DateSpan_GetMonths(*args, **kwargs)
4359
4360 def GetWeeks(*args, **kwargs):
4361 """GetWeeks(self) -> int"""
4362 return _misc_.DateSpan_GetWeeks(*args, **kwargs)
4363
4364 def GetDays(*args, **kwargs):
4365 """GetDays(self) -> int"""
4366 return _misc_.DateSpan_GetDays(*args, **kwargs)
4367
4368 def GetTotalDays(*args, **kwargs):
4369 """GetTotalDays(self) -> int"""
4370 return _misc_.DateSpan_GetTotalDays(*args, **kwargs)
4371
4372 def Add(*args, **kwargs):
4373 """Add(self, DateSpan other) -> DateSpan"""
4374 return _misc_.DateSpan_Add(*args, **kwargs)
4375
4376 def Subtract(*args, **kwargs):
4377 """Subtract(self, DateSpan other) -> DateSpan"""
4378 return _misc_.DateSpan_Subtract(*args, **kwargs)
4379
4380 def Neg(*args, **kwargs):
4381 """Neg(self) -> DateSpan"""
4382 return _misc_.DateSpan_Neg(*args, **kwargs)
4383
4384 def Multiply(*args, **kwargs):
4385 """Multiply(self, int factor) -> DateSpan"""
4386 return _misc_.DateSpan_Multiply(*args, **kwargs)
4387
4388 def __iadd__(*args, **kwargs):
4389 """__iadd__(self, DateSpan other) -> DateSpan"""
4390 return _misc_.DateSpan___iadd__(*args, **kwargs)
4391
4392 def __isub__(*args, **kwargs):
4393 """__isub__(self, DateSpan other) -> DateSpan"""
4394 return _misc_.DateSpan___isub__(*args, **kwargs)
4395
4396 def __neg__(*args, **kwargs):
4397 """__neg__(self) -> DateSpan"""
4398 return _misc_.DateSpan___neg__(*args, **kwargs)
4399
4400 def __imul__(*args, **kwargs):
4401 """__imul__(self, int factor) -> DateSpan"""
4402 return _misc_.DateSpan___imul__(*args, **kwargs)
4403
4404 def __add__(*args, **kwargs):
4405 """__add__(self, DateSpan other) -> DateSpan"""
4406 return _misc_.DateSpan___add__(*args, **kwargs)
4407
4408 def __sub__(*args, **kwargs):
4409 """__sub__(self, DateSpan other) -> DateSpan"""
4410 return _misc_.DateSpan___sub__(*args, **kwargs)
4411
4412 def __mul__(*args, **kwargs):
4413 """__mul__(self, int n) -> DateSpan"""
4414 return _misc_.DateSpan___mul__(*args, **kwargs)
4415
4416 def __rmul__(*args, **kwargs):
4417 """__rmul__(self, int n) -> DateSpan"""
4418 return _misc_.DateSpan___rmul__(*args, **kwargs)
4419
4420 def __eq__(*args, **kwargs):
4421 """__eq__(self, DateSpan other) -> bool"""
4422 return _misc_.DateSpan___eq__(*args, **kwargs)
4423
4424 def __ne__(*args, **kwargs):
4425 """__ne__(self, DateSpan other) -> bool"""
4426 return _misc_.DateSpan___ne__(*args, **kwargs)
4427
4428
4429 class DateSpanPtr(DateSpan):
4430 def __init__(self, this):
4431 self.this = this
4432 if not hasattr(self,"thisown"): self.thisown = 0
4433 self.__class__ = DateSpan
4434 _misc_.DateSpan_swigregister(DateSpanPtr)
4435
4436 def DateSpan_Days(*args, **kwargs):
4437 """DateSpan_Days(int days) -> DateSpan"""
4438 return _misc_.DateSpan_Days(*args, **kwargs)
4439
4440 def DateSpan_Day(*args, **kwargs):
4441 """DateSpan_Day() -> DateSpan"""
4442 return _misc_.DateSpan_Day(*args, **kwargs)
4443
4444 def DateSpan_Weeks(*args, **kwargs):
4445 """DateSpan_Weeks(int weeks) -> DateSpan"""
4446 return _misc_.DateSpan_Weeks(*args, **kwargs)
4447
4448 def DateSpan_Week(*args, **kwargs):
4449 """DateSpan_Week() -> DateSpan"""
4450 return _misc_.DateSpan_Week(*args, **kwargs)
4451
4452 def DateSpan_Months(*args, **kwargs):
4453 """DateSpan_Months(int mon) -> DateSpan"""
4454 return _misc_.DateSpan_Months(*args, **kwargs)
4455
4456 def DateSpan_Month(*args, **kwargs):
4457 """DateSpan_Month() -> DateSpan"""
4458 return _misc_.DateSpan_Month(*args, **kwargs)
4459
4460 def DateSpan_Years(*args, **kwargs):
4461 """DateSpan_Years(int years) -> DateSpan"""
4462 return _misc_.DateSpan_Years(*args, **kwargs)
4463
4464 def DateSpan_Year(*args, **kwargs):
4465 """DateSpan_Year() -> DateSpan"""
4466 return _misc_.DateSpan_Year(*args, **kwargs)
4467
4468
4469 def GetLocalTime(*args, **kwargs):
4470 """GetLocalTime() -> long"""
4471 return _misc_.GetLocalTime(*args, **kwargs)
4472
4473 def GetUTCTime(*args, **kwargs):
4474 """GetUTCTime() -> long"""
4475 return _misc_.GetUTCTime(*args, **kwargs)
4476
4477 def GetCurrentTime(*args, **kwargs):
4478 """GetCurrentTime() -> long"""
4479 return _misc_.GetCurrentTime(*args, **kwargs)
4480
4481 def GetLocalTimeMillis(*args, **kwargs):
4482 """GetLocalTimeMillis() -> wxLongLong"""
4483 return _misc_.GetLocalTimeMillis(*args, **kwargs)
4484 #---------------------------------------------------------------------------
4485
4486 DF_INVALID = _misc_.DF_INVALID
4487 DF_TEXT = _misc_.DF_TEXT
4488 DF_BITMAP = _misc_.DF_BITMAP
4489 DF_METAFILE = _misc_.DF_METAFILE
4490 DF_SYLK = _misc_.DF_SYLK
4491 DF_DIF = _misc_.DF_DIF
4492 DF_TIFF = _misc_.DF_TIFF
4493 DF_OEMTEXT = _misc_.DF_OEMTEXT
4494 DF_DIB = _misc_.DF_DIB
4495 DF_PALETTE = _misc_.DF_PALETTE
4496 DF_PENDATA = _misc_.DF_PENDATA
4497 DF_RIFF = _misc_.DF_RIFF
4498 DF_WAVE = _misc_.DF_WAVE
4499 DF_UNICODETEXT = _misc_.DF_UNICODETEXT
4500 DF_ENHMETAFILE = _misc_.DF_ENHMETAFILE
4501 DF_FILENAME = _misc_.DF_FILENAME
4502 DF_LOCALE = _misc_.DF_LOCALE
4503 DF_PRIVATE = _misc_.DF_PRIVATE
4504 DF_HTML = _misc_.DF_HTML
4505 DF_MAX = _misc_.DF_MAX
4506 class DataFormat(object):
4507 """
4508 A wx.DataFormat is an encapsulation of a platform-specific format
4509 handle which is used by the system for the clipboard and drag and drop
4510 operations. The applications are usually only interested in, for
4511 example, pasting data from the clipboard only if the data is in a
4512 format the program understands. A data format is is used to uniquely
4513 identify this format.
4514 """
4515 def __repr__(self):
4516 return "<%s.%s; proxy of C++ wxDataFormat instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
4517 def __init__(self, *args, **kwargs):
4518 """
4519 __init__(self, int type) -> DataFormat
4520
4521 Constructs a data format object for one of the standard data formats
4522 or an empty data object (use SetType or SetId later in this case)
4523 """
4524 newobj = _misc_.new_DataFormat(*args, **kwargs)
4525 self.this = newobj.this
4526 self.thisown = 1
4527 del newobj.thisown
4528 def __del__(self, destroy=_misc_.delete_DataFormat):
4529 """__del__(self)"""
4530 try:
4531 if self.thisown: destroy(self)
4532 except: pass
4533
4534 def __eq__(*args):
4535 """
4536 __eq__(self, int format) -> bool
4537 __eq__(self, DataFormat format) -> bool
4538 """
4539 return _misc_.DataFormat___eq__(*args)
4540
4541 def __ne__(*args):
4542 """
4543 __ne__(self, int format) -> bool
4544 __ne__(self, DataFormat format) -> bool
4545 """
4546 return _misc_.DataFormat___ne__(*args)
4547
4548 def SetType(*args, **kwargs):
4549 """
4550 SetType(self, int format)
4551
4552 Sets the format to the given value, which should be one of wx.DF_XXX
4553 constants.
4554 """
4555 return _misc_.DataFormat_SetType(*args, **kwargs)
4556
4557 def GetType(*args, **kwargs):
4558 """
4559 GetType(self) -> int
4560
4561 Returns the platform-specific number identifying the format.
4562 """
4563 return _misc_.DataFormat_GetType(*args, **kwargs)
4564
4565 def GetId(*args, **kwargs):
4566 """
4567 GetId(self) -> String
4568
4569 Returns the name of a custom format (this function will fail for a
4570 standard format).
4571 """
4572 return _misc_.DataFormat_GetId(*args, **kwargs)
4573
4574 def SetId(*args, **kwargs):
4575 """
4576 SetId(self, String format)
4577
4578 Sets the format to be the custom format identified by the given name.
4579 """
4580 return _misc_.DataFormat_SetId(*args, **kwargs)
4581
4582
4583 class DataFormatPtr(DataFormat):
4584 def __init__(self, this):
4585 self.this = this
4586 if not hasattr(self,"thisown"): self.thisown = 0
4587 self.__class__ = DataFormat
4588 _misc_.DataFormat_swigregister(DataFormatPtr)
4589 DefaultDateTime = cvar.DefaultDateTime
4590
4591 def CustomDataFormat(*args, **kwargs):
4592 """
4593 CustomDataFormat(String format) -> DataFormat
4594
4595 Constructs a data format object for a custom format identified by its
4596 name.
4597 """
4598 val = _misc_.new_CustomDataFormat(*args, **kwargs)
4599 val.thisown = 1
4600 return val
4601
4602 class DataObject(object):
4603 """
4604 A wx.DataObject represents data that can be copied to or from the
4605 clipboard, or dragged and dropped. The important thing about
4606 wx.DataObject is that this is a 'smart' piece of data unlike usual
4607 'dumb' data containers such as memory buffers or files. Being 'smart'
4608 here means that the data object itself should know what data formats
4609 it supports and how to render itself in each of supported formats.
4610
4611 **NOTE**: This class is an abstract base class and can not be used
4612 directly from Python. If you need a custom type of data object then
4613 you should instead derive from `wx.PyDataObjectSimple` or use
4614 `wx.CustomDataObject`.
4615
4616 """
4617 def __init__(self): raise RuntimeError, "No constructor defined"
4618 def __repr__(self):
4619 return "<%s.%s; proxy of C++ wxDataObject instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
4620 Get = _misc_.DataObject_Get
4621 Set = _misc_.DataObject_Set
4622 Both = _misc_.DataObject_Both
4623 def __del__(self, destroy=_misc_.delete_DataObject):
4624 """__del__(self)"""
4625 try:
4626 if self.thisown: destroy(self)
4627 except: pass
4628
4629 def GetPreferredFormat(*args, **kwargs):
4630 """
4631 GetPreferredFormat(self, int dir=Get) -> DataFormat
4632
4633 Returns the preferred format for either rendering the data (if dir is
4634 Get, its default value) or for setting it. Usually this will be the
4635 native format of the wx.DataObject.
4636 """
4637 return _misc_.DataObject_GetPreferredFormat(*args, **kwargs)
4638
4639 def GetFormatCount(*args, **kwargs):
4640 """
4641 GetFormatCount(self, int dir=Get) -> size_t
4642
4643 Returns the number of available formats for rendering or setting the
4644 data.
4645 """
4646 return _misc_.DataObject_GetFormatCount(*args, **kwargs)
4647
4648 def IsSupported(*args, **kwargs):
4649 """
4650 IsSupported(self, DataFormat format, int dir=Get) -> bool
4651
4652 Returns True if this format is supported.
4653 """
4654 return _misc_.DataObject_IsSupported(*args, **kwargs)
4655
4656 def GetDataSize(*args, **kwargs):
4657 """
4658 GetDataSize(self, DataFormat format) -> size_t
4659
4660 Get the (total) size of data for the given format
4661 """
4662 return _misc_.DataObject_GetDataSize(*args, **kwargs)
4663
4664 def GetAllFormats(*args, **kwargs):
4665 """
4666 GetAllFormats(self, int dir=Get) -> [formats]
4667
4668 Returns a list of all the wx.DataFormats that this dataobject supports
4669 in the given direction.
4670 """
4671 return _misc_.DataObject_GetAllFormats(*args, **kwargs)
4672
4673 def GetDataHere(*args, **kwargs):
4674 """
4675 GetDataHere(self, DataFormat format) -> String
4676
4677 Get the data bytes in the specified format, returns None on failure.
4678
4679 """
4680 return _misc_.DataObject_GetDataHere(*args, **kwargs)
4681
4682 def SetData(*args, **kwargs):
4683 """
4684 SetData(self, DataFormat format, String data) -> bool
4685
4686 Set the data in the specified format from the bytes in the the data string.
4687
4688 """
4689 return _misc_.DataObject_SetData(*args, **kwargs)
4690
4691
4692 class DataObjectPtr(DataObject):
4693 def __init__(self, this):
4694 self.this = this
4695 if not hasattr(self,"thisown"): self.thisown = 0
4696 self.__class__ = DataObject
4697 _misc_.DataObject_swigregister(DataObjectPtr)
4698 FormatInvalid = cvar.FormatInvalid
4699
4700 class DataObjectSimple(DataObject):
4701 """
4702 wx.DataObjectSimple is a `wx.DataObject` which only supports one
4703 format. This is the simplest possible `wx.DataObject` implementation.
4704
4705 This is still an "abstract base class" meaning that you can't use it
4706 directly. You either need to use one of the predefined base classes,
4707 or derive your own class from `wx.PyDataObjectSimple`.
4708
4709 """
4710 def __repr__(self):
4711 return "<%s.%s; proxy of C++ wxDataObjectSimple instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
4712 def __init__(self, *args, **kwargs):
4713 """
4714 __init__(self, DataFormat format=FormatInvalid) -> DataObjectSimple
4715
4716 Constructor accepts the supported format (none by default) which may
4717 also be set later with `SetFormat`.
4718 """
4719 newobj = _misc_.new_DataObjectSimple(*args, **kwargs)
4720 self.this = newobj.this
4721 self.thisown = 1
4722 del newobj.thisown
4723 def GetFormat(*args, **kwargs):
4724 """
4725 GetFormat(self) -> DataFormat
4726
4727 Returns the (one and only one) format supported by this object. It is
4728 assumed that the format is supported in both directions.
4729 """
4730 return _misc_.DataObjectSimple_GetFormat(*args, **kwargs)
4731
4732 def SetFormat(*args, **kwargs):
4733 """
4734 SetFormat(self, DataFormat format)
4735
4736 Sets the supported format.
4737 """
4738 return _misc_.DataObjectSimple_SetFormat(*args, **kwargs)
4739
4740 def GetDataSize(*args, **kwargs):
4741 """
4742 GetDataSize(self) -> size_t
4743
4744 Get the size of our data.
4745 """
4746 return _misc_.DataObjectSimple_GetDataSize(*args, **kwargs)
4747
4748 def GetDataHere(*args, **kwargs):
4749 """
4750 GetDataHere(self) -> String
4751
4752 Returns the data bytes from the data object as a string, returns None
4753 on failure. Must be implemented in the derived class if the object
4754 supports rendering its data.
4755 """
4756 return _misc_.DataObjectSimple_GetDataHere(*args, **kwargs)
4757
4758 def SetData(*args, **kwargs):
4759 """
4760 SetData(self, String data) -> bool
4761
4762 Copy the data value to the data object. Must be implemented in the
4763 derived class if the object supports setting its data.
4764
4765 """
4766 return _misc_.DataObjectSimple_SetData(*args, **kwargs)
4767
4768
4769 class DataObjectSimplePtr(DataObjectSimple):
4770 def __init__(self, this):
4771 self.this = this
4772 if not hasattr(self,"thisown"): self.thisown = 0
4773 self.__class__ = DataObjectSimple
4774 _misc_.DataObjectSimple_swigregister(DataObjectSimplePtr)
4775
4776 class PyDataObjectSimple(DataObjectSimple):
4777 """
4778 wx.PyDataObjectSimple is a version of `wx.DataObjectSimple` that is
4779 Python-aware and knows how to reflect calls to its C++ virtual methods
4780 to methods in the Python derived class. You should derive from this
4781 class and overload `GetDataSize`, `GetDataHere` and `SetData` when you
4782 need to create your own simple single-format type of `wx.DataObject`.
4783
4784 """
4785 def __repr__(self):
4786 return "<%s.%s; proxy of C++ wxPyDataObjectSimple instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
4787 def __init__(self, *args, **kwargs):
4788 """
4789 __init__(self, DataFormat format=FormatInvalid) -> PyDataObjectSimple
4790
4791 wx.PyDataObjectSimple is a version of `wx.DataObjectSimple` that is
4792 Python-aware and knows how to reflect calls to its C++ virtual methods
4793 to methods in the Python derived class. You should derive from this
4794 class and overload `GetDataSize`, `GetDataHere` and `SetData` when you
4795 need to create your own simple single-format type of `wx.DataObject`.
4796
4797 """
4798 newobj = _misc_.new_PyDataObjectSimple(*args, **kwargs)
4799 self.this = newobj.this
4800 self.thisown = 1
4801 del newobj.thisown
4802 self._setCallbackInfo(self, PyDataObjectSimple)
4803
4804 def _setCallbackInfo(*args, **kwargs):
4805 """_setCallbackInfo(self, PyObject self, PyObject _class)"""
4806 return _misc_.PyDataObjectSimple__setCallbackInfo(*args, **kwargs)
4807
4808
4809 class PyDataObjectSimplePtr(PyDataObjectSimple):
4810 def __init__(self, this):
4811 self.this = this
4812 if not hasattr(self,"thisown"): self.thisown = 0
4813 self.__class__ = PyDataObjectSimple
4814 _misc_.PyDataObjectSimple_swigregister(PyDataObjectSimplePtr)
4815
4816 class DataObjectComposite(DataObject):
4817 """
4818 wx.DataObjectComposite is the simplest `wx.DataObject` derivation
4819 which may be sued to support multiple formats. It contains several
4820 'wx.DataObjectSimple` objects and supports any format supported by at
4821 least one of them. Only one of these data objects is *preferred* (the
4822 first one if not explicitly changed by using the second parameter of
4823 `Add`) and its format determines the preferred format of the composite
4824 data object as well.
4825
4826 See `wx.DataObject` documentation for the reasons why you might prefer
4827 to use wx.DataObject directly instead of wx.DataObjectComposite for
4828 efficiency reasons.
4829
4830 """
4831 def __repr__(self):
4832 return "<%s.%s; proxy of C++ wxDataObjectComposite instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
4833 def __init__(self, *args, **kwargs):
4834 """
4835 __init__(self) -> DataObjectComposite
4836
4837 wx.DataObjectComposite is the simplest `wx.DataObject` derivation
4838 which may be sued to support multiple formats. It contains several
4839 'wx.DataObjectSimple` objects and supports any format supported by at
4840 least one of them. Only one of these data objects is *preferred* (the
4841 first one if not explicitly changed by using the second parameter of
4842 `Add`) and its format determines the preferred format of the composite
4843 data object as well.
4844
4845 See `wx.DataObject` documentation for the reasons why you might prefer
4846 to use wx.DataObject directly instead of wx.DataObjectComposite for
4847 efficiency reasons.
4848
4849 """
4850 newobj = _misc_.new_DataObjectComposite(*args, **kwargs)
4851 self.this = newobj.this
4852 self.thisown = 1
4853 del newobj.thisown
4854 def Add(*args, **kwargs):
4855 """
4856 Add(self, DataObjectSimple dataObject, bool preferred=False)
4857
4858 Adds the dataObject to the list of supported objects and it becomes
4859 the preferred object if preferred is True.
4860 """
4861 return _misc_.DataObjectComposite_Add(*args, **kwargs)
4862
4863
4864 class DataObjectCompositePtr(DataObjectComposite):
4865 def __init__(self, this):
4866 self.this = this
4867 if not hasattr(self,"thisown"): self.thisown = 0
4868 self.__class__ = DataObjectComposite
4869 _misc_.DataObjectComposite_swigregister(DataObjectCompositePtr)
4870
4871 class TextDataObject(DataObjectSimple):
4872 """
4873 wx.TextDataObject is a specialization of `wx.DataObject` for text
4874 data. It can be used without change to paste data into the `wx.Clipboard`
4875 or a `wx.DropSource`.
4876
4877 Alternativly, you may wish to derive a new class from the
4878 `wx.PyTextDataObject` class for providing text on-demand in order to
4879 minimize memory consumption when offering data in several formats,
4880 such as plain text and RTF, because by default the text is stored in a
4881 string in this class, but it might as well be generated on demand when
4882 requested. For this, `GetTextLength` and `GetText` will have to be
4883 overridden.
4884 """
4885 def __repr__(self):
4886 return "<%s.%s; proxy of C++ wxTextDataObject instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
4887 def __init__(self, *args, **kwargs):
4888 """
4889 __init__(self, String text=EmptyString) -> TextDataObject
4890
4891 Constructor, may be used to initialise the text (otherwise `SetText`
4892 should be used later).
4893 """
4894 newobj = _misc_.new_TextDataObject(*args, **kwargs)
4895 self.this = newobj.this
4896 self.thisown = 1
4897 del newobj.thisown
4898 def GetTextLength(*args, **kwargs):
4899 """
4900 GetTextLength(self) -> size_t
4901
4902 Returns the data size. By default, returns the size of the text data
4903 set in the constructor or using `SetText`. This can be overridden (via
4904 `wx.PyTextDataObject`) to provide text size data on-demand. It is
4905 recommended to return the text length plus 1 for a trailing zero, but
4906 this is not strictly required.
4907 """
4908 return _misc_.TextDataObject_GetTextLength(*args, **kwargs)
4909
4910 def GetText(*args, **kwargs):
4911 """
4912 GetText(self) -> String
4913
4914 Returns the text associated with the data object.
4915 """
4916 return _misc_.TextDataObject_GetText(*args, **kwargs)
4917
4918 def SetText(*args, **kwargs):
4919 """
4920 SetText(self, String text)
4921
4922 Sets the text associated with the data object. This method is called
4923 when the data object receives the data and, by default, copies the
4924 text into the member variable. If you want to process the text on the
4925 fly you may wish to override this function (via
4926 `wx.PyTextDataObject`.)
4927 """
4928 return _misc_.TextDataObject_SetText(*args, **kwargs)
4929
4930
4931 class TextDataObjectPtr(TextDataObject):
4932 def __init__(self, this):
4933 self.this = this
4934 if not hasattr(self,"thisown"): self.thisown = 0
4935 self.__class__ = TextDataObject
4936 _misc_.TextDataObject_swigregister(TextDataObjectPtr)
4937
4938 class PyTextDataObject(TextDataObject):
4939 """
4940 wx.PyTextDataObject is a version of `wx.TextDataObject` that is
4941 Python-aware and knows how to reflect calls to its C++ virtual methods
4942 to methods in the Python derived class. You should derive from this
4943 class and overload `GetTextLength`, `GetText`, and `SetText` when you
4944 want to be able to provide text on demand instead of preloading it
4945 into the data object.
4946 """
4947 def __repr__(self):
4948 return "<%s.%s; proxy of C++ wxPyTextDataObject instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
4949 def __init__(self, *args, **kwargs):
4950 """
4951 __init__(self, String text=EmptyString) -> PyTextDataObject
4952
4953 wx.PyTextDataObject is a version of `wx.TextDataObject` that is
4954 Python-aware and knows how to reflect calls to its C++ virtual methods
4955 to methods in the Python derived class. You should derive from this
4956 class and overload `GetTextLength`, `GetText`, and `SetText` when you
4957 want to be able to provide text on demand instead of preloading it
4958 into the data object.
4959 """
4960 newobj = _misc_.new_PyTextDataObject(*args, **kwargs)
4961 self.this = newobj.this
4962 self.thisown = 1
4963 del newobj.thisown
4964 self._setCallbackInfo(self, PyTextDataObject)
4965
4966 def _setCallbackInfo(*args, **kwargs):
4967 """_setCallbackInfo(self, PyObject self, PyObject _class)"""
4968 return _misc_.PyTextDataObject__setCallbackInfo(*args, **kwargs)
4969
4970
4971 class PyTextDataObjectPtr(PyTextDataObject):
4972 def __init__(self, this):
4973 self.this = this
4974 if not hasattr(self,"thisown"): self.thisown = 0
4975 self.__class__ = PyTextDataObject
4976 _misc_.PyTextDataObject_swigregister(PyTextDataObjectPtr)
4977
4978 class BitmapDataObject(DataObjectSimple):
4979 """
4980 wx.BitmapDataObject is a specialization of wxDataObject for bitmap
4981 data. It can be used without change to paste data into the `wx.Clipboard`
4982 or a `wx.DropSource`.
4983
4984 """
4985 def __repr__(self):
4986 return "<%s.%s; proxy of C++ wxBitmapDataObject instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
4987 def __init__(self, *args, **kwargs):
4988 """
4989 __init__(self, Bitmap bitmap=wxNullBitmap) -> BitmapDataObject
4990
4991 Constructor, optionally passing a bitmap (otherwise use `SetBitmap`
4992 later).
4993 """
4994 newobj = _misc_.new_BitmapDataObject(*args, **kwargs)
4995 self.this = newobj.this
4996 self.thisown = 1
4997 del newobj.thisown
4998 def GetBitmap(*args, **kwargs):
4999 """
5000 GetBitmap(self) -> Bitmap
5001
5002 Returns the bitmap associated with the data object. You may wish to
5003 override this method (by deriving from `wx.PyBitmapDataObject`) when
5004 offering data on-demand, but this is not required by wxWidgets'
5005 internals. Use this method to get data in bitmap form from the
5006 `wx.Clipboard`.
5007 """
5008 return _misc_.BitmapDataObject_GetBitmap(*args, **kwargs)
5009
5010 def SetBitmap(*args, **kwargs):
5011 """
5012 SetBitmap(self, Bitmap bitmap)
5013
5014 Sets the bitmap associated with the data object. This method is called
5015 when the data object receives data. Usually there will be no reason to
5016 override this function.
5017 """
5018 return _misc_.BitmapDataObject_SetBitmap(*args, **kwargs)
5019
5020
5021 class BitmapDataObjectPtr(BitmapDataObject):
5022 def __init__(self, this):
5023 self.this = this
5024 if not hasattr(self,"thisown"): self.thisown = 0
5025 self.__class__ = BitmapDataObject
5026 _misc_.BitmapDataObject_swigregister(BitmapDataObjectPtr)
5027
5028 class PyBitmapDataObject(BitmapDataObject):
5029 """
5030 wx.PyBitmapDataObject is a version of `wx.BitmapDataObject` that is
5031 Python-aware and knows how to reflect calls to its C++ virtual methods
5032 to methods in the Python derived class. To be able to provide bitmap
5033 data on demand derive from this class and overload `GetBitmap`.
5034 """
5035 def __repr__(self):
5036 return "<%s.%s; proxy of C++ wxPyBitmapDataObject instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
5037 def __init__(self, *args, **kwargs):
5038 """
5039 __init__(self, Bitmap bitmap=wxNullBitmap) -> PyBitmapDataObject
5040
5041 wx.PyBitmapDataObject is a version of `wx.BitmapDataObject` that is
5042 Python-aware and knows how to reflect calls to its C++ virtual methods
5043 to methods in the Python derived class. To be able to provide bitmap
5044 data on demand derive from this class and overload `GetBitmap`.
5045 """
5046 newobj = _misc_.new_PyBitmapDataObject(*args, **kwargs)
5047 self.this = newobj.this
5048 self.thisown = 1
5049 del newobj.thisown
5050 self._setCallbackInfo(self, PyBitmapDataObject)
5051
5052 def _setCallbackInfo(*args, **kwargs):
5053 """_setCallbackInfo(self, PyObject self, PyObject _class)"""
5054 return _misc_.PyBitmapDataObject__setCallbackInfo(*args, **kwargs)
5055
5056
5057 class PyBitmapDataObjectPtr(PyBitmapDataObject):
5058 def __init__(self, this):
5059 self.this = this
5060 if not hasattr(self,"thisown"): self.thisown = 0
5061 self.__class__ = PyBitmapDataObject
5062 _misc_.PyBitmapDataObject_swigregister(PyBitmapDataObjectPtr)
5063
5064 class FileDataObject(DataObjectSimple):
5065 """
5066 wx.FileDataObject is a specialization of `wx.DataObjectSimple` for
5067 file names. The program works with it just as if it were a list of
5068 absolute file names, but internally it uses the same format as
5069 Explorer and other compatible programs under Windows or GNOME/KDE
5070 filemanager under Unix which makes it possible to receive files from
5071 them using this class.
5072 """
5073 def __repr__(self):
5074 return "<%s.%s; proxy of C++ wxFileDataObject instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
5075 def __init__(self, *args, **kwargs):
5076 """__init__(self) -> FileDataObject"""
5077 newobj = _misc_.new_FileDataObject(*args, **kwargs)
5078 self.this = newobj.this
5079 self.thisown = 1
5080 del newobj.thisown
5081 def GetFilenames(*args, **kwargs):
5082 """
5083 GetFilenames(self) -> [names]
5084
5085 Returns a list of file names.
5086 """
5087 return _misc_.FileDataObject_GetFilenames(*args, **kwargs)
5088
5089 def AddFile(*args, **kwargs):
5090 """
5091 AddFile(self, String filename)
5092
5093 Adds a file to the list of files represented by this data object.
5094 """
5095 return _misc_.FileDataObject_AddFile(*args, **kwargs)
5096
5097
5098 class FileDataObjectPtr(FileDataObject):
5099 def __init__(self, this):
5100 self.this = this
5101 if not hasattr(self,"thisown"): self.thisown = 0
5102 self.__class__ = FileDataObject
5103 _misc_.FileDataObject_swigregister(FileDataObjectPtr)
5104
5105 class CustomDataObject(DataObjectSimple):
5106 """
5107 wx.CustomDataObject is a specialization of `wx.DataObjectSimple` for
5108 some application-specific data in arbitrary format. Python strings
5109 are used for getting and setting data, but any picklable object can
5110 easily be transfered via strings. A copy of the data is stored in the
5111 data object.
5112 """
5113 def __repr__(self):
5114 return "<%s.%s; proxy of C++ wxCustomDataObject instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
5115 def __init__(self, *args):
5116 """
5117 __init__(self, DataFormat format) -> CustomDataObject
5118 __init__(self, String formatName) -> CustomDataObject
5119 __init__(self) -> CustomDataObject
5120
5121 wx.CustomDataObject is a specialization of `wx.DataObjectSimple` for
5122 some application-specific data in arbitrary format. Python strings
5123 are used for getting and setting data, but any picklable object can
5124 easily be transfered via strings. A copy of the data is stored in the
5125 data object.
5126 """
5127 newobj = _misc_.new_CustomDataObject(*args)
5128 self.this = newobj.this
5129 self.thisown = 1
5130 del newobj.thisown
5131 def SetData(*args, **kwargs):
5132 """
5133 SetData(self, String data) -> bool
5134
5135 Copy the data value to the data object.
5136 """
5137 return _misc_.CustomDataObject_SetData(*args, **kwargs)
5138
5139 TakeData = SetData
5140 def GetSize(*args, **kwargs):
5141 """
5142 GetSize(self) -> size_t
5143
5144 Get the size of the data.
5145 """
5146 return _misc_.CustomDataObject_GetSize(*args, **kwargs)
5147
5148 def GetData(*args, **kwargs):
5149 """
5150 GetData(self) -> String
5151
5152 Returns the data bytes from the data object as a string.
5153 """
5154 return _misc_.CustomDataObject_GetData(*args, **kwargs)
5155
5156
5157 class CustomDataObjectPtr(CustomDataObject):
5158 def __init__(self, this):
5159 self.this = this
5160 if not hasattr(self,"thisown"): self.thisown = 0
5161 self.__class__ = CustomDataObject
5162 _misc_.CustomDataObject_swigregister(CustomDataObjectPtr)
5163
5164 class URLDataObject(DataObjectComposite):
5165 """
5166 This data object holds a URL in a format that is compatible with some
5167 browsers such that it is able to be dragged to or from them.
5168 """
5169 def __repr__(self):
5170 return "<%s.%s; proxy of C++ wxURLDataObject instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
5171 def __init__(self, *args, **kwargs):
5172 """
5173 __init__(self) -> URLDataObject
5174
5175 This data object holds a URL in a format that is compatible with some
5176 browsers such that it is able to be dragged to or from them.
5177 """
5178 newobj = _misc_.new_URLDataObject(*args, **kwargs)
5179 self.this = newobj.this
5180 self.thisown = 1
5181 del newobj.thisown
5182 def GetURL(*args, **kwargs):
5183 """
5184 GetURL(self) -> String
5185
5186 Returns a string containing the current URL.
5187 """
5188 return _misc_.URLDataObject_GetURL(*args, **kwargs)
5189
5190 def SetURL(*args, **kwargs):
5191 """
5192 SetURL(self, String url)
5193
5194 Set the URL.
5195 """
5196 return _misc_.URLDataObject_SetURL(*args, **kwargs)
5197
5198
5199 class URLDataObjectPtr(URLDataObject):
5200 def __init__(self, this):
5201 self.this = this
5202 if not hasattr(self,"thisown"): self.thisown = 0
5203 self.__class__ = URLDataObject
5204 _misc_.URLDataObject_swigregister(URLDataObjectPtr)
5205
5206 class MetafileDataObject(DataObjectSimple):
5207 """Proxy of C++ MetafileDataObject class"""
5208 def __repr__(self):
5209 return "<%s.%s; proxy of C++ wxMetafileDataObject instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
5210 def __init__(self, *args, **kwargs):
5211 """__init__(self) -> MetafileDataObject"""
5212 newobj = _misc_.new_MetafileDataObject(*args, **kwargs)
5213 self.this = newobj.this
5214 self.thisown = 1
5215 del newobj.thisown
5216 def SetMetafile(*args, **kwargs):
5217 """SetMetafile(self, wxMetafile metafile)"""
5218 return _misc_.MetafileDataObject_SetMetafile(*args, **kwargs)
5219
5220 def GetMetafile(*args, **kwargs):
5221 """GetMetafile(self) -> wxMetafile"""
5222 return _misc_.MetafileDataObject_GetMetafile(*args, **kwargs)
5223
5224
5225 class MetafileDataObjectPtr(MetafileDataObject):
5226 def __init__(self, this):
5227 self.this = this
5228 if not hasattr(self,"thisown"): self.thisown = 0
5229 self.__class__ = MetafileDataObject
5230 _misc_.MetafileDataObject_swigregister(MetafileDataObjectPtr)
5231
5232 #---------------------------------------------------------------------------
5233
5234 Drag_CopyOnly = _misc_.Drag_CopyOnly
5235 Drag_AllowMove = _misc_.Drag_AllowMove
5236 Drag_DefaultMove = _misc_.Drag_DefaultMove
5237 DragError = _misc_.DragError
5238 DragNone = _misc_.DragNone
5239 DragCopy = _misc_.DragCopy
5240 DragMove = _misc_.DragMove
5241 DragLink = _misc_.DragLink
5242 DragCancel = _misc_.DragCancel
5243
5244 def IsDragResultOk(*args, **kwargs):
5245 """IsDragResultOk(int res) -> bool"""
5246 return _misc_.IsDragResultOk(*args, **kwargs)
5247 class DropSource(object):
5248 """Proxy of C++ DropSource class"""
5249 def __repr__(self):
5250 return "<%s.%s; proxy of C++ wxPyDropSource instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
5251 def __init__(self, *args, **kwargs):
5252 """
5253 __init__(self, Window win, Cursor copy=wxNullCursor, Cursor move=wxNullCursor,
5254 Cursor none=wxNullCursor) -> DropSource
5255 """
5256 newobj = _misc_.new_DropSource(*args, **kwargs)
5257 self.this = newobj.this
5258 self.thisown = 1
5259 del newobj.thisown
5260 self._setCallbackInfo(self, DropSource, 0)
5261
5262 def _setCallbackInfo(*args, **kwargs):
5263 """_setCallbackInfo(self, PyObject self, PyObject _class, int incref)"""
5264 return _misc_.DropSource__setCallbackInfo(*args, **kwargs)
5265
5266 def __del__(self, destroy=_misc_.delete_DropSource):
5267 """__del__(self)"""
5268 try:
5269 if self.thisown: destroy(self)
5270 except: pass
5271
5272 def SetData(*args, **kwargs):
5273 """SetData(self, DataObject data)"""
5274 return _misc_.DropSource_SetData(*args, **kwargs)
5275
5276 def GetDataObject(*args, **kwargs):
5277 """GetDataObject(self) -> DataObject"""
5278 return _misc_.DropSource_GetDataObject(*args, **kwargs)
5279
5280 def SetCursor(*args, **kwargs):
5281 """SetCursor(self, int res, Cursor cursor)"""
5282 return _misc_.DropSource_SetCursor(*args, **kwargs)
5283
5284 def DoDragDrop(*args, **kwargs):
5285 """DoDragDrop(self, int flags=Drag_CopyOnly) -> int"""
5286 return _misc_.DropSource_DoDragDrop(*args, **kwargs)
5287
5288 def base_GiveFeedback(*args, **kwargs):
5289 """base_GiveFeedback(self, int effect) -> bool"""
5290 return _misc_.DropSource_base_GiveFeedback(*args, **kwargs)
5291
5292
5293 class DropSourcePtr(DropSource):
5294 def __init__(self, this):
5295 self.this = this
5296 if not hasattr(self,"thisown"): self.thisown = 0
5297 self.__class__ = DropSource
5298 _misc_.DropSource_swigregister(DropSourcePtr)
5299
5300 def DROP_ICON(filename):
5301 """
5302 Returns either a `wx.Cursor` or `wx.Icon` created from the image file
5303 ``filename``. This function is useful with the `wx.DropSource` class
5304 which, depending on platform accepts either a icon or a cursor.
5305 """
5306 img = wx.Image(filename)
5307 if wx.Platform == '__WXGTK__':
5308 return wx.IconFromBitmap(wx.BitmapFromImage(img))
5309 else:
5310 return wx.CursorFromImage(img)
5311
5312 class DropTarget(object):
5313 """Proxy of C++ DropTarget class"""
5314 def __repr__(self):
5315 return "<%s.%s; proxy of C++ wxPyDropTarget instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
5316 def __init__(self, *args, **kwargs):
5317 """__init__(self, DataObject dataObject=None) -> DropTarget"""
5318 newobj = _misc_.new_DropTarget(*args, **kwargs)
5319 self.this = newobj.this
5320 self.thisown = 1
5321 del newobj.thisown
5322 self._setCallbackInfo(self, DropTarget)
5323
5324 def _setCallbackInfo(*args, **kwargs):
5325 """_setCallbackInfo(self, PyObject self, PyObject _class)"""
5326 return _misc_.DropTarget__setCallbackInfo(*args, **kwargs)
5327
5328 def __del__(self, destroy=_misc_.delete_DropTarget):
5329 """__del__(self)"""
5330 try:
5331 if self.thisown: destroy(self)
5332 except: pass
5333
5334 def GetDataObject(*args, **kwargs):
5335 """GetDataObject(self) -> DataObject"""
5336 return _misc_.DropTarget_GetDataObject(*args, **kwargs)
5337
5338 def SetDataObject(*args, **kwargs):
5339 """SetDataObject(self, DataObject dataObject)"""
5340 return _misc_.DropTarget_SetDataObject(*args, **kwargs)
5341
5342 def base_OnEnter(*args, **kwargs):
5343 """base_OnEnter(self, int x, int y, int def) -> int"""
5344 return _misc_.DropTarget_base_OnEnter(*args, **kwargs)
5345
5346 def base_OnDragOver(*args, **kwargs):
5347 """base_OnDragOver(self, int x, int y, int def) -> int"""
5348 return _misc_.DropTarget_base_OnDragOver(*args, **kwargs)
5349
5350 def base_OnLeave(*args, **kwargs):
5351 """base_OnLeave(self)"""
5352 return _misc_.DropTarget_base_OnLeave(*args, **kwargs)
5353
5354 def base_OnDrop(*args, **kwargs):
5355 """base_OnDrop(self, int x, int y) -> bool"""
5356 return _misc_.DropTarget_base_OnDrop(*args, **kwargs)
5357
5358 def GetData(*args, **kwargs):
5359 """GetData(self) -> bool"""
5360 return _misc_.DropTarget_GetData(*args, **kwargs)
5361
5362 def SetDefaultAction(*args, **kwargs):
5363 """SetDefaultAction(self, int action)"""
5364 return _misc_.DropTarget_SetDefaultAction(*args, **kwargs)
5365
5366 def GetDefaultAction(*args, **kwargs):
5367 """GetDefaultAction(self) -> int"""
5368 return _misc_.DropTarget_GetDefaultAction(*args, **kwargs)
5369
5370
5371 class DropTargetPtr(DropTarget):
5372 def __init__(self, this):
5373 self.this = this
5374 if not hasattr(self,"thisown"): self.thisown = 0
5375 self.__class__ = DropTarget
5376 _misc_.DropTarget_swigregister(DropTargetPtr)
5377
5378 PyDropTarget = DropTarget
5379 class TextDropTarget(DropTarget):
5380 """Proxy of C++ TextDropTarget class"""
5381 def __repr__(self):
5382 return "<%s.%s; proxy of C++ wxPyTextDropTarget instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
5383 def __init__(self, *args, **kwargs):
5384 """__init__(self) -> TextDropTarget"""
5385 newobj = _misc_.new_TextDropTarget(*args, **kwargs)
5386 self.this = newobj.this
5387 self.thisown = 1
5388 del newobj.thisown
5389 self._setCallbackInfo(self, TextDropTarget)
5390
5391 def _setCallbackInfo(*args, **kwargs):
5392 """_setCallbackInfo(self, PyObject self, PyObject _class)"""
5393 return _misc_.TextDropTarget__setCallbackInfo(*args, **kwargs)
5394
5395 def base_OnEnter(*args, **kwargs):
5396 """base_OnEnter(self, int x, int y, int def) -> int"""
5397 return _misc_.TextDropTarget_base_OnEnter(*args, **kwargs)
5398
5399 def base_OnDragOver(*args, **kwargs):
5400 """base_OnDragOver(self, int x, int y, int def) -> int"""
5401 return _misc_.TextDropTarget_base_OnDragOver(*args, **kwargs)
5402
5403 def base_OnLeave(*args, **kwargs):
5404 """base_OnLeave(self)"""
5405 return _misc_.TextDropTarget_base_OnLeave(*args, **kwargs)
5406
5407 def base_OnDrop(*args, **kwargs):
5408 """base_OnDrop(self, int x, int y) -> bool"""
5409 return _misc_.TextDropTarget_base_OnDrop(*args, **kwargs)
5410
5411 def base_OnData(*args, **kwargs):
5412 """base_OnData(self, int x, int y, int def) -> int"""
5413 return _misc_.TextDropTarget_base_OnData(*args, **kwargs)
5414
5415
5416 class TextDropTargetPtr(TextDropTarget):
5417 def __init__(self, this):
5418 self.this = this
5419 if not hasattr(self,"thisown"): self.thisown = 0
5420 self.__class__ = TextDropTarget
5421 _misc_.TextDropTarget_swigregister(TextDropTargetPtr)
5422
5423 class FileDropTarget(DropTarget):
5424 """Proxy of C++ FileDropTarget class"""
5425 def __repr__(self):
5426 return "<%s.%s; proxy of C++ wxPyFileDropTarget instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
5427 def __init__(self, *args, **kwargs):
5428 """__init__(self) -> FileDropTarget"""
5429 newobj = _misc_.new_FileDropTarget(*args, **kwargs)
5430 self.this = newobj.this
5431 self.thisown = 1
5432 del newobj.thisown
5433 self._setCallbackInfo(self, FileDropTarget)
5434
5435 def _setCallbackInfo(*args, **kwargs):
5436 """_setCallbackInfo(self, PyObject self, PyObject _class)"""
5437 return _misc_.FileDropTarget__setCallbackInfo(*args, **kwargs)
5438
5439 def base_OnEnter(*args, **kwargs):
5440 """base_OnEnter(self, int x, int y, int def) -> int"""
5441 return _misc_.FileDropTarget_base_OnEnter(*args, **kwargs)
5442
5443 def base_OnDragOver(*args, **kwargs):
5444 """base_OnDragOver(self, int x, int y, int def) -> int"""
5445 return _misc_.FileDropTarget_base_OnDragOver(*args, **kwargs)
5446
5447 def base_OnLeave(*args, **kwargs):
5448 """base_OnLeave(self)"""
5449 return _misc_.FileDropTarget_base_OnLeave(*args, **kwargs)
5450
5451 def base_OnDrop(*args, **kwargs):
5452 """base_OnDrop(self, int x, int y) -> bool"""
5453 return _misc_.FileDropTarget_base_OnDrop(*args, **kwargs)
5454
5455 def base_OnData(*args, **kwargs):
5456 """base_OnData(self, int x, int y, int def) -> int"""
5457 return _misc_.FileDropTarget_base_OnData(*args, **kwargs)
5458
5459
5460 class FileDropTargetPtr(FileDropTarget):
5461 def __init__(self, this):
5462 self.this = this
5463 if not hasattr(self,"thisown"): self.thisown = 0
5464 self.__class__ = FileDropTarget
5465 _misc_.FileDropTarget_swigregister(FileDropTargetPtr)
5466
5467 #---------------------------------------------------------------------------
5468
5469 class Clipboard(_core.Object):
5470 """
5471 wx.Clipboard represents the system clipboard and provides methods to
5472 copy data to it or paste data from it. Normally, you should only use
5473 ``wx.TheClipboard`` which is a reference to a global wx.Clipboard
5474 instance.
5475
5476 Call ``wx.TheClipboard``'s `Open` method to get ownership of the
5477 clipboard. If this operation returns True, you now own the
5478 clipboard. Call `SetData` to put data on the clipboard, or `GetData`
5479 to retrieve data from the clipboard. Call `Close` to close the
5480 clipboard and relinquish ownership. You should keep the clipboard open
5481 only momentarily.
5482
5483 :see: `wx.DataObject`
5484
5485 """
5486 def __repr__(self):
5487 return "<%s.%s; proxy of C++ wxClipboard instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
5488 def __init__(self, *args, **kwargs):
5489 """__init__(self) -> Clipboard"""
5490 newobj = _misc_.new_Clipboard(*args, **kwargs)
5491 self.this = newobj.this
5492 self.thisown = 1
5493 del newobj.thisown
5494 def __del__(self, destroy=_misc_.delete_Clipboard):
5495 """__del__(self)"""
5496 try:
5497 if self.thisown: destroy(self)
5498 except: pass
5499
5500 def Open(*args, **kwargs):
5501 """
5502 Open(self) -> bool
5503
5504 Call this function to open the clipboard before calling SetData and
5505 GetData. Call Close when you have finished with the clipboard. You
5506 should keep the clipboard open for only a very short time. Returns
5507 True on success.
5508 """
5509 return _misc_.Clipboard_Open(*args, **kwargs)
5510
5511 def Close(*args, **kwargs):
5512 """
5513 Close(self)
5514
5515 Closes the clipboard.
5516 """
5517 return _misc_.Clipboard_Close(*args, **kwargs)
5518
5519 def IsOpened(*args, **kwargs):
5520 """
5521 IsOpened(self) -> bool
5522
5523 Query whether the clipboard is opened
5524 """
5525 return _misc_.Clipboard_IsOpened(*args, **kwargs)
5526
5527 def AddData(*args, **kwargs):
5528 """
5529 AddData(self, DataObject data) -> bool
5530
5531 Call this function to add the data object to the clipboard. You may
5532 call this function repeatedly after having cleared the clipboard.
5533 After this function has been called, the clipboard owns the data, so
5534 do not delete the data explicitly.
5535
5536 :see: `wx.DataObject`
5537 """
5538 return _misc_.Clipboard_AddData(*args, **kwargs)
5539
5540 def SetData(*args, **kwargs):
5541 """
5542 SetData(self, DataObject data) -> bool
5543
5544 Set the clipboard data, this is the same as `Clear` followed by
5545 `AddData`.
5546
5547 :see: `wx.DataObject`
5548 """
5549 return _misc_.Clipboard_SetData(*args, **kwargs)
5550
5551 def IsSupported(*args, **kwargs):
5552 """
5553 IsSupported(self, DataFormat format) -> bool
5554
5555 Returns True if the given format is available in the data object(s) on
5556 the clipboard.
5557 """
5558 return _misc_.Clipboard_IsSupported(*args, **kwargs)
5559
5560 def GetData(*args, **kwargs):
5561 """
5562 GetData(self, DataObject data) -> bool
5563
5564 Call this function to fill data with data on the clipboard, if
5565 available in the required format. Returns true on success.
5566 """
5567 return _misc_.Clipboard_GetData(*args, **kwargs)
5568
5569 def Clear(*args, **kwargs):
5570 """
5571 Clear(self)
5572
5573 Clears data from the clipboard object and also the system's clipboard
5574 if possible.
5575 """
5576 return _misc_.Clipboard_Clear(*args, **kwargs)
5577
5578 def Flush(*args, **kwargs):
5579 """
5580 Flush(self) -> bool
5581
5582 Flushes the clipboard: this means that the data which is currently on
5583 clipboard will stay available even after the application exits,
5584 possibly eating memory, otherwise the clipboard will be emptied on
5585 exit. Returns False if the operation is unsuccesful for any reason.
5586 """
5587 return _misc_.Clipboard_Flush(*args, **kwargs)
5588
5589 def UsePrimarySelection(*args, **kwargs):
5590 """
5591 UsePrimarySelection(self, bool primary=True)
5592
5593 On platforms supporting it (the X11 based platforms), selects the
5594 so called PRIMARY SELECTION as the clipboard as opposed to the
5595 normal clipboard, if primary is True.
5596 """
5597 return _misc_.Clipboard_UsePrimarySelection(*args, **kwargs)
5598
5599 def Get(*args, **kwargs):
5600 """
5601 Get() -> Clipboard
5602
5603 Returns global instance (wxTheClipboard) of the object.
5604 """
5605 return _misc_.Clipboard_Get(*args, **kwargs)
5606
5607 Get = staticmethod(Get)
5608
5609 class ClipboardPtr(Clipboard):
5610 def __init__(self, this):
5611 self.this = this
5612 if not hasattr(self,"thisown"): self.thisown = 0
5613 self.__class__ = Clipboard
5614 _misc_.Clipboard_swigregister(ClipboardPtr)
5615
5616 def Clipboard_Get(*args, **kwargs):
5617 """
5618 Clipboard_Get() -> Clipboard
5619
5620 Returns global instance (wxTheClipboard) of the object.
5621 """
5622 return _misc_.Clipboard_Get(*args, **kwargs)
5623
5624 class _wxPyDelayedInitWrapper(object):
5625 def __init__(self, initfunc, *args, **kwargs):
5626 self._initfunc = initfunc
5627 self._args = args
5628 self._kwargs = kwargs
5629 self._instance = None
5630 def _checkInstance(self):
5631 if self._instance is None:
5632 self._instance = self._initfunc(*self._args, **self._kwargs)
5633 def __getattr__(self, name):
5634 self._checkInstance()
5635 return getattr(self._instance, name)
5636 def __repr__(self):
5637 self._checkInstance()
5638 return repr(self._instance)
5639 TheClipboard = _wxPyDelayedInitWrapper(Clipboard.Get)
5640
5641 class ClipboardLocker(object):
5642 """
5643 A helpful class for opening the clipboard and automatically
5644 closing it when the locker is destroyed.
5645 """
5646 def __repr__(self):
5647 return "<%s.%s; proxy of C++ wxClipboardLocker instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
5648 def __init__(self, *args, **kwargs):
5649 """
5650 __init__(self, Clipboard clipboard=None) -> ClipboardLocker
5651
5652 A helpful class for opening the clipboard and automatically
5653 closing it when the locker is destroyed.
5654 """
5655 newobj = _misc_.new_ClipboardLocker(*args, **kwargs)
5656 self.this = newobj.this
5657 self.thisown = 1
5658 del newobj.thisown
5659 def __del__(self, destroy=_misc_.delete_ClipboardLocker):
5660 """__del__(self)"""
5661 try:
5662 if self.thisown: destroy(self)
5663 except: pass
5664
5665 def __nonzero__(*args, **kwargs):
5666 """
5667 __nonzero__(self) -> bool
5668
5669 A ClipboardLocker instance evaluates to True if the clipboard was
5670 successfully opened.
5671 """
5672 return _misc_.ClipboardLocker___nonzero__(*args, **kwargs)
5673
5674
5675 class ClipboardLockerPtr(ClipboardLocker):
5676 def __init__(self, this):
5677 self.this = this
5678 if not hasattr(self,"thisown"): self.thisown = 0
5679 self.__class__ = ClipboardLocker
5680 _misc_.ClipboardLocker_swigregister(ClipboardLockerPtr)
5681
5682 #---------------------------------------------------------------------------
5683
5684 class VideoMode(object):
5685 """A simple struct containing video mode parameters for a display"""
5686 def __repr__(self):
5687 return "<%s.%s; proxy of C++ wxVideoMode instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
5688 def __init__(self, *args, **kwargs):
5689 """
5690 __init__(self, int width=0, int height=0, int depth=0, int freq=0) -> VideoMode
5691
5692 A simple struct containing video mode parameters for a display
5693 """
5694 newobj = _misc_.new_VideoMode(*args, **kwargs)
5695 self.this = newobj.this
5696 self.thisown = 1
5697 del newobj.thisown
5698 def __del__(self, destroy=_misc_.delete_VideoMode):
5699 """__del__(self)"""
5700 try:
5701 if self.thisown: destroy(self)
5702 except: pass
5703
5704 def Matches(*args, **kwargs):
5705 """
5706 Matches(self, VideoMode other) -> bool
5707
5708 Returns true if this mode matches the other one in the sense that all
5709 non zero fields of the other mode have the same value in this
5710 one (except for refresh which is allowed to have a greater value)
5711 """
5712 return _misc_.VideoMode_Matches(*args, **kwargs)
5713
5714 def GetWidth(*args, **kwargs):
5715 """
5716 GetWidth(self) -> int
5717
5718 Returns the screen width in pixels (e.g. 640*480), 0 means unspecified
5719 """
5720 return _misc_.VideoMode_GetWidth(*args, **kwargs)
5721
5722 def GetHeight(*args, **kwargs):
5723 """
5724 GetHeight(self) -> int
5725
5726 Returns the screen width in pixels (e.g. 640*480), 0 means
5727 unspecified
5728 """
5729 return _misc_.VideoMode_GetHeight(*args, **kwargs)
5730
5731 def GetDepth(*args, **kwargs):
5732 """
5733 GetDepth(self) -> int
5734
5735 Returns the screen's bits per pixel (e.g. 32), 1 is monochrome and 0
5736 means unspecified/known
5737 """
5738 return _misc_.VideoMode_GetDepth(*args, **kwargs)
5739
5740 def IsOk(*args, **kwargs):
5741 """
5742 IsOk(self) -> bool
5743
5744 returns true if the object has been initialized
5745 """
5746 return _misc_.VideoMode_IsOk(*args, **kwargs)
5747
5748 def __nonzero__(self): return self.IsOk()
5749 def __eq__(*args, **kwargs):
5750 """__eq__(self, VideoMode other) -> bool"""
5751 return _misc_.VideoMode___eq__(*args, **kwargs)
5752
5753 def __ne__(*args, **kwargs):
5754 """__ne__(self, VideoMode other) -> bool"""
5755 return _misc_.VideoMode___ne__(*args, **kwargs)
5756
5757 w = property(_misc_.VideoMode_w_get, _misc_.VideoMode_w_set)
5758 h = property(_misc_.VideoMode_h_get, _misc_.VideoMode_h_set)
5759 bpp = property(_misc_.VideoMode_bpp_get, _misc_.VideoMode_bpp_set)
5760 refresh = property(_misc_.VideoMode_refresh_get, _misc_.VideoMode_refresh_set)
5761
5762 class VideoModePtr(VideoMode):
5763 def __init__(self, this):
5764 self.this = this
5765 if not hasattr(self,"thisown"): self.thisown = 0
5766 self.__class__ = VideoMode
5767 _misc_.VideoMode_swigregister(VideoModePtr)
5768
5769 class Display(object):
5770 """Represents a display/monitor attached to the system"""
5771 def __repr__(self):
5772 return "<%s.%s; proxy of C++ wxDisplay instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
5773 def __init__(self, *args, **kwargs):
5774 """
5775 __init__(self, size_t index=0) -> Display
5776
5777 Set up a Display instance with the specified display. The displays
5778 are numbered from 0 to GetCount() - 1, 0 is always the primary display
5779 and the only one which is always supported
5780 """
5781 newobj = _misc_.new_Display(*args, **kwargs)
5782 self.this = newobj.this
5783 self.thisown = 1
5784 del newobj.thisown
5785 def __del__(self, destroy=_misc_.delete_Display):
5786 """__del__(self)"""
5787 try:
5788 if self.thisown: destroy(self)
5789 except: pass
5790
5791 def GetCount(*args, **kwargs):
5792 """
5793 GetCount() -> size_t
5794
5795 Return the number of available displays.
5796 """
5797 return _misc_.Display_GetCount(*args, **kwargs)
5798
5799 GetCount = staticmethod(GetCount)
5800 def GetFromPoint(*args, **kwargs):
5801 """
5802 GetFromPoint(Point pt) -> int
5803
5804 Find the display where the given point lies, return wx.NOT_FOUND if it
5805 doesn't belong to any display
5806 """
5807 return _misc_.Display_GetFromPoint(*args, **kwargs)
5808
5809 GetFromPoint = staticmethod(GetFromPoint)
5810 def GetFromWindow(*args, **kwargs):
5811 """
5812 GetFromWindow(Window window) -> int
5813
5814 Find the display where the given window lies, return wx.NOT_FOUND if
5815 it is not shown at all.
5816 """
5817 return _misc_.Display_GetFromWindow(*args, **kwargs)
5818
5819 GetFromWindow = staticmethod(GetFromWindow)
5820 def IsOk(*args, **kwargs):
5821 """
5822 IsOk(self) -> bool
5823
5824 Return true if the object was initialized successfully
5825 """
5826 return _misc_.Display_IsOk(*args, **kwargs)
5827
5828 def __nonzero__(self): return self.IsOk()
5829 def GetGeometry(*args, **kwargs):
5830 """
5831 GetGeometry(self) -> Rect
5832
5833 Returns the bounding rectangle of the display whose index was passed
5834 to the constructor.
5835 """
5836 return _misc_.Display_GetGeometry(*args, **kwargs)
5837
5838 def GetName(*args, **kwargs):
5839 """
5840 GetName(self) -> String
5841
5842 Returns the display's name. A name is not available on all platforms.
5843 """
5844 return _misc_.Display_GetName(*args, **kwargs)
5845
5846 def IsPrimary(*args, **kwargs):
5847 """
5848 IsPrimary(self) -> bool
5849
5850 Returns true if the display is the primary display. The primary
5851 display is the one whose index is 0.
5852 """
5853 return _misc_.Display_IsPrimary(*args, **kwargs)
5854
5855 def GetModes(*args, **kwargs):
5856 """
5857 GetModes(VideoMode mode=DefaultVideoMode) -> [videoMode...]
5858
5859 Enumerate all video modes supported by this display matching the given
5860 one (in the sense of VideoMode.Match()).
5861
5862 As any mode matches the default value of the argument and there is
5863 always at least one video mode supported by display, the returned
5864 array is only empty for the default value of the argument if this
5865 function is not supported at all on this platform.
5866 """
5867 return _misc_.Display_GetModes(*args, **kwargs)
5868
5869 def GetCurrentMode(*args, **kwargs):
5870 """
5871 GetCurrentMode(self) -> VideoMode
5872
5873 Get the current video mode.
5874 """
5875 return _misc_.Display_GetCurrentMode(*args, **kwargs)
5876
5877 def ChangeMode(*args, **kwargs):
5878 """
5879 ChangeMode(self, VideoMode mode=DefaultVideoMode) -> bool
5880
5881 Changes the video mode of this display to the mode specified in the
5882 mode parameter.
5883
5884 If wx.DefaultVideoMode is passed in as the mode parameter, the defined
5885 behaviour is that wx.Display will reset the video mode to the default
5886 mode used by the display. On Windows, the behavior is normal.
5887 However, there are differences on other platforms. On Unix variations
5888 using X11 extensions it should behave as defined, but some
5889 irregularities may occur.
5890
5891 On wxMac passing in wx.DefaultVideoMode as the mode parameter does
5892 nothing. This happens because Carbon no longer has access to
5893 DMUseScreenPrefs, an undocumented function that changed the video mode
5894 to the system default by using the system's 'scrn' resource.
5895
5896 Returns True if succeeded, False otherwise
5897 """
5898 return _misc_.Display_ChangeMode(*args, **kwargs)
5899
5900 def ResetMode(*args, **kwargs):
5901 """
5902 ResetMode(self)
5903
5904 Restore the default video mode (just a more readable synonym)
5905 """
5906 return _misc_.Display_ResetMode(*args, **kwargs)
5907
5908
5909 class DisplayPtr(Display):
5910 def __init__(self, this):
5911 self.this = this
5912 if not hasattr(self,"thisown"): self.thisown = 0
5913 self.__class__ = Display
5914 _misc_.Display_swigregister(DisplayPtr)
5915 DefaultVideoMode = cvar.DefaultVideoMode
5916
5917 def Display_GetCount(*args, **kwargs):
5918 """
5919 Display_GetCount() -> size_t
5920
5921 Return the number of available displays.
5922 """
5923 return _misc_.Display_GetCount(*args, **kwargs)
5924
5925 def Display_GetFromPoint(*args, **kwargs):
5926 """
5927 Display_GetFromPoint(Point pt) -> int
5928
5929 Find the display where the given point lies, return wx.NOT_FOUND if it
5930 doesn't belong to any display
5931 """
5932 return _misc_.Display_GetFromPoint(*args, **kwargs)
5933
5934 def Display_GetFromWindow(*args, **kwargs):
5935 """
5936 Display_GetFromWindow(Window window) -> int
5937
5938 Find the display where the given window lies, return wx.NOT_FOUND if
5939 it is not shown at all.
5940 """
5941 return _misc_.Display_GetFromWindow(*args, **kwargs)
5942
5943 #---------------------------------------------------------------------------
5944
5945 class StandardPaths(object):
5946 """
5947 wx.StandardPaths returns the standard locations in the file system and
5948 should be used by the programs to find their data files in a portable
5949 way.
5950
5951 In the description of the methods below, the example return values are
5952 given for the Unix, Windows and Mac OS X systems, however please note
5953 that these are just the examples and the actual values may differ. For
5954 example, under Windows: the system administrator may change the
5955 standard directories locations, i.e. the Windows directory may be
5956 named W:\Win2003 instead of the default C:\Windows.
5957
5958 The strings appname and username should be replaced with the value
5959 returned by `wx.App.GetAppName` and the name of the currently logged
5960 in user, respectively. The string prefix is only used under Unix and
5961 is /usr/local by default but may be changed using `SetInstallPrefix`.
5962
5963 The directories returned by the methods of this class may or may not
5964 exist. If they don't exist, it's up to the caller to create them,
5965 wxStandardPaths doesn't do it.
5966
5967 Finally note that these functions only work with standardly packaged
5968 applications. I.e. under Unix you should follow the standard
5969 installation conventions and under Mac you should create your
5970 application bundle according to the Apple guidelines. Again, this
5971 class doesn't help you to do it.
5972 """
5973 def __init__(self): raise RuntimeError, "No constructor defined"
5974 def __repr__(self):
5975 return "<%s.%s; proxy of C++ wxStandardPaths instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
5976 def Get(*args, **kwargs):
5977 """
5978 Get() -> StandardPaths
5979
5980 Return the global standard paths singleton
5981 """
5982 return _misc_.StandardPaths_Get(*args, **kwargs)
5983
5984 Get = staticmethod(Get)
5985 def GetConfigDir(*args, **kwargs):
5986 """
5987 GetConfigDir(self) -> String
5988
5989 Return the directory with system config files: /etc under Unix,
5990 'c:\Documents and Settings\All Users\Application Data' under Windows,
5991 /Library/Preferences for Mac
5992 """
5993 return _misc_.StandardPaths_GetConfigDir(*args, **kwargs)
5994
5995 def GetUserConfigDir(*args, **kwargs):
5996 """
5997 GetUserConfigDir(self) -> String
5998
5999 Return the directory for the user config files: $HOME under Unix,
6000 'c:\Documents and Settings\username' under Windows, and
6001 ~/Library/Preferences under Mac
6002
6003 Only use this if you have a single file to put there, otherwise
6004 `GetUserDataDir` is more appropriate
6005 """
6006 return _misc_.StandardPaths_GetUserConfigDir(*args, **kwargs)
6007
6008 def GetDataDir(*args, **kwargs):
6009 """
6010 GetDataDir(self) -> String
6011
6012 Return the location of the application's global, (i.e. not
6013 user-specific,) data files: prefix/share/appname under Unix,
6014 'c:\Program Files\appname' under Windows,
6015 appname.app/Contents/SharedSupport app bundle directory under Mac.
6016 """
6017 return _misc_.StandardPaths_GetDataDir(*args, **kwargs)
6018
6019 def GetLocalDataDir(*args, **kwargs):
6020 """
6021 GetLocalDataDir(self) -> String
6022
6023 Return the location for application data files which are
6024 host-specific. Same as `GetDataDir` except under Unix where it is
6025 /etc/appname
6026 """
6027 return _misc_.StandardPaths_GetLocalDataDir(*args, **kwargs)
6028
6029 def GetUserDataDir(*args, **kwargs):
6030 """
6031 GetUserDataDir(self) -> String
6032
6033 Return the directory for the user-dependent application data files:
6034 $HOME/.appname under Unix, c:\Documents and
6035 Settings\username\Application Data\appname under Windows and
6036 ~/Library/Application Support/appname under Mac
6037 """
6038 return _misc_.StandardPaths_GetUserDataDir(*args, **kwargs)
6039
6040 def GetUserLocalDataDir(*args, **kwargs):
6041 """
6042 GetUserLocalDataDir(self) -> String
6043
6044 Return the directory for user data files which shouldn't be shared
6045 with the other machines
6046
6047 Same as `GetUserDataDir` for all platforms except Windows where it is
6048 the 'Local Settings\Application Data\appname' directory.
6049 """
6050 return _misc_.StandardPaths_GetUserLocalDataDir(*args, **kwargs)
6051
6052 def GetPluginsDir(*args, **kwargs):
6053 """
6054 GetPluginsDir(self) -> String
6055
6056 Return the directory where the loadable modules (plugins) live:
6057 prefix/lib/appname under Unix, program directory under Windows and
6058 Contents/Plugins app bundle subdirectory under Mac
6059 """
6060 return _misc_.StandardPaths_GetPluginsDir(*args, **kwargs)
6061
6062 def SetInstallPrefix(*args, **kwargs):
6063 """
6064 SetInstallPrefix(self, String prefix)
6065
6066 Set the program installation directory which is /usr/local by default.
6067 This value will be used by other methods such as `GetDataDir` and
6068 `GetPluginsDir` as the prefix for what they return. (This function
6069 only has meaning on Unix systems.)
6070 """
6071 return _misc_.StandardPaths_SetInstallPrefix(*args, **kwargs)
6072
6073 def GetInstallPrefix(*args, **kwargs):
6074 """
6075 GetInstallPrefix(self) -> String
6076
6077 Get the program installation prefix. The default is the prefix where
6078 Python is installed. (This function only has meaning on Unix systems.)
6079 """
6080 return _misc_.StandardPaths_GetInstallPrefix(*args, **kwargs)
6081
6082
6083 class StandardPathsPtr(StandardPaths):
6084 def __init__(self, this):
6085 self.this = this
6086 if not hasattr(self,"thisown"): self.thisown = 0
6087 self.__class__ = StandardPaths
6088 _misc_.StandardPaths_swigregister(StandardPathsPtr)
6089
6090 def StandardPaths_Get(*args, **kwargs):
6091 """
6092 StandardPaths_Get() -> StandardPaths
6093
6094 Return the global standard paths singleton
6095 """
6096 return _misc_.StandardPaths_Get(*args, **kwargs)
6097
6098