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