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