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