]> git.saurik.com Git - wxWidgets.git/blame - wxPython/src/gtk/_controls.py
Compilation fix. I didn't add a #error since I figured this sample will be
[wxWidgets.git] / wxPython / src / gtk / _controls.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 _controls_
d14a1e28 5
093d3ff1
RD
6def _swig_setattr_nondynamic(self,class_type,name,value,static=1):
7 if (name == "this"):
8 if isinstance(value, class_type):
9 self.__dict__[name] = value.this
10 if hasattr(value,"thisown"): self.__dict__["thisown"] = value.thisown
11 del value.thisown
12 return
13 method = class_type.__swig_setmethods__.get(name,None)
14 if method: return method(self,value)
15 if (not static) or hasattr(self,name) or (name == "thisown"):
16 self.__dict__[name] = value
17 else:
18 raise AttributeError("You cannot add attributes to %s" % self)
19
20def _swig_setattr(self,class_type,name,value):
21 return _swig_setattr_nondynamic(self,class_type,name,value,0)
22
23def _swig_getattr(self,class_type,name):
24 method = class_type.__swig_getmethods__.get(name,None)
25 if method: return method(self)
26 raise AttributeError,name
27
28import types
29try:
30 _object = types.ObjectType
31 _newclass = 1
32except AttributeError:
33 class _object : pass
34 _newclass = 0
35del types
36
37
38def _swig_setattr_nondynamic_method(set):
39 def set_attr(self,name,value):
40 if hasattr(self,name) or (name in ("this", "thisown")):
41 set(self,name,value)
42 else:
43 raise AttributeError("You cannot add attributes to %s" % self)
44 return set_attr
45
46
54f9ee45
RD
47import _core
48wx = _core
d14a1e28
RD
49#---------------------------------------------------------------------------
50
54f9ee45
RD
51BU_LEFT = _controls_.BU_LEFT
52BU_TOP = _controls_.BU_TOP
53BU_RIGHT = _controls_.BU_RIGHT
54BU_BOTTOM = _controls_.BU_BOTTOM
8fb0e70a 55BU_ALIGN_MASK = _controls_.BU_ALIGN_MASK
54f9ee45
RD
56BU_EXACTFIT = _controls_.BU_EXACTFIT
57BU_AUTODRAW = _controls_.BU_AUTODRAW
58class Button(_core.Control):
0df68c9f
RD
59 """
60 A button is a control that contains a text string, and is one of the most
61 common elements of a GUI. It may be placed on a dialog box or panel, or
62 indeed almost any other window.
63 """
e811c8ce
RD
64 def __repr__(self):
65 return "<%s.%s; proxy of C++ wxButton instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 66 def __init__(self, *args, **kwargs):
0df68c9f 67 """
248ed943
RD
68 __init__(self, Window parent, int id=-1, String label=EmptyString,
69 Point pos=DefaultPosition, Size size=DefaultSize,
70 long style=0, Validator validator=DefaultValidator,
71 String name=ButtonNameStr) -> Button
0df68c9f 72
7bc1e663
RD
73 Create and show a button. The preferred way to create standard
74 buttons is to use a standard ID and an empty label. In this case
75 wxWigets will automatically use a stock label that coresponds to the
76 ID given. In additon, the button will be decorated with stock icons
77 under GTK+ 2.
0df68c9f 78 """
54f9ee45 79 newobj = _controls_.new_Button(*args, **kwargs)
d14a1e28
RD
80 self.this = newobj.this
81 self.thisown = 1
82 del newobj.thisown
83 self._setOORInfo(self)
e811c8ce
RD
84
85 def Create(*args, **kwargs):
0df68c9f 86 """
248ed943
RD
87 Create(self, Window parent, int id=-1, String label=EmptyString,
88 Point pos=DefaultPosition, Size size=DefaultSize,
89 long style=0, Validator validator=DefaultValidator,
90 String name=ButtonNameStr) -> bool
0df68c9f
RD
91
92 Acutally create the GUI Button for 2-phase creation.
93 """
54f9ee45 94 return _controls_.Button_Create(*args, **kwargs)
e811c8ce
RD
95
96 def SetDefault(*args, **kwargs):
0df68c9f 97 """
a95a7133 98 SetDefault(self)
1e0c8722 99
0df68c9f
RD
100 This sets the button to be the default item for the panel or dialog box.
101 """
54f9ee45 102 return _controls_.Button_SetDefault(*args, **kwargs)
e811c8ce
RD
103
104 def GetDefaultSize(*args, **kwargs):
66c033b4
RD
105 """
106 GetDefaultSize() -> Size
107
108 Returns the default button size for this platform.
109 """
54f9ee45 110 return _controls_.Button_GetDefaultSize(*args, **kwargs)
e811c8ce
RD
111
112 GetDefaultSize = staticmethod(GetDefaultSize)
22bfe96c 113 def GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
114 """
115 GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
116
117 Get the default attributes for this class. This is useful if you want
118 to use the same font or colour in your own control as in a standard
119 control -- which is a much better idea than hard coding specific
120 colours or fonts which might look completely out of place on the
121 user's system, especially if it uses themes.
122
123 The variant parameter is only relevant under Mac currently and is
124 ignore under other platforms. Under Mac, it will change the size of
125 the returned font. See `wx.Window.SetWindowVariant` for more about
126 this.
127 """
22bfe96c
RD
128 return _controls_.Button_GetClassDefaultAttributes(*args, **kwargs)
129
130 GetClassDefaultAttributes = staticmethod(GetClassDefaultAttributes)
70551f47 131
d14a1e28
RD
132class ButtonPtr(Button):
133 def __init__(self, this):
134 self.this = this
135 if not hasattr(self,"thisown"): self.thisown = 0
136 self.__class__ = Button
54f9ee45
RD
137_controls_.Button_swigregister(ButtonPtr)
138cvar = _controls_.cvar
b2dc1044 139ButtonNameStr = cvar.ButtonNameStr
70551f47 140
d14a1e28 141def PreButton(*args, **kwargs):
0df68c9f
RD
142 """
143 PreButton() -> Button
1e0c8722 144
0df68c9f
RD
145 Precreate a Button for 2-phase creation.
146 """
54f9ee45 147 val = _controls_.new_PreButton(*args, **kwargs)
d14a1e28
RD
148 val.thisown = 1
149 return val
70551f47 150
e811c8ce 151def Button_GetDefaultSize(*args, **kwargs):
66c033b4
RD
152 """
153 Button_GetDefaultSize() -> Size
154
155 Returns the default button size for this platform.
156 """
54f9ee45 157 return _controls_.Button_GetDefaultSize(*args, **kwargs)
a323d3bd 158
22bfe96c 159def Button_GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
160 """
161 Button_GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
162
163 Get the default attributes for this class. This is useful if you want
164 to use the same font or colour in your own control as in a standard
165 control -- which is a much better idea than hard coding specific
166 colours or fonts which might look completely out of place on the
167 user's system, especially if it uses themes.
168
169 The variant parameter is only relevant under Mac currently and is
170 ignore under other platforms. Under Mac, it will change the size of
171 the returned font. See `wx.Window.SetWindowVariant` for more about
172 this.
173 """
22bfe96c
RD
174 return _controls_.Button_GetClassDefaultAttributes(*args, **kwargs)
175
d14a1e28 176class BitmapButton(Button):
98e665d3
RD
177 """
178 A Button that contains a bitmap. A bitmap button can be supplied with a
66c033b4 179 single bitmap, and wxWidgets will draw all button states using this bitmap. If
98e665d3
RD
180 the application needs more control, additional bitmaps for the selected state,
181 unpressed focused state, and greyed-out state may be supplied.
98e665d3 182 """
e811c8ce
RD
183 def __repr__(self):
184 return "<%s.%s; proxy of C++ wxBitmapButton instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 185 def __init__(self, *args, **kwargs):
0df68c9f 186 """
248ed943
RD
187 __init__(self, Window parent, int id=-1, Bitmap bitmap=wxNullBitmap,
188 Point pos=DefaultPosition, Size size=DefaultSize,
189 long style=BU_AUTODRAW, Validator validator=DefaultValidator,
b2dc1044 190 String name=ButtonNameStr) -> BitmapButton
0df68c9f 191
98e665d3 192 Create and show a button with a bitmap for the label.
0df68c9f 193 """
54f9ee45 194 newobj = _controls_.new_BitmapButton(*args, **kwargs)
d14a1e28
RD
195 self.this = newobj.this
196 self.thisown = 1
197 del newobj.thisown
198 self._setOORInfo(self)
e811c8ce
RD
199
200 def Create(*args, **kwargs):
0df68c9f 201 """
248ed943
RD
202 Create(self, Window parent, int id=-1, Bitmap bitmap=wxNullBitmap,
203 Point pos=DefaultPosition, Size size=DefaultSize,
204 long style=BU_AUTODRAW, Validator validator=DefaultValidator,
b2dc1044 205 String name=ButtonNameStr) -> bool
0df68c9f
RD
206
207 Acutally create the GUI BitmapButton for 2-phase creation.
208 """
54f9ee45 209 return _controls_.BitmapButton_Create(*args, **kwargs)
e811c8ce
RD
210
211 def GetBitmapLabel(*args, **kwargs):
0df68c9f 212 """
a95a7133 213 GetBitmapLabel(self) -> Bitmap
1e0c8722 214
0df68c9f
RD
215 Returns the label bitmap (the one passed to the constructor).
216 """
54f9ee45 217 return _controls_.BitmapButton_GetBitmapLabel(*args, **kwargs)
e811c8ce
RD
218
219 def GetBitmapDisabled(*args, **kwargs):
0df68c9f 220 """
a95a7133 221 GetBitmapDisabled(self) -> Bitmap
1e0c8722 222
0df68c9f
RD
223 Returns the bitmap for the disabled state.
224 """
54f9ee45 225 return _controls_.BitmapButton_GetBitmapDisabled(*args, **kwargs)
e811c8ce
RD
226
227 def GetBitmapFocus(*args, **kwargs):
0df68c9f 228 """
a95a7133 229 GetBitmapFocus(self) -> Bitmap
1e0c8722 230
0df68c9f
RD
231 Returns the bitmap for the focused state.
232 """
54f9ee45 233 return _controls_.BitmapButton_GetBitmapFocus(*args, **kwargs)
e811c8ce
RD
234
235 def GetBitmapSelected(*args, **kwargs):
0df68c9f 236 """
a95a7133 237 GetBitmapSelected(self) -> Bitmap
1e0c8722 238
0df68c9f
RD
239 Returns the bitmap for the selected state.
240 """
54f9ee45 241 return _controls_.BitmapButton_GetBitmapSelected(*args, **kwargs)
e811c8ce
RD
242
243 def SetBitmapDisabled(*args, **kwargs):
0df68c9f 244 """
a95a7133 245 SetBitmapDisabled(self, Bitmap bitmap)
1e0c8722 246
0df68c9f
RD
247 Sets the bitmap for the disabled button appearance.
248 """
54f9ee45 249 return _controls_.BitmapButton_SetBitmapDisabled(*args, **kwargs)
e811c8ce
RD
250
251 def SetBitmapFocus(*args, **kwargs):
0df68c9f 252 """
a95a7133 253 SetBitmapFocus(self, Bitmap bitmap)
1e0c8722 254
0df68c9f
RD
255 Sets the bitmap for the button appearance when it has the keyboard focus.
256 """
54f9ee45 257 return _controls_.BitmapButton_SetBitmapFocus(*args, **kwargs)
e811c8ce
RD
258
259 def SetBitmapSelected(*args, **kwargs):
0df68c9f 260 """
a95a7133 261 SetBitmapSelected(self, Bitmap bitmap)
1e0c8722 262
0df68c9f
RD
263 Sets the bitmap for the selected (depressed) button appearance.
264 """
54f9ee45 265 return _controls_.BitmapButton_SetBitmapSelected(*args, **kwargs)
e811c8ce
RD
266
267 def SetBitmapLabel(*args, **kwargs):
0df68c9f 268 """
a95a7133 269 SetBitmapLabel(self, Bitmap bitmap)
1e0c8722 270
0df68c9f
RD
271 Sets the bitmap label for the button. This is the bitmap used for the
272 unselected state, and for all other states if no other bitmaps are provided.
273 """
54f9ee45 274 return _controls_.BitmapButton_SetBitmapLabel(*args, **kwargs)
e811c8ce
RD
275
276 def SetMargins(*args, **kwargs):
a95a7133 277 """SetMargins(self, int x, int y)"""
54f9ee45 278 return _controls_.BitmapButton_SetMargins(*args, **kwargs)
e811c8ce
RD
279
280 def GetMarginX(*args, **kwargs):
a95a7133 281 """GetMarginX(self) -> int"""
54f9ee45 282 return _controls_.BitmapButton_GetMarginX(*args, **kwargs)
e811c8ce
RD
283
284 def GetMarginY(*args, **kwargs):
a95a7133 285 """GetMarginY(self) -> int"""
54f9ee45 286 return _controls_.BitmapButton_GetMarginY(*args, **kwargs)
e811c8ce 287
4120ef2b 288
d14a1e28
RD
289class BitmapButtonPtr(BitmapButton):
290 def __init__(self, this):
70551f47 291 self.this = this
d14a1e28
RD
292 if not hasattr(self,"thisown"): self.thisown = 0
293 self.__class__ = BitmapButton
54f9ee45 294_controls_.BitmapButton_swigregister(BitmapButtonPtr)
d14a1e28
RD
295
296def PreBitmapButton(*args, **kwargs):
0df68c9f
RD
297 """
298 PreBitmapButton() -> BitmapButton
1e0c8722 299
0df68c9f
RD
300 Precreate a BitmapButton for 2-phase creation.
301 """
54f9ee45 302 val = _controls_.new_PreBitmapButton(*args, **kwargs)
d14a1e28
RD
303 val.thisown = 1
304 return val
305
306#---------------------------------------------------------------------------
307
54f9ee45
RD
308CHK_2STATE = _controls_.CHK_2STATE
309CHK_3STATE = _controls_.CHK_3STATE
310CHK_ALLOW_3RD_STATE_FOR_USER = _controls_.CHK_ALLOW_3RD_STATE_FOR_USER
311CHK_UNCHECKED = _controls_.CHK_UNCHECKED
312CHK_CHECKED = _controls_.CHK_CHECKED
313CHK_UNDETERMINED = _controls_.CHK_UNDETERMINED
314class CheckBox(_core.Control):
fcafa8a9 315 """
66c033b4
RD
316 A checkbox is a labelled box which by default is either on (the
317 checkmark is visible) or off (no checkmark). Optionally (When the
318 wx.CHK_3STATE style flag is set) it can have a third state, called the
319 mixed or undetermined state. Often this is used as a "Does Not
320 Apply" state.
fcafa8a9 321 """
e811c8ce
RD
322 def __repr__(self):
323 return "<%s.%s; proxy of C++ wxCheckBox instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 324 def __init__(self, *args, **kwargs):
0df68c9f 325 """
248ed943
RD
326 __init__(self, Window parent, int id=-1, String label=EmptyString,
327 Point pos=DefaultPosition, Size size=DefaultSize,
328 long style=0, Validator validator=DefaultValidator,
329 String name=CheckBoxNameStr) -> CheckBox
fcafa8a9
RD
330
331 Creates and shows a CheckBox control
0df68c9f 332 """
54f9ee45 333 newobj = _controls_.new_CheckBox(*args, **kwargs)
d14a1e28 334 self.this = newobj.this
56f5d962 335 self.thisown = 1
d14a1e28 336 del newobj.thisown
0220cbc1 337 self._setOORInfo(self)
e811c8ce
RD
338
339 def Create(*args, **kwargs):
0df68c9f 340 """
248ed943
RD
341 Create(self, Window parent, int id=-1, String label=EmptyString,
342 Point pos=DefaultPosition, Size size=DefaultSize,
343 long style=0, Validator validator=DefaultValidator,
344 String name=CheckBoxNameStr) -> bool
fcafa8a9
RD
345
346 Actually create the GUI CheckBox for 2-phase creation.
0df68c9f 347 """
54f9ee45 348 return _controls_.CheckBox_Create(*args, **kwargs)
e811c8ce
RD
349
350 def GetValue(*args, **kwargs):
fcafa8a9 351 """
a95a7133 352 GetValue(self) -> bool
fcafa8a9
RD
353
354 Gets the state of a 2-state CheckBox. Returns True if it is checked,
355 False otherwise.
356 """
54f9ee45 357 return _controls_.CheckBox_GetValue(*args, **kwargs)
e811c8ce
RD
358
359 def IsChecked(*args, **kwargs):
fcafa8a9 360 """
a95a7133 361 IsChecked(self) -> bool
fcafa8a9 362
66c033b4
RD
363 Similar to GetValue, but raises an exception if it is not a 2-state
364 CheckBox.
fcafa8a9 365 """
54f9ee45 366 return _controls_.CheckBox_IsChecked(*args, **kwargs)
e811c8ce
RD
367
368 def SetValue(*args, **kwargs):
fcafa8a9 369 """
a95a7133 370 SetValue(self, bool state)
fcafa8a9 371
66c033b4
RD
372 Set the state of a 2-state CheckBox. Pass True for checked, False for
373 unchecked.
fcafa8a9 374 """
54f9ee45 375 return _controls_.CheckBox_SetValue(*args, **kwargs)
e811c8ce
RD
376
377 def Get3StateValue(*args, **kwargs):
fcafa8a9 378 """
a95a7133 379 Get3StateValue(self) -> int
fcafa8a9 380
66c033b4
RD
381 Returns wx.CHK_UNCHECKED when the CheckBox is unchecked,
382 wx.CHK_CHECKED when it is checked and wx.CHK_UNDETERMINED when it's in
383 the undetermined state. Raises an exceptiion when the function is
384 used with a 2-state CheckBox.
fcafa8a9 385 """
54f9ee45 386 return _controls_.CheckBox_Get3StateValue(*args, **kwargs)
e811c8ce
RD
387
388 def Set3StateValue(*args, **kwargs):
fcafa8a9 389 """
a95a7133 390 Set3StateValue(self, int state)
fcafa8a9 391
66c033b4
RD
392 Sets the CheckBox to the given state. The state parameter can be one
393 of the following: wx.CHK_UNCHECKED (Check is off), wx.CHK_CHECKED (the
394 Check is on) or wx.CHK_UNDETERMINED (Check is mixed). Raises an
395 exception when the CheckBox is a 2-state checkbox and setting the
396 state to wx.CHK_UNDETERMINED.
fcafa8a9 397 """
54f9ee45 398 return _controls_.CheckBox_Set3StateValue(*args, **kwargs)
e811c8ce
RD
399
400 def Is3State(*args, **kwargs):
fcafa8a9 401 """
a95a7133 402 Is3State(self) -> bool
fcafa8a9
RD
403
404 Returns whether or not the CheckBox is a 3-state CheckBox.
405 """
54f9ee45 406 return _controls_.CheckBox_Is3State(*args, **kwargs)
e811c8ce
RD
407
408 def Is3rdStateAllowedForUser(*args, **kwargs):
fcafa8a9 409 """
a95a7133 410 Is3rdStateAllowedForUser(self) -> bool
fcafa8a9 411
66c033b4
RD
412 Returns whether or not the user can set the CheckBox to the third
413 state.
fcafa8a9 414 """
54f9ee45 415 return _controls_.CheckBox_Is3rdStateAllowedForUser(*args, **kwargs)
e811c8ce 416
22bfe96c 417 def GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
418 """
419 GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
420
421 Get the default attributes for this class. This is useful if you want
422 to use the same font or colour in your own control as in a standard
423 control -- which is a much better idea than hard coding specific
424 colours or fonts which might look completely out of place on the
425 user's system, especially if it uses themes.
426
427 The variant parameter is only relevant under Mac currently and is
428 ignore under other platforms. Under Mac, it will change the size of
429 the returned font. See `wx.Window.SetWindowVariant` for more about
430 this.
431 """
22bfe96c
RD
432 return _controls_.CheckBox_GetClassDefaultAttributes(*args, **kwargs)
433
434 GetClassDefaultAttributes = staticmethod(GetClassDefaultAttributes)
70551f47 435
d14a1e28
RD
436class CheckBoxPtr(CheckBox):
437 def __init__(self, this):
438 self.this = this
439 if not hasattr(self,"thisown"): self.thisown = 0
440 self.__class__ = CheckBox
54f9ee45 441_controls_.CheckBox_swigregister(CheckBoxPtr)
b2dc1044 442CheckBoxNameStr = cvar.CheckBoxNameStr
70551f47 443
d14a1e28 444def PreCheckBox(*args, **kwargs):
fcafa8a9
RD
445 """
446 PreCheckBox() -> CheckBox
447
448 Precreate a CheckBox for 2-phase creation.
449 """
54f9ee45 450 val = _controls_.new_PreCheckBox(*args, **kwargs)
aa2a5b86
RD
451 val.thisown = 1
452 return val
453
22bfe96c 454def CheckBox_GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
455 """
456 CheckBox_GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
457
458 Get the default attributes for this class. This is useful if you want
459 to use the same font or colour in your own control as in a standard
460 control -- which is a much better idea than hard coding specific
461 colours or fonts which might look completely out of place on the
462 user's system, especially if it uses themes.
463
464 The variant parameter is only relevant under Mac currently and is
465 ignore under other platforms. Under Mac, it will change the size of
466 the returned font. See `wx.Window.SetWindowVariant` for more about
467 this.
468 """
22bfe96c
RD
469 return _controls_.CheckBox_GetClassDefaultAttributes(*args, **kwargs)
470
d14a1e28 471#---------------------------------------------------------------------------
70551f47 472
54f9ee45 473class Choice(_core.ControlWithItems):
fcafa8a9 474 """
66c033b4
RD
475 A Choice control is used to select one of a list of strings.
476 Unlike a `wx.ListBox`, only the selection is visible until the
477 user pulls down the menu of choices.
fcafa8a9 478 """
e811c8ce
RD
479 def __repr__(self):
480 return "<%s.%s; proxy of C++ wxChoice instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 481 def __init__(self, *args, **kwargs):
0df68c9f 482 """
fcafa8a9
RD
483 __init__(Window parent, int id, Point pos=DefaultPosition, Size size=DefaultSize,
484 List choices=[], long style=0, Validator validator=DefaultValidator,
b2dc1044 485 String name=ChoiceNameStr) -> Choice
fcafa8a9
RD
486
487 Create and show a Choice control
0df68c9f 488 """
54f9ee45 489 newobj = _controls_.new_Choice(*args, **kwargs)
d14a1e28
RD
490 self.this = newobj.this
491 self.thisown = 1
492 del newobj.thisown
493 self._setOORInfo(self)
e811c8ce
RD
494
495 def Create(*args, **kwargs):
0df68c9f 496 """
fcafa8a9
RD
497 Create(Window parent, int id, Point pos=DefaultPosition, Size size=DefaultSize,
498 List choices=[], long style=0, Validator validator=DefaultValidator,
b2dc1044 499 String name=ChoiceNameStr) -> bool
fd2dc343
RD
500
501 Actually create the GUI Choice control for 2-phase creation
0df68c9f 502 """
54f9ee45 503 return _controls_.Choice_Create(*args, **kwargs)
e811c8ce 504
22bfe96c 505 def GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
506 """
507 GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
508
509 Get the default attributes for this class. This is useful if you want
510 to use the same font or colour in your own control as in a standard
511 control -- which is a much better idea than hard coding specific
512 colours or fonts which might look completely out of place on the
513 user's system, especially if it uses themes.
514
515 The variant parameter is only relevant under Mac currently and is
516 ignore under other platforms. Under Mac, it will change the size of
517 the returned font. See `wx.Window.SetWindowVariant` for more about
518 this.
519 """
22bfe96c
RD
520 return _controls_.Choice_GetClassDefaultAttributes(*args, **kwargs)
521
522 GetClassDefaultAttributes = staticmethod(GetClassDefaultAttributes)
65191ae8 523
d14a1e28
RD
524class ChoicePtr(Choice):
525 def __init__(self, this):
526 self.this = this
527 if not hasattr(self,"thisown"): self.thisown = 0
528 self.__class__ = Choice
54f9ee45 529_controls_.Choice_swigregister(ChoicePtr)
b2dc1044 530ChoiceNameStr = cvar.ChoiceNameStr
65191ae8 531
d14a1e28 532def PreChoice(*args, **kwargs):
fcafa8a9
RD
533 """
534 PreChoice() -> Choice
535
536 Precreate a Choice control for 2-phase creation.
537 """
54f9ee45 538 val = _controls_.new_PreChoice(*args, **kwargs)
d14a1e28
RD
539 val.thisown = 1
540 return val
65191ae8 541
22bfe96c 542def Choice_GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
543 """
544 Choice_GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
545
546 Get the default attributes for this class. This is useful if you want
547 to use the same font or colour in your own control as in a standard
548 control -- which is a much better idea than hard coding specific
549 colours or fonts which might look completely out of place on the
550 user's system, especially if it uses themes.
551
552 The variant parameter is only relevant under Mac currently and is
553 ignore under other platforms. Under Mac, it will change the size of
554 the returned font. See `wx.Window.SetWindowVariant` for more about
555 this.
556 """
22bfe96c
RD
557 return _controls_.Choice_GetClassDefaultAttributes(*args, **kwargs)
558
d14a1e28 559#---------------------------------------------------------------------------
65191ae8 560
54f9ee45 561class ComboBox(_core.Control,_core.ItemContainer):
b88bce5f 562 """
41e2b43e
RD
563 A combobox is like a combination of an edit control and a
564 listbox. It can be displayed as static list with editable or
565 read-only text field; or a drop-down list with text field.
566
567 A combobox permits a single selection only. Combobox items are
568 numbered from zero.
b88bce5f 569 """
e811c8ce
RD
570 def __repr__(self):
571 return "<%s.%s; proxy of C++ wxComboBox instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 572 def __init__(self, *args, **kwargs):
0df68c9f 573 """
b88bce5f
RD
574 __init__(Window parent, int id, String value=EmptyString,
575 Point pos=DefaultPosition, Size size=DefaultSize,
41e2b43e
RD
576 List choices=[], long style=0, Validator validator=DefaultValidator,
577 String name=ComboBoxNameStr) -> ComboBox
b88bce5f
RD
578
579 Constructor, creates and shows a ComboBox control.
0df68c9f 580 """
54f9ee45 581 newobj = _controls_.new_ComboBox(*args, **kwargs)
d14a1e28 582 self.this = newobj.this
70551f47 583 self.thisown = 1
d14a1e28 584 del newobj.thisown
0220cbc1 585 self._setOORInfo(self)
e811c8ce
RD
586
587 def Create(*args, **kwargs):
0df68c9f 588 """
b88bce5f
RD
589 Create(Window parent, int id, String value=EmptyString,
590 Point pos=DefaultPosition, Size size=DefaultSize,
591 List choices=[], long style=0, Validator validator=DefaultValidator,
592 String name=ChoiceNameStr) -> bool
fd2dc343
RD
593
594 Actually create the GUI wxComboBox control for 2-phase creation
0df68c9f 595 """
54f9ee45 596 return _controls_.ComboBox_Create(*args, **kwargs)
e811c8ce
RD
597
598 def GetValue(*args, **kwargs):
b88bce5f 599 """
a95a7133 600 GetValue(self) -> String
b88bce5f
RD
601
602 Returns the current value in the combobox text field.
603 """
54f9ee45 604 return _controls_.ComboBox_GetValue(*args, **kwargs)
e811c8ce
RD
605
606 def SetValue(*args, **kwargs):
a95a7133 607 """SetValue(self, String value)"""
54f9ee45 608 return _controls_.ComboBox_SetValue(*args, **kwargs)
e811c8ce
RD
609
610 def Copy(*args, **kwargs):
b88bce5f 611 """
a95a7133 612 Copy(self)
b88bce5f
RD
613
614 Copies the selected text to the clipboard.
615 """
54f9ee45 616 return _controls_.ComboBox_Copy(*args, **kwargs)
e811c8ce
RD
617
618 def Cut(*args, **kwargs):
b88bce5f 619 """
a95a7133 620 Cut(self)
b88bce5f
RD
621
622 Copies the selected text to the clipboard and removes the selection.
623 """
54f9ee45 624 return _controls_.ComboBox_Cut(*args, **kwargs)
e811c8ce
RD
625
626 def Paste(*args, **kwargs):
b88bce5f 627 """
a95a7133 628 Paste(self)
b88bce5f
RD
629
630 Pastes text from the clipboard to the text field.
631 """
54f9ee45 632 return _controls_.ComboBox_Paste(*args, **kwargs)
e811c8ce
RD
633
634 def SetInsertionPoint(*args, **kwargs):
b88bce5f 635 """
a95a7133 636 SetInsertionPoint(self, long pos)
b88bce5f
RD
637
638 Sets the insertion point in the combobox text field.
639 """
54f9ee45 640 return _controls_.ComboBox_SetInsertionPoint(*args, **kwargs)
e811c8ce
RD
641
642 def GetInsertionPoint(*args, **kwargs):
b88bce5f 643 """
a95a7133 644 GetInsertionPoint(self) -> long
b88bce5f
RD
645
646 Returns the insertion point for the combobox's text field.
647 """
54f9ee45 648 return _controls_.ComboBox_GetInsertionPoint(*args, **kwargs)
e811c8ce
RD
649
650 def GetLastPosition(*args, **kwargs):
b88bce5f 651 """
a95a7133 652 GetLastPosition(self) -> long
b88bce5f
RD
653
654 Returns the last position in the combobox text field.
655 """
54f9ee45 656 return _controls_.ComboBox_GetLastPosition(*args, **kwargs)
e811c8ce
RD
657
658 def Replace(*args, **kwargs):
b88bce5f 659 """
a95a7133 660 Replace(self, long from, long to, String value)
b88bce5f
RD
661
662 Replaces the text between two positions with the given text, in the
663 combobox text field.
664 """
54f9ee45 665 return _controls_.ComboBox_Replace(*args, **kwargs)
fd3f2efe
RD
666
667 def SetSelection(*args, **kwargs):
b88bce5f 668 """
a95a7133 669 SetSelection(self, int n)
b88bce5f 670
121b9a67 671 Sets the item at index 'n' to be the selected item.
b88bce5f 672 """
54f9ee45 673 return _controls_.ComboBox_SetSelection(*args, **kwargs)
e811c8ce
RD
674
675 def SetMark(*args, **kwargs):
121b9a67
RD
676 """
677 SetMark(self, long from, long to)
678
679 Selects the text between the two positions in the combobox text field.
680 """
54f9ee45 681 return _controls_.ComboBox_SetMark(*args, **kwargs)
e811c8ce 682
b9d6a5f3
RD
683 def GetMark(*args, **kwargs):
684 """
685 GetMark(self) -> (from, to)
686
687 Gets the positions of the begining and ending of the selection mark in
688 the combobox text field.
689 """
690 return _controls_.ComboBox_GetMark(*args, **kwargs)
691
121b9a67
RD
692 def SetStringSelection(*args, **kwargs):
693 """
694 SetStringSelection(self, String string) -> bool
695
696 Select the item with the specifed string
697 """
698 return _controls_.ComboBox_SetStringSelection(*args, **kwargs)
699
700 def SetString(*args, **kwargs):
701 """
702 SetString(self, int n, String string)
703
704 Set the label for the n'th item (zero based) in the list.
705 """
706 return _controls_.ComboBox_SetString(*args, **kwargs)
707
e811c8ce 708 def SetEditable(*args, **kwargs):
a95a7133 709 """SetEditable(self, bool editable)"""
54f9ee45 710 return _controls_.ComboBox_SetEditable(*args, **kwargs)
e811c8ce
RD
711
712 def SetInsertionPointEnd(*args, **kwargs):
b88bce5f 713 """
a95a7133 714 SetInsertionPointEnd(self)
b88bce5f
RD
715
716 Sets the insertion point at the end of the combobox text field.
717 """
54f9ee45 718 return _controls_.ComboBox_SetInsertionPointEnd(*args, **kwargs)
e811c8ce
RD
719
720 def Remove(*args, **kwargs):
b88bce5f 721 """
a95a7133 722 Remove(self, long from, long to)
b88bce5f
RD
723
724 Removes the text between the two positions in the combobox text field.
725 """
54f9ee45 726 return _controls_.ComboBox_Remove(*args, **kwargs)
e811c8ce 727
5cbf236d
RD
728 def IsEditable(*args, **kwargs):
729 """
730 IsEditable(self) -> bool
731
732 Returns True if the combo is ediatable (not read-only.)
733 """
734 return _controls_.ComboBox_IsEditable(*args, **kwargs)
735
736 def Undo(*args, **kwargs):
737 """
738 Undo(self)
739
740 Redoes the last undo in the text field. Windows only.
741 """
742 return _controls_.ComboBox_Undo(*args, **kwargs)
743
744 def Redo(*args, **kwargs):
745 """
746 Redo(self)
747
748 Undoes the last edit in the text field. Windows only.
749 """
750 return _controls_.ComboBox_Redo(*args, **kwargs)
751
752 def SelectAll(*args, **kwargs):
753 """
754 SelectAll(self)
755
756 Select all the text in the combo's text field.
757 """
758 return _controls_.ComboBox_SelectAll(*args, **kwargs)
759
760 def CanCopy(*args, **kwargs):
761 """
762 CanCopy(self) -> bool
763
764 Returns True if the combobox is editable and there is a text selection
765 to copy to the clipboard. Only available on Windows.
766 """
767 return _controls_.ComboBox_CanCopy(*args, **kwargs)
768
769 def CanCut(*args, **kwargs):
770 """
771 CanCut(self) -> bool
772
773 Returns True if the combobox is editable and there is a text selection
774 to copy to the clipboard. Only available on Windows.
775 """
776 return _controls_.ComboBox_CanCut(*args, **kwargs)
777
778 def CanPaste(*args, **kwargs):
779 """
780 CanPaste(self) -> bool
781
782 Returns True if the combobox is editable and there is text on the
783 clipboard that can be pasted into the text field. Only available on
784 Windows.
785 """
786 return _controls_.ComboBox_CanPaste(*args, **kwargs)
787
788 def CanUndo(*args, **kwargs):
789 """
790 CanUndo(self) -> bool
791
792 Returns True if the combobox is editable and the last edit can be
793 undone. Only available on Windows.
794 """
795 return _controls_.ComboBox_CanUndo(*args, **kwargs)
796
797 def CanRedo(*args, **kwargs):
798 """
799 CanRedo(self) -> bool
800
801 Returns True if the combobox is editable and the last undo can be
802 redone. Only available on Windows.
803 """
804 return _controls_.ComboBox_CanRedo(*args, **kwargs)
805
22bfe96c 806 def GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
807 """
808 GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
809
810 Get the default attributes for this class. This is useful if you want
811 to use the same font or colour in your own control as in a standard
812 control -- which is a much better idea than hard coding specific
813 colours or fonts which might look completely out of place on the
814 user's system, especially if it uses themes.
815
816 The variant parameter is only relevant under Mac currently and is
817 ignore under other platforms. Under Mac, it will change the size of
818 the returned font. See `wx.Window.SetWindowVariant` for more about
819 this.
820 """
22bfe96c
RD
821 return _controls_.ComboBox_GetClassDefaultAttributes(*args, **kwargs)
822
823 GetClassDefaultAttributes = staticmethod(GetClassDefaultAttributes)
70551f47 824
d14a1e28
RD
825class ComboBoxPtr(ComboBox):
826 def __init__(self, this):
827 self.this = this
828 if not hasattr(self,"thisown"): self.thisown = 0
829 self.__class__ = ComboBox
54f9ee45 830_controls_.ComboBox_swigregister(ComboBoxPtr)
b2dc1044 831ComboBoxNameStr = cvar.ComboBoxNameStr
70551f47 832
d14a1e28 833def PreComboBox(*args, **kwargs):
b88bce5f
RD
834 """
835 PreComboBox() -> ComboBox
836
837 Precreate a ComboBox control for 2-phase creation.
838 """
54f9ee45 839 val = _controls_.new_PreComboBox(*args, **kwargs)
aa2a5b86
RD
840 val.thisown = 1
841 return val
842
22bfe96c 843def ComboBox_GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
844 """
845 ComboBox_GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
846
847 Get the default attributes for this class. This is useful if you want
848 to use the same font or colour in your own control as in a standard
849 control -- which is a much better idea than hard coding specific
850 colours or fonts which might look completely out of place on the
851 user's system, especially if it uses themes.
852
853 The variant parameter is only relevant under Mac currently and is
854 ignore under other platforms. Under Mac, it will change the size of
855 the returned font. See `wx.Window.SetWindowVariant` for more about
856 this.
857 """
22bfe96c
RD
858 return _controls_.ComboBox_GetClassDefaultAttributes(*args, **kwargs)
859
d14a1e28 860#---------------------------------------------------------------------------
70551f47 861
54f9ee45
RD
862GA_HORIZONTAL = _controls_.GA_HORIZONTAL
863GA_VERTICAL = _controls_.GA_VERTICAL
864GA_SMOOTH = _controls_.GA_SMOOTH
865GA_PROGRESSBAR = _controls_.GA_PROGRESSBAR
866class Gauge(_core.Control):
093d3ff1 867 """Proxy of C++ Gauge class"""
e811c8ce
RD
868 def __repr__(self):
869 return "<%s.%s; proxy of C++ wxGauge instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 870 def __init__(self, *args, **kwargs):
0df68c9f 871 """
248ed943 872 __init__(self, Window parent, int id=-1, int range=100, Point pos=DefaultPosition,
0df68c9f
RD
873 Size size=DefaultSize, long style=GA_HORIZONTAL,
874 Validator validator=DefaultValidator,
b2dc1044 875 String name=GaugeNameStr) -> Gauge
0df68c9f 876 """
54f9ee45 877 newobj = _controls_.new_Gauge(*args, **kwargs)
d14a1e28 878 self.this = newobj.this
70551f47 879 self.thisown = 1
d14a1e28 880 del newobj.thisown
0220cbc1 881 self._setOORInfo(self)
e811c8ce
RD
882
883 def Create(*args, **kwargs):
0df68c9f 884 """
248ed943 885 Create(self, Window parent, int id=-1, int range=100, Point pos=DefaultPosition,
0df68c9f
RD
886 Size size=DefaultSize, long style=GA_HORIZONTAL,
887 Validator validator=DefaultValidator,
b2dc1044 888 String name=GaugeNameStr) -> bool
0df68c9f 889 """
54f9ee45 890 return _controls_.Gauge_Create(*args, **kwargs)
e811c8ce
RD
891
892 def SetRange(*args, **kwargs):
a95a7133 893 """SetRange(self, int range)"""
54f9ee45 894 return _controls_.Gauge_SetRange(*args, **kwargs)
e811c8ce
RD
895
896 def GetRange(*args, **kwargs):
a95a7133 897 """GetRange(self) -> int"""
54f9ee45 898 return _controls_.Gauge_GetRange(*args, **kwargs)
e811c8ce
RD
899
900 def SetValue(*args, **kwargs):
a95a7133 901 """SetValue(self, int pos)"""
54f9ee45 902 return _controls_.Gauge_SetValue(*args, **kwargs)
e811c8ce
RD
903
904 def GetValue(*args, **kwargs):
a95a7133 905 """GetValue(self) -> int"""
54f9ee45 906 return _controls_.Gauge_GetValue(*args, **kwargs)
e811c8ce
RD
907
908 def IsVertical(*args, **kwargs):
a95a7133 909 """IsVertical(self) -> bool"""
54f9ee45 910 return _controls_.Gauge_IsVertical(*args, **kwargs)
e811c8ce
RD
911
912 def SetShadowWidth(*args, **kwargs):
a95a7133 913 """SetShadowWidth(self, int w)"""
54f9ee45 914 return _controls_.Gauge_SetShadowWidth(*args, **kwargs)
e811c8ce
RD
915
916 def GetShadowWidth(*args, **kwargs):
a95a7133 917 """GetShadowWidth(self) -> int"""
54f9ee45 918 return _controls_.Gauge_GetShadowWidth(*args, **kwargs)
e811c8ce
RD
919
920 def SetBezelFace(*args, **kwargs):
a95a7133 921 """SetBezelFace(self, int w)"""
54f9ee45 922 return _controls_.Gauge_SetBezelFace(*args, **kwargs)
e811c8ce
RD
923
924 def GetBezelFace(*args, **kwargs):
a95a7133 925 """GetBezelFace(self) -> int"""
54f9ee45 926 return _controls_.Gauge_GetBezelFace(*args, **kwargs)
e811c8ce 927
22bfe96c 928 def GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
929 """
930 GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
931
932 Get the default attributes for this class. This is useful if you want
933 to use the same font or colour in your own control as in a standard
934 control -- which is a much better idea than hard coding specific
935 colours or fonts which might look completely out of place on the
936 user's system, especially if it uses themes.
937
938 The variant parameter is only relevant under Mac currently and is
939 ignore under other platforms. Under Mac, it will change the size of
940 the returned font. See `wx.Window.SetWindowVariant` for more about
941 this.
942 """
22bfe96c
RD
943 return _controls_.Gauge_GetClassDefaultAttributes(*args, **kwargs)
944
945 GetClassDefaultAttributes = staticmethod(GetClassDefaultAttributes)
70551f47 946
d14a1e28
RD
947class GaugePtr(Gauge):
948 def __init__(self, this):
949 self.this = this
950 if not hasattr(self,"thisown"): self.thisown = 0
951 self.__class__ = Gauge
54f9ee45 952_controls_.Gauge_swigregister(GaugePtr)
b2dc1044 953GaugeNameStr = cvar.GaugeNameStr
70551f47 954
d14a1e28 955def PreGauge(*args, **kwargs):
e811c8ce 956 """PreGauge() -> Gauge"""
54f9ee45 957 val = _controls_.new_PreGauge(*args, **kwargs)
aa2a5b86
RD
958 val.thisown = 1
959 return val
960
22bfe96c 961def Gauge_GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
962 """
963 Gauge_GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
964
965 Get the default attributes for this class. This is useful if you want
966 to use the same font or colour in your own control as in a standard
967 control -- which is a much better idea than hard coding specific
968 colours or fonts which might look completely out of place on the
969 user's system, especially if it uses themes.
970
971 The variant parameter is only relevant under Mac currently and is
972 ignore under other platforms. Under Mac, it will change the size of
973 the returned font. See `wx.Window.SetWindowVariant` for more about
974 this.
975 """
22bfe96c
RD
976 return _controls_.Gauge_GetClassDefaultAttributes(*args, **kwargs)
977
d14a1e28 978#---------------------------------------------------------------------------
70551f47 979
54f9ee45 980class StaticBox(_core.Control):
093d3ff1 981 """Proxy of C++ StaticBox class"""
e811c8ce
RD
982 def __repr__(self):
983 return "<%s.%s; proxy of C++ wxStaticBox instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 984 def __init__(self, *args, **kwargs):
0df68c9f 985 """
248ed943
RD
986 __init__(self, Window parent, int id=-1, String label=EmptyString,
987 Point pos=DefaultPosition, Size size=DefaultSize,
988 long style=0, String name=StaticBoxNameStr) -> StaticBox
0df68c9f 989 """
54f9ee45 990 newobj = _controls_.new_StaticBox(*args, **kwargs)
d14a1e28 991 self.this = newobj.this
70551f47 992 self.thisown = 1
d14a1e28 993 del newobj.thisown
0220cbc1 994 self._setOORInfo(self)
e811c8ce
RD
995
996 def Create(*args, **kwargs):
0df68c9f 997 """
248ed943
RD
998 Create(self, Window parent, int id=-1, String label=EmptyString,
999 Point pos=DefaultPosition, Size size=DefaultSize,
1000 long style=0, String name=StaticBoxNameStr) -> bool
0df68c9f 1001 """
54f9ee45 1002 return _controls_.StaticBox_Create(*args, **kwargs)
e811c8ce 1003
22bfe96c 1004 def GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
1005 """
1006 GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
1007
1008 Get the default attributes for this class. This is useful if you want
1009 to use the same font or colour in your own control as in a standard
1010 control -- which is a much better idea than hard coding specific
1011 colours or fonts which might look completely out of place on the
1012 user's system, especially if it uses themes.
1013
1014 The variant parameter is only relevant under Mac currently and is
1015 ignore under other platforms. Under Mac, it will change the size of
1016 the returned font. See `wx.Window.SetWindowVariant` for more about
1017 this.
1018 """
22bfe96c
RD
1019 return _controls_.StaticBox_GetClassDefaultAttributes(*args, **kwargs)
1020
1021 GetClassDefaultAttributes = staticmethod(GetClassDefaultAttributes)
70551f47 1022
d14a1e28
RD
1023class StaticBoxPtr(StaticBox):
1024 def __init__(self, this):
1025 self.this = this
1026 if not hasattr(self,"thisown"): self.thisown = 0
1027 self.__class__ = StaticBox
54f9ee45 1028_controls_.StaticBox_swigregister(StaticBoxPtr)
b2dc1044
RD
1029StaticBitmapNameStr = cvar.StaticBitmapNameStr
1030StaticBoxNameStr = cvar.StaticBoxNameStr
1031StaticTextNameStr = cvar.StaticTextNameStr
70551f47 1032
d14a1e28 1033def PreStaticBox(*args, **kwargs):
e811c8ce 1034 """PreStaticBox() -> StaticBox"""
54f9ee45 1035 val = _controls_.new_PreStaticBox(*args, **kwargs)
aa2a5b86
RD
1036 val.thisown = 1
1037 return val
1038
22bfe96c 1039def StaticBox_GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
1040 """
1041 StaticBox_GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
1042
1043 Get the default attributes for this class. This is useful if you want
1044 to use the same font or colour in your own control as in a standard
1045 control -- which is a much better idea than hard coding specific
1046 colours or fonts which might look completely out of place on the
1047 user's system, especially if it uses themes.
1048
1049 The variant parameter is only relevant under Mac currently and is
1050 ignore under other platforms. Under Mac, it will change the size of
1051 the returned font. See `wx.Window.SetWindowVariant` for more about
1052 this.
1053 """
22bfe96c
RD
1054 return _controls_.StaticBox_GetClassDefaultAttributes(*args, **kwargs)
1055
d14a1e28 1056#---------------------------------------------------------------------------
70551f47 1057
54f9ee45 1058class StaticLine(_core.Control):
093d3ff1 1059 """Proxy of C++ StaticLine class"""
e811c8ce
RD
1060 def __repr__(self):
1061 return "<%s.%s; proxy of C++ wxStaticLine instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 1062 def __init__(self, *args, **kwargs):
0df68c9f 1063 """
248ed943
RD
1064 __init__(self, Window parent, int id=-1, Point pos=DefaultPosition,
1065 Size size=DefaultSize, long style=LI_HORIZONTAL,
b2dc1044 1066 String name=StaticTextNameStr) -> StaticLine
0df68c9f 1067 """
54f9ee45 1068 newobj = _controls_.new_StaticLine(*args, **kwargs)
d14a1e28 1069 self.this = newobj.this
70551f47 1070 self.thisown = 1
d14a1e28 1071 del newobj.thisown
0220cbc1 1072 self._setOORInfo(self)
e811c8ce
RD
1073
1074 def Create(*args, **kwargs):
0df68c9f 1075 """
248ed943
RD
1076 Create(self, Window parent, int id=-1, Point pos=DefaultPosition,
1077 Size size=DefaultSize, long style=LI_HORIZONTAL,
b2dc1044 1078 String name=StaticTextNameStr) -> bool
0df68c9f 1079 """
54f9ee45 1080 return _controls_.StaticLine_Create(*args, **kwargs)
e811c8ce
RD
1081
1082 def IsVertical(*args, **kwargs):
a95a7133 1083 """IsVertical(self) -> bool"""
54f9ee45 1084 return _controls_.StaticLine_IsVertical(*args, **kwargs)
e811c8ce
RD
1085
1086 def GetDefaultSize(*args, **kwargs):
66c033b4 1087 """GetDefaultSize() -> int"""
54f9ee45 1088 return _controls_.StaticLine_GetDefaultSize(*args, **kwargs)
e811c8ce
RD
1089
1090 GetDefaultSize = staticmethod(GetDefaultSize)
22bfe96c 1091 def GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
1092 """
1093 GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
1094
1095 Get the default attributes for this class. This is useful if you want
1096 to use the same font or colour in your own control as in a standard
1097 control -- which is a much better idea than hard coding specific
1098 colours or fonts which might look completely out of place on the
1099 user's system, especially if it uses themes.
1100
1101 The variant parameter is only relevant under Mac currently and is
1102 ignore under other platforms. Under Mac, it will change the size of
1103 the returned font. See `wx.Window.SetWindowVariant` for more about
1104 this.
1105 """
22bfe96c
RD
1106 return _controls_.StaticLine_GetClassDefaultAttributes(*args, **kwargs)
1107
1108 GetClassDefaultAttributes = staticmethod(GetClassDefaultAttributes)
70551f47 1109
d14a1e28
RD
1110class StaticLinePtr(StaticLine):
1111 def __init__(self, this):
1112 self.this = this
1113 if not hasattr(self,"thisown"): self.thisown = 0
1114 self.__class__ = StaticLine
54f9ee45 1115_controls_.StaticLine_swigregister(StaticLinePtr)
70551f47 1116
d14a1e28 1117def PreStaticLine(*args, **kwargs):
e811c8ce 1118 """PreStaticLine() -> StaticLine"""
54f9ee45 1119 val = _controls_.new_PreStaticLine(*args, **kwargs)
aa2a5b86
RD
1120 val.thisown = 1
1121 return val
1122
e811c8ce
RD
1123def StaticLine_GetDefaultSize(*args, **kwargs):
1124 """StaticLine_GetDefaultSize() -> int"""
54f9ee45 1125 return _controls_.StaticLine_GetDefaultSize(*args, **kwargs)
70551f47 1126
22bfe96c 1127def StaticLine_GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
1128 """
1129 StaticLine_GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
1130
1131 Get the default attributes for this class. This is useful if you want
1132 to use the same font or colour in your own control as in a standard
1133 control -- which is a much better idea than hard coding specific
1134 colours or fonts which might look completely out of place on the
1135 user's system, especially if it uses themes.
1136
1137 The variant parameter is only relevant under Mac currently and is
1138 ignore under other platforms. Under Mac, it will change the size of
1139 the returned font. See `wx.Window.SetWindowVariant` for more about
1140 this.
1141 """
22bfe96c
RD
1142 return _controls_.StaticLine_GetClassDefaultAttributes(*args, **kwargs)
1143
d14a1e28
RD
1144#---------------------------------------------------------------------------
1145
54f9ee45 1146class StaticText(_core.Control):
093d3ff1 1147 """Proxy of C++ StaticText class"""
e811c8ce
RD
1148 def __repr__(self):
1149 return "<%s.%s; proxy of C++ wxStaticText instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 1150 def __init__(self, *args, **kwargs):
0df68c9f 1151 """
248ed943
RD
1152 __init__(self, Window parent, int id=-1, String label=EmptyString,
1153 Point pos=DefaultPosition, Size size=DefaultSize,
1154 long style=0, String name=StaticTextNameStr) -> StaticText
0df68c9f 1155 """
54f9ee45 1156 newobj = _controls_.new_StaticText(*args, **kwargs)
d14a1e28 1157 self.this = newobj.this
70551f47 1158 self.thisown = 1
d14a1e28 1159 del newobj.thisown
0220cbc1 1160 self._setOORInfo(self)
e811c8ce
RD
1161
1162 def Create(*args, **kwargs):
0df68c9f 1163 """
248ed943
RD
1164 Create(self, Window parent, int id=-1, String label=EmptyString,
1165 Point pos=DefaultPosition, Size size=DefaultSize,
1166 long style=0, String name=StaticTextNameStr) -> bool
0df68c9f 1167 """
54f9ee45 1168 return _controls_.StaticText_Create(*args, **kwargs)
e811c8ce 1169
22bfe96c 1170 def GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
1171 """
1172 GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
1173
1174 Get the default attributes for this class. This is useful if you want
1175 to use the same font or colour in your own control as in a standard
1176 control -- which is a much better idea than hard coding specific
1177 colours or fonts which might look completely out of place on the
1178 user's system, especially if it uses themes.
1179
1180 The variant parameter is only relevant under Mac currently and is
1181 ignore under other platforms. Under Mac, it will change the size of
1182 the returned font. See `wx.Window.SetWindowVariant` for more about
1183 this.
1184 """
22bfe96c
RD
1185 return _controls_.StaticText_GetClassDefaultAttributes(*args, **kwargs)
1186
1187 GetClassDefaultAttributes = staticmethod(GetClassDefaultAttributes)
70551f47 1188
d14a1e28
RD
1189class StaticTextPtr(StaticText):
1190 def __init__(self, this):
1191 self.this = this
1192 if not hasattr(self,"thisown"): self.thisown = 0
1193 self.__class__ = StaticText
54f9ee45 1194_controls_.StaticText_swigregister(StaticTextPtr)
70551f47 1195
d14a1e28 1196def PreStaticText(*args, **kwargs):
e811c8ce 1197 """PreStaticText() -> StaticText"""
54f9ee45 1198 val = _controls_.new_PreStaticText(*args, **kwargs)
aa2a5b86
RD
1199 val.thisown = 1
1200 return val
1201
22bfe96c 1202def StaticText_GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
1203 """
1204 StaticText_GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
1205
1206 Get the default attributes for this class. This is useful if you want
1207 to use the same font or colour in your own control as in a standard
1208 control -- which is a much better idea than hard coding specific
1209 colours or fonts which might look completely out of place on the
1210 user's system, especially if it uses themes.
1211
1212 The variant parameter is only relevant under Mac currently and is
1213 ignore under other platforms. Under Mac, it will change the size of
1214 the returned font. See `wx.Window.SetWindowVariant` for more about
1215 this.
1216 """
22bfe96c
RD
1217 return _controls_.StaticText_GetClassDefaultAttributes(*args, **kwargs)
1218
d14a1e28 1219#---------------------------------------------------------------------------
70551f47 1220
54f9ee45 1221class StaticBitmap(_core.Control):
093d3ff1 1222 """Proxy of C++ StaticBitmap class"""
e811c8ce
RD
1223 def __repr__(self):
1224 return "<%s.%s; proxy of C++ wxStaticBitmap instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 1225 def __init__(self, *args, **kwargs):
0df68c9f 1226 """
248ed943
RD
1227 __init__(self, Window parent, int id=-1, Bitmap bitmap=wxNullBitmap,
1228 Point pos=DefaultPosition, Size size=DefaultSize,
1229 long style=0, String name=StaticBitmapNameStr) -> StaticBitmap
0df68c9f 1230 """
54f9ee45 1231 newobj = _controls_.new_StaticBitmap(*args, **kwargs)
d14a1e28 1232 self.this = newobj.this
70551f47 1233 self.thisown = 1
d14a1e28 1234 del newobj.thisown
4f89f6a3
RD
1235 self._setOORInfo(self)
1236
e811c8ce 1237 def Create(*args, **kwargs):
0df68c9f 1238 """
248ed943
RD
1239 Create(self, Window parent, int id=-1, Bitmap bitmap=wxNullBitmap,
1240 Point pos=DefaultPosition, Size size=DefaultSize,
1241 long style=0, String name=StaticBitmapNameStr) -> bool
0df68c9f 1242 """
54f9ee45 1243 return _controls_.StaticBitmap_Create(*args, **kwargs)
e811c8ce
RD
1244
1245 def GetBitmap(*args, **kwargs):
a95a7133 1246 """GetBitmap(self) -> Bitmap"""
54f9ee45 1247 return _controls_.StaticBitmap_GetBitmap(*args, **kwargs)
e811c8ce
RD
1248
1249 def SetBitmap(*args, **kwargs):
a95a7133 1250 """SetBitmap(self, Bitmap bitmap)"""
54f9ee45 1251 return _controls_.StaticBitmap_SetBitmap(*args, **kwargs)
e811c8ce
RD
1252
1253 def SetIcon(*args, **kwargs):
a95a7133 1254 """SetIcon(self, Icon icon)"""
54f9ee45 1255 return _controls_.StaticBitmap_SetIcon(*args, **kwargs)
e811c8ce 1256
22bfe96c 1257 def GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
1258 """
1259 GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
1260
1261 Get the default attributes for this class. This is useful if you want
1262 to use the same font or colour in your own control as in a standard
1263 control -- which is a much better idea than hard coding specific
1264 colours or fonts which might look completely out of place on the
1265 user's system, especially if it uses themes.
1266
1267 The variant parameter is only relevant under Mac currently and is
1268 ignore under other platforms. Under Mac, it will change the size of
1269 the returned font. See `wx.Window.SetWindowVariant` for more about
1270 this.
1271 """
22bfe96c
RD
1272 return _controls_.StaticBitmap_GetClassDefaultAttributes(*args, **kwargs)
1273
1274 GetClassDefaultAttributes = staticmethod(GetClassDefaultAttributes)
70551f47 1275
d14a1e28
RD
1276class StaticBitmapPtr(StaticBitmap):
1277 def __init__(self, this):
1278 self.this = this
1279 if not hasattr(self,"thisown"): self.thisown = 0
1280 self.__class__ = StaticBitmap
54f9ee45 1281_controls_.StaticBitmap_swigregister(StaticBitmapPtr)
70551f47 1282
d14a1e28 1283def PreStaticBitmap(*args, **kwargs):
e811c8ce 1284 """PreStaticBitmap() -> StaticBitmap"""
54f9ee45 1285 val = _controls_.new_PreStaticBitmap(*args, **kwargs)
aa2a5b86
RD
1286 val.thisown = 1
1287 return val
1288
22bfe96c 1289def StaticBitmap_GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
1290 """
1291 StaticBitmap_GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
1292
1293 Get the default attributes for this class. This is useful if you want
1294 to use the same font or colour in your own control as in a standard
1295 control -- which is a much better idea than hard coding specific
1296 colours or fonts which might look completely out of place on the
1297 user's system, especially if it uses themes.
1298
1299 The variant parameter is only relevant under Mac currently and is
1300 ignore under other platforms. Under Mac, it will change the size of
1301 the returned font. See `wx.Window.SetWindowVariant` for more about
1302 this.
1303 """
22bfe96c
RD
1304 return _controls_.StaticBitmap_GetClassDefaultAttributes(*args, **kwargs)
1305
d14a1e28 1306#---------------------------------------------------------------------------
70551f47 1307
54f9ee45 1308class ListBox(_core.ControlWithItems):
093d3ff1 1309 """Proxy of C++ ListBox class"""
e811c8ce
RD
1310 def __repr__(self):
1311 return "<%s.%s; proxy of C++ wxListBox instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 1312 def __init__(self, *args, **kwargs):
0df68c9f 1313 """
248ed943
RD
1314 __init__(self, Window parent, int id=-1, Point pos=DefaultPosition,
1315 Size size=DefaultSize, wxArrayString choices=wxPyEmptyStringArray,
0df68c9f 1316 long style=0, Validator validator=DefaultValidator,
b2dc1044 1317 String name=ListBoxNameStr) -> ListBox
0df68c9f 1318 """
54f9ee45 1319 newobj = _controls_.new_ListBox(*args, **kwargs)
d14a1e28 1320 self.this = newobj.this
70551f47 1321 self.thisown = 1
d14a1e28 1322 del newobj.thisown
0220cbc1 1323 self._setOORInfo(self)
e811c8ce
RD
1324
1325 def Create(*args, **kwargs):
0df68c9f 1326 """
248ed943
RD
1327 Create(self, Window parent, int id=-1, Point pos=DefaultPosition,
1328 Size size=DefaultSize, wxArrayString choices=wxPyEmptyStringArray,
0df68c9f 1329 long style=0, Validator validator=DefaultValidator,
b2dc1044 1330 String name=ListBoxNameStr) -> bool
0df68c9f 1331 """
54f9ee45 1332 return _controls_.ListBox_Create(*args, **kwargs)
e811c8ce
RD
1333
1334 def Insert(*args, **kwargs):
15afbcd0 1335 """
a95a7133 1336 Insert(self, String item, int pos, PyObject clientData=None)
15afbcd0 1337
41e2b43e 1338 Insert an item into the control before the item at the ``pos`` index,
15afbcd0
RD
1339 optionally associating some data object with the item.
1340 """
54f9ee45 1341 return _controls_.ListBox_Insert(*args, **kwargs)
e811c8ce
RD
1342
1343 def InsertItems(*args, **kwargs):
a95a7133 1344 """InsertItems(self, wxArrayString items, int pos)"""
54f9ee45 1345 return _controls_.ListBox_InsertItems(*args, **kwargs)
e811c8ce
RD
1346
1347 def Set(*args, **kwargs):
a95a7133 1348 """Set(self, wxArrayString items)"""
54f9ee45 1349 return _controls_.ListBox_Set(*args, **kwargs)
e811c8ce
RD
1350
1351 def IsSelected(*args, **kwargs):
a95a7133 1352 """IsSelected(self, int n) -> bool"""
54f9ee45 1353 return _controls_.ListBox_IsSelected(*args, **kwargs)
e811c8ce
RD
1354
1355 def SetSelection(*args, **kwargs):
a95a7133 1356 """SetSelection(self, int n, bool select=True)"""
54f9ee45 1357 return _controls_.ListBox_SetSelection(*args, **kwargs)
e811c8ce
RD
1358
1359 def Select(*args, **kwargs):
15afbcd0 1360 """
a95a7133 1361 Select(self, int n)
15afbcd0 1362
53aa7709
RD
1363 This is the same as `SetSelection` and exists only because it is
1364 slightly more natural for controls which support multiple selection.
15afbcd0 1365 """
54f9ee45 1366 return _controls_.ListBox_Select(*args, **kwargs)
e811c8ce
RD
1367
1368 def Deselect(*args, **kwargs):
a95a7133 1369 """Deselect(self, int n)"""
54f9ee45 1370 return _controls_.ListBox_Deselect(*args, **kwargs)
e811c8ce
RD
1371
1372 def DeselectAll(*args, **kwargs):
a95a7133 1373 """DeselectAll(self, int itemToLeaveSelected=-1)"""
54f9ee45 1374 return _controls_.ListBox_DeselectAll(*args, **kwargs)
e811c8ce
RD
1375
1376 def SetStringSelection(*args, **kwargs):
a95a7133 1377 """SetStringSelection(self, String s, bool select=True) -> bool"""
54f9ee45 1378 return _controls_.ListBox_SetStringSelection(*args, **kwargs)
e811c8ce
RD
1379
1380 def GetSelections(*args, **kwargs):
a95a7133 1381 """GetSelections(self) -> PyObject"""
54f9ee45 1382 return _controls_.ListBox_GetSelections(*args, **kwargs)
e811c8ce
RD
1383
1384 def SetFirstItem(*args, **kwargs):
a95a7133 1385 """SetFirstItem(self, int n)"""
54f9ee45 1386 return _controls_.ListBox_SetFirstItem(*args, **kwargs)
e811c8ce
RD
1387
1388 def SetFirstItemStr(*args, **kwargs):
a95a7133 1389 """SetFirstItemStr(self, String s)"""
54f9ee45 1390 return _controls_.ListBox_SetFirstItemStr(*args, **kwargs)
e811c8ce
RD
1391
1392 def EnsureVisible(*args, **kwargs):
a95a7133 1393 """EnsureVisible(self, int n)"""
54f9ee45 1394 return _controls_.ListBox_EnsureVisible(*args, **kwargs)
e811c8ce
RD
1395
1396 def AppendAndEnsureVisible(*args, **kwargs):
a95a7133 1397 """AppendAndEnsureVisible(self, String s)"""
54f9ee45 1398 return _controls_.ListBox_AppendAndEnsureVisible(*args, **kwargs)
e811c8ce
RD
1399
1400 def IsSorted(*args, **kwargs):
a95a7133 1401 """IsSorted(self) -> bool"""
54f9ee45 1402 return _controls_.ListBox_IsSorted(*args, **kwargs)
e811c8ce 1403
c3eb6258 1404 def SetItemForegroundColour(*args, **kwargs):
a95a7133 1405 """SetItemForegroundColour(self, int item, Colour c)"""
54f9ee45 1406 return _controls_.ListBox_SetItemForegroundColour(*args, **kwargs)
c3eb6258
RD
1407
1408 def SetItemBackgroundColour(*args, **kwargs):
a95a7133 1409 """SetItemBackgroundColour(self, int item, Colour c)"""
54f9ee45 1410 return _controls_.ListBox_SetItemBackgroundColour(*args, **kwargs)
c3eb6258
RD
1411
1412 def SetItemFont(*args, **kwargs):
a95a7133 1413 """SetItemFont(self, int item, Font f)"""
54f9ee45 1414 return _controls_.ListBox_SetItemFont(*args, **kwargs)
c3eb6258 1415
74a57fcd 1416 def GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
1417 """
1418 GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
1419
1420 Get the default attributes for this class. This is useful if you want
1421 to use the same font or colour in your own control as in a standard
1422 control -- which is a much better idea than hard coding specific
1423 colours or fonts which might look completely out of place on the
1424 user's system, especially if it uses themes.
1425
1426 The variant parameter is only relevant under Mac currently and is
1427 ignore under other platforms. Under Mac, it will change the size of
1428 the returned font. See `wx.Window.SetWindowVariant` for more about
1429 this.
1430 """
54f9ee45 1431 return _controls_.ListBox_GetClassDefaultAttributes(*args, **kwargs)
74a57fcd
RD
1432
1433 GetClassDefaultAttributes = staticmethod(GetClassDefaultAttributes)
70551f47 1434
d14a1e28
RD
1435class ListBoxPtr(ListBox):
1436 def __init__(self, this):
1437 self.this = this
1438 if not hasattr(self,"thisown"): self.thisown = 0
1439 self.__class__ = ListBox
54f9ee45 1440_controls_.ListBox_swigregister(ListBoxPtr)
b2dc1044 1441ListBoxNameStr = cvar.ListBoxNameStr
70551f47 1442
d14a1e28 1443def PreListBox(*args, **kwargs):
e811c8ce 1444 """PreListBox() -> ListBox"""
54f9ee45 1445 val = _controls_.new_PreListBox(*args, **kwargs)
aa2a5b86
RD
1446 val.thisown = 1
1447 return val
1448
74a57fcd 1449def ListBox_GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
1450 """
1451 ListBox_GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
1452
1453 Get the default attributes for this class. This is useful if you want
1454 to use the same font or colour in your own control as in a standard
1455 control -- which is a much better idea than hard coding specific
1456 colours or fonts which might look completely out of place on the
1457 user's system, especially if it uses themes.
1458
1459 The variant parameter is only relevant under Mac currently and is
1460 ignore under other platforms. Under Mac, it will change the size of
1461 the returned font. See `wx.Window.SetWindowVariant` for more about
1462 this.
1463 """
54f9ee45 1464 return _controls_.ListBox_GetClassDefaultAttributes(*args, **kwargs)
74a57fcd 1465
d14a1e28 1466#---------------------------------------------------------------------------
70551f47 1467
d14a1e28 1468class CheckListBox(ListBox):
093d3ff1 1469 """Proxy of C++ CheckListBox class"""
e811c8ce
RD
1470 def __repr__(self):
1471 return "<%s.%s; proxy of C++ wxCheckListBox instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 1472 def __init__(self, *args, **kwargs):
0df68c9f 1473 """
248ed943
RD
1474 __init__(self, Window parent, int id=-1, Point pos=DefaultPosition,
1475 Size size=DefaultSize, wxArrayString choices=wxPyEmptyStringArray,
0df68c9f 1476 long style=0, Validator validator=DefaultValidator,
b2dc1044 1477 String name=ListBoxNameStr) -> CheckListBox
0df68c9f 1478 """
54f9ee45 1479 newobj = _controls_.new_CheckListBox(*args, **kwargs)
d14a1e28
RD
1480 self.this = newobj.this
1481 self.thisown = 1
1482 del newobj.thisown
33b885b9
RD
1483 self._setOORInfo(self)
1484
e811c8ce 1485 def Create(*args, **kwargs):
0df68c9f 1486 """
248ed943
RD
1487 Create(self, Window parent, int id=-1, Point pos=DefaultPosition,
1488 Size size=DefaultSize, wxArrayString choices=wxPyEmptyStringArray,
0df68c9f 1489 long style=0, Validator validator=DefaultValidator,
b2dc1044 1490 String name=ListBoxNameStr) -> bool
0df68c9f 1491 """
54f9ee45 1492 return _controls_.CheckListBox_Create(*args, **kwargs)
e811c8ce
RD
1493
1494 def IsChecked(*args, **kwargs):
a95a7133 1495 """IsChecked(self, int index) -> bool"""
54f9ee45 1496 return _controls_.CheckListBox_IsChecked(*args, **kwargs)
e811c8ce
RD
1497
1498 def Check(*args, **kwargs):
a95a7133 1499 """Check(self, int index, int check=True)"""
54f9ee45 1500 return _controls_.CheckListBox_Check(*args, **kwargs)
e811c8ce
RD
1501
1502 def GetItemHeight(*args, **kwargs):
a95a7133 1503 """GetItemHeight(self) -> int"""
54f9ee45 1504 return _controls_.CheckListBox_GetItemHeight(*args, **kwargs)
e811c8ce
RD
1505
1506 def HitTest(*args, **kwargs):
15afbcd0 1507 """
a95a7133 1508 HitTest(self, Point pt) -> int
15afbcd0
RD
1509
1510 Test where the given (in client coords) point lies
1511 """
54f9ee45 1512 return _controls_.CheckListBox_HitTest(*args, **kwargs)
e811c8ce
RD
1513
1514 def HitTestXY(*args, **kwargs):
15afbcd0 1515 """
a95a7133 1516 HitTestXY(self, int x, int y) -> int
15afbcd0
RD
1517
1518 Test where the given (in client coords) point lies
1519 """
54f9ee45 1520 return _controls_.CheckListBox_HitTestXY(*args, **kwargs)
e811c8ce 1521
d14a1e28
RD
1522
1523class CheckListBoxPtr(CheckListBox):
1524 def __init__(self, this):
d24a34bb 1525 self.this = this
d14a1e28
RD
1526 if not hasattr(self,"thisown"): self.thisown = 0
1527 self.__class__ = CheckListBox
54f9ee45 1528_controls_.CheckListBox_swigregister(CheckListBoxPtr)
d14a1e28
RD
1529
1530def PreCheckListBox(*args, **kwargs):
e811c8ce 1531 """PreCheckListBox() -> CheckListBox"""
54f9ee45 1532 val = _controls_.new_PreCheckListBox(*args, **kwargs)
d14a1e28
RD
1533 val.thisown = 1
1534 return val
1535
1536#---------------------------------------------------------------------------
1537
54f9ee45
RD
1538TE_NO_VSCROLL = _controls_.TE_NO_VSCROLL
1539TE_AUTO_SCROLL = _controls_.TE_AUTO_SCROLL
1540TE_READONLY = _controls_.TE_READONLY
1541TE_MULTILINE = _controls_.TE_MULTILINE
1542TE_PROCESS_TAB = _controls_.TE_PROCESS_TAB
1543TE_LEFT = _controls_.TE_LEFT
1544TE_CENTER = _controls_.TE_CENTER
1545TE_RIGHT = _controls_.TE_RIGHT
1546TE_CENTRE = _controls_.TE_CENTRE
1547TE_RICH = _controls_.TE_RICH
1548TE_PROCESS_ENTER = _controls_.TE_PROCESS_ENTER
1549TE_PASSWORD = _controls_.TE_PASSWORD
1550TE_AUTO_URL = _controls_.TE_AUTO_URL
1551TE_NOHIDESEL = _controls_.TE_NOHIDESEL
1552TE_DONTWRAP = _controls_.TE_DONTWRAP
08d9e66e 1553TE_CHARWRAP = _controls_.TE_CHARWRAP
54f9ee45 1554TE_WORDWRAP = _controls_.TE_WORDWRAP
08d9e66e
RD
1555TE_BESTWRAP = _controls_.TE_BESTWRAP
1556TE_LINEWRAP = _controls_.TE_LINEWRAP
54f9ee45 1557TE_RICH2 = _controls_.TE_RICH2
88c6b281 1558TE_CAPITALIZE = _controls_.TE_CAPITALIZE
54f9ee45
RD
1559TEXT_ALIGNMENT_DEFAULT = _controls_.TEXT_ALIGNMENT_DEFAULT
1560TEXT_ALIGNMENT_LEFT = _controls_.TEXT_ALIGNMENT_LEFT
1561TEXT_ALIGNMENT_CENTRE = _controls_.TEXT_ALIGNMENT_CENTRE
1562TEXT_ALIGNMENT_CENTER = _controls_.TEXT_ALIGNMENT_CENTER
1563TEXT_ALIGNMENT_RIGHT = _controls_.TEXT_ALIGNMENT_RIGHT
1564TEXT_ALIGNMENT_JUSTIFIED = _controls_.TEXT_ALIGNMENT_JUSTIFIED
1565TEXT_ATTR_TEXT_COLOUR = _controls_.TEXT_ATTR_TEXT_COLOUR
1566TEXT_ATTR_BACKGROUND_COLOUR = _controls_.TEXT_ATTR_BACKGROUND_COLOUR
1567TEXT_ATTR_FONT_FACE = _controls_.TEXT_ATTR_FONT_FACE
1568TEXT_ATTR_FONT_SIZE = _controls_.TEXT_ATTR_FONT_SIZE
1569TEXT_ATTR_FONT_WEIGHT = _controls_.TEXT_ATTR_FONT_WEIGHT
1570TEXT_ATTR_FONT_ITALIC = _controls_.TEXT_ATTR_FONT_ITALIC
1571TEXT_ATTR_FONT_UNDERLINE = _controls_.TEXT_ATTR_FONT_UNDERLINE
1572TEXT_ATTR_FONT = _controls_.TEXT_ATTR_FONT
1573TEXT_ATTR_ALIGNMENT = _controls_.TEXT_ATTR_ALIGNMENT
1574TEXT_ATTR_LEFT_INDENT = _controls_.TEXT_ATTR_LEFT_INDENT
1575TEXT_ATTR_RIGHT_INDENT = _controls_.TEXT_ATTR_RIGHT_INDENT
1576TEXT_ATTR_TABS = _controls_.TEXT_ATTR_TABS
1577TE_HT_UNKNOWN = _controls_.TE_HT_UNKNOWN
1578TE_HT_BEFORE = _controls_.TE_HT_BEFORE
1579TE_HT_ON_TEXT = _controls_.TE_HT_ON_TEXT
1580TE_HT_BELOW = _controls_.TE_HT_BELOW
1581TE_HT_BEYOND = _controls_.TE_HT_BEYOND
7557b9b5
RD
1582OutOfRangeTextCoord = _controls_.OutOfRangeTextCoord
1583InvalidTextCoord = _controls_.InvalidTextCoord
d14a1e28 1584class TextAttr(object):
093d3ff1 1585 """Proxy of C++ TextAttr class"""
e811c8ce
RD
1586 def __repr__(self):
1587 return "<%s.%s; proxy of C++ wxTextAttr instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
908b74cd 1588 def __init__(self, *args, **kwargs):
0df68c9f 1589 """
908b74cd
RD
1590 __init__(self, Colour colText=wxNullColour, Colour colBack=wxNullColour,
1591 Font font=wxNullFont, int alignment=TEXT_ALIGNMENT_DEFAULT) -> TextAttr
0df68c9f 1592 """
908b74cd 1593 newobj = _controls_.new_TextAttr(*args, **kwargs)
d14a1e28
RD
1594 self.this = newobj.this
1595 self.thisown = 1
1596 del newobj.thisown
54f9ee45 1597 def __del__(self, destroy=_controls_.delete_TextAttr):
a95a7133 1598 """__del__(self)"""
994141e6
RD
1599 try:
1600 if self.thisown: destroy(self)
1601 except: pass
1602
e811c8ce 1603 def Init(*args, **kwargs):
a95a7133 1604 """Init(self)"""
54f9ee45 1605 return _controls_.TextAttr_Init(*args, **kwargs)
e811c8ce
RD
1606
1607 def SetTextColour(*args, **kwargs):
a95a7133 1608 """SetTextColour(self, Colour colText)"""
54f9ee45 1609 return _controls_.TextAttr_SetTextColour(*args, **kwargs)
e811c8ce
RD
1610
1611 def SetBackgroundColour(*args, **kwargs):
a95a7133 1612 """SetBackgroundColour(self, Colour colBack)"""
54f9ee45 1613 return _controls_.TextAttr_SetBackgroundColour(*args, **kwargs)
e811c8ce
RD
1614
1615 def SetFont(*args, **kwargs):
a95a7133 1616 """SetFont(self, Font font, long flags=TEXT_ATTR_FONT)"""
54f9ee45 1617 return _controls_.TextAttr_SetFont(*args, **kwargs)
e811c8ce
RD
1618
1619 def SetAlignment(*args, **kwargs):
a95a7133 1620 """SetAlignment(self, int alignment)"""
54f9ee45 1621 return _controls_.TextAttr_SetAlignment(*args, **kwargs)
e811c8ce
RD
1622
1623 def SetTabs(*args, **kwargs):
a95a7133 1624 """SetTabs(self, wxArrayInt tabs)"""
54f9ee45 1625 return _controls_.TextAttr_SetTabs(*args, **kwargs)
e811c8ce
RD
1626
1627 def SetLeftIndent(*args, **kwargs):
5e4ca4a8 1628 """SetLeftIndent(self, int indent, int subIndent=0)"""
54f9ee45 1629 return _controls_.TextAttr_SetLeftIndent(*args, **kwargs)
e811c8ce
RD
1630
1631 def SetRightIndent(*args, **kwargs):
a95a7133 1632 """SetRightIndent(self, int indent)"""
54f9ee45 1633 return _controls_.TextAttr_SetRightIndent(*args, **kwargs)
e811c8ce
RD
1634
1635 def SetFlags(*args, **kwargs):
a95a7133 1636 """SetFlags(self, long flags)"""
54f9ee45 1637 return _controls_.TextAttr_SetFlags(*args, **kwargs)
e811c8ce
RD
1638
1639 def HasTextColour(*args, **kwargs):
a95a7133 1640 """HasTextColour(self) -> bool"""
54f9ee45 1641 return _controls_.TextAttr_HasTextColour(*args, **kwargs)
e811c8ce
RD
1642
1643 def HasBackgroundColour(*args, **kwargs):
a95a7133 1644 """HasBackgroundColour(self) -> bool"""
54f9ee45 1645 return _controls_.TextAttr_HasBackgroundColour(*args, **kwargs)
e811c8ce
RD
1646
1647 def HasFont(*args, **kwargs):
a95a7133 1648 """HasFont(self) -> bool"""
54f9ee45 1649 return _controls_.TextAttr_HasFont(*args, **kwargs)
e811c8ce
RD
1650
1651 def HasAlignment(*args, **kwargs):
a95a7133 1652 """HasAlignment(self) -> bool"""
54f9ee45 1653 return _controls_.TextAttr_HasAlignment(*args, **kwargs)
e811c8ce
RD
1654
1655 def HasTabs(*args, **kwargs):
a95a7133 1656 """HasTabs(self) -> bool"""
54f9ee45 1657 return _controls_.TextAttr_HasTabs(*args, **kwargs)
e811c8ce
RD
1658
1659 def HasLeftIndent(*args, **kwargs):
a95a7133 1660 """HasLeftIndent(self) -> bool"""
54f9ee45 1661 return _controls_.TextAttr_HasLeftIndent(*args, **kwargs)
e811c8ce
RD
1662
1663 def HasRightIndent(*args, **kwargs):
a95a7133 1664 """HasRightIndent(self) -> bool"""
54f9ee45 1665 return _controls_.TextAttr_HasRightIndent(*args, **kwargs)
e811c8ce
RD
1666
1667 def HasFlag(*args, **kwargs):
a95a7133 1668 """HasFlag(self, long flag) -> bool"""
54f9ee45 1669 return _controls_.TextAttr_HasFlag(*args, **kwargs)
e811c8ce
RD
1670
1671 def GetTextColour(*args, **kwargs):
a95a7133 1672 """GetTextColour(self) -> Colour"""
54f9ee45 1673 return _controls_.TextAttr_GetTextColour(*args, **kwargs)
e811c8ce
RD
1674
1675 def GetBackgroundColour(*args, **kwargs):
a95a7133 1676 """GetBackgroundColour(self) -> Colour"""
54f9ee45 1677 return _controls_.TextAttr_GetBackgroundColour(*args, **kwargs)
e811c8ce
RD
1678
1679 def GetFont(*args, **kwargs):
a95a7133 1680 """GetFont(self) -> Font"""
54f9ee45 1681 return _controls_.TextAttr_GetFont(*args, **kwargs)
e811c8ce
RD
1682
1683 def GetAlignment(*args, **kwargs):
a95a7133 1684 """GetAlignment(self) -> int"""
54f9ee45 1685 return _controls_.TextAttr_GetAlignment(*args, **kwargs)
e811c8ce
RD
1686
1687 def GetTabs(*args, **kwargs):
a95a7133 1688 """GetTabs(self) -> wxArrayInt"""
54f9ee45 1689 return _controls_.TextAttr_GetTabs(*args, **kwargs)
e811c8ce
RD
1690
1691 def GetLeftIndent(*args, **kwargs):
a95a7133 1692 """GetLeftIndent(self) -> long"""
54f9ee45 1693 return _controls_.TextAttr_GetLeftIndent(*args, **kwargs)
5e4ca4a8
RD
1694
1695 def GetLeftSubIndent(*args, **kwargs):
1696 """GetLeftSubIndent(self) -> long"""
1697 return _controls_.TextAttr_GetLeftSubIndent(*args, **kwargs)
e811c8ce
RD
1698
1699 def GetRightIndent(*args, **kwargs):
a95a7133 1700 """GetRightIndent(self) -> long"""
54f9ee45 1701 return _controls_.TextAttr_GetRightIndent(*args, **kwargs)
e811c8ce
RD
1702
1703 def GetFlags(*args, **kwargs):
a95a7133 1704 """GetFlags(self) -> long"""
54f9ee45 1705 return _controls_.TextAttr_GetFlags(*args, **kwargs)
e811c8ce
RD
1706
1707 def IsDefault(*args, **kwargs):
a95a7133 1708 """IsDefault(self) -> bool"""
54f9ee45 1709 return _controls_.TextAttr_IsDefault(*args, **kwargs)
e811c8ce
RD
1710
1711 def Combine(*args, **kwargs):
66c033b4 1712 """Combine(TextAttr attr, TextAttr attrDef, TextCtrl text) -> TextAttr"""
54f9ee45 1713 return _controls_.TextAttr_Combine(*args, **kwargs)
e811c8ce
RD
1714
1715 Combine = staticmethod(Combine)
d14a1e28
RD
1716
1717class TextAttrPtr(TextAttr):
1718 def __init__(self, this):
1719 self.this = this
1720 if not hasattr(self,"thisown"): self.thisown = 0
1721 self.__class__ = TextAttr
54f9ee45 1722_controls_.TextAttr_swigregister(TextAttrPtr)
b2dc1044 1723TextCtrlNameStr = cvar.TextCtrlNameStr
d14a1e28 1724
e811c8ce
RD
1725def TextAttr_Combine(*args, **kwargs):
1726 """TextAttr_Combine(TextAttr attr, TextAttr attrDef, TextCtrl text) -> TextAttr"""
54f9ee45 1727 return _controls_.TextAttr_Combine(*args, **kwargs)
d14a1e28 1728
54f9ee45 1729class TextCtrl(_core.Control):
093d3ff1 1730 """Proxy of C++ TextCtrl class"""
e811c8ce
RD
1731 def __repr__(self):
1732 return "<%s.%s; proxy of C++ wxTextCtrl instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 1733 def __init__(self, *args, **kwargs):
0df68c9f 1734 """
248ed943
RD
1735 __init__(self, Window parent, int id=-1, String value=EmptyString,
1736 Point pos=DefaultPosition, Size size=DefaultSize,
0df68c9f 1737 long style=0, Validator validator=DefaultValidator,
b2dc1044 1738 String name=TextCtrlNameStr) -> TextCtrl
0df68c9f 1739 """
54f9ee45 1740 newobj = _controls_.new_TextCtrl(*args, **kwargs)
d14a1e28 1741 self.this = newobj.this
d24a34bb 1742 self.thisown = 1
d14a1e28 1743 del newobj.thisown
0220cbc1 1744 self._setOORInfo(self)
e811c8ce
RD
1745
1746 def Create(*args, **kwargs):
0df68c9f 1747 """
248ed943
RD
1748 Create(self, Window parent, int id=-1, String value=EmptyString,
1749 Point pos=DefaultPosition, Size size=DefaultSize,
0df68c9f 1750 long style=0, Validator validator=DefaultValidator,
b2dc1044 1751 String name=TextCtrlNameStr) -> bool
0df68c9f 1752 """
54f9ee45 1753 return _controls_.TextCtrl_Create(*args, **kwargs)
e811c8ce
RD
1754
1755 def GetValue(*args, **kwargs):
a95a7133 1756 """GetValue(self) -> String"""
54f9ee45 1757 return _controls_.TextCtrl_GetValue(*args, **kwargs)
e811c8ce
RD
1758
1759 def SetValue(*args, **kwargs):
a95a7133 1760 """SetValue(self, String value)"""
54f9ee45 1761 return _controls_.TextCtrl_SetValue(*args, **kwargs)
e811c8ce
RD
1762
1763 def GetRange(*args, **kwargs):
a95a7133 1764 """GetRange(self, long from, long to) -> String"""
54f9ee45 1765 return _controls_.TextCtrl_GetRange(*args, **kwargs)
e811c8ce
RD
1766
1767 def GetLineLength(*args, **kwargs):
a95a7133 1768 """GetLineLength(self, long lineNo) -> int"""
54f9ee45 1769 return _controls_.TextCtrl_GetLineLength(*args, **kwargs)
e811c8ce
RD
1770
1771 def GetLineText(*args, **kwargs):
a95a7133 1772 """GetLineText(self, long lineNo) -> String"""
54f9ee45 1773 return _controls_.TextCtrl_GetLineText(*args, **kwargs)
e811c8ce
RD
1774
1775 def GetNumberOfLines(*args, **kwargs):
a95a7133 1776 """GetNumberOfLines(self) -> int"""
54f9ee45 1777 return _controls_.TextCtrl_GetNumberOfLines(*args, **kwargs)
e811c8ce
RD
1778
1779 def IsModified(*args, **kwargs):
a95a7133 1780 """IsModified(self) -> bool"""
54f9ee45 1781 return _controls_.TextCtrl_IsModified(*args, **kwargs)
e811c8ce
RD
1782
1783 def IsEditable(*args, **kwargs):
a95a7133 1784 """IsEditable(self) -> bool"""
54f9ee45 1785 return _controls_.TextCtrl_IsEditable(*args, **kwargs)
e811c8ce
RD
1786
1787 def IsSingleLine(*args, **kwargs):
a95a7133 1788 """IsSingleLine(self) -> bool"""
54f9ee45 1789 return _controls_.TextCtrl_IsSingleLine(*args, **kwargs)
e811c8ce
RD
1790
1791 def IsMultiLine(*args, **kwargs):
a95a7133 1792 """IsMultiLine(self) -> bool"""
54f9ee45 1793 return _controls_.TextCtrl_IsMultiLine(*args, **kwargs)
e811c8ce
RD
1794
1795 def GetSelection(*args, **kwargs):
fd2dc343
RD
1796 """
1797 GetSelection() -> (from, to)
1798
1799 If the return values from and to are the same, there is no selection.
1800 """
54f9ee45 1801 return _controls_.TextCtrl_GetSelection(*args, **kwargs)
e811c8ce
RD
1802
1803 def GetStringSelection(*args, **kwargs):
a95a7133 1804 """GetStringSelection(self) -> String"""
54f9ee45 1805 return _controls_.TextCtrl_GetStringSelection(*args, **kwargs)
e811c8ce
RD
1806
1807 def Clear(*args, **kwargs):
a95a7133 1808 """Clear(self)"""
54f9ee45 1809 return _controls_.TextCtrl_Clear(*args, **kwargs)
e811c8ce
RD
1810
1811 def Replace(*args, **kwargs):
a95a7133 1812 """Replace(self, long from, long to, String value)"""
54f9ee45 1813 return _controls_.TextCtrl_Replace(*args, **kwargs)
e811c8ce
RD
1814
1815 def Remove(*args, **kwargs):
a95a7133 1816 """Remove(self, long from, long to)"""
54f9ee45 1817 return _controls_.TextCtrl_Remove(*args, **kwargs)
e811c8ce
RD
1818
1819 def LoadFile(*args, **kwargs):
a95a7133 1820 """LoadFile(self, String file) -> bool"""
54f9ee45 1821 return _controls_.TextCtrl_LoadFile(*args, **kwargs)
e811c8ce
RD
1822
1823 def SaveFile(*args, **kwargs):
a95a7133 1824 """SaveFile(self, String file=EmptyString) -> bool"""
54f9ee45 1825 return _controls_.TextCtrl_SaveFile(*args, **kwargs)
e811c8ce
RD
1826
1827 def MarkDirty(*args, **kwargs):
a95a7133 1828 """MarkDirty(self)"""
54f9ee45 1829 return _controls_.TextCtrl_MarkDirty(*args, **kwargs)
e811c8ce
RD
1830
1831 def DiscardEdits(*args, **kwargs):
a95a7133 1832 """DiscardEdits(self)"""
54f9ee45 1833 return _controls_.TextCtrl_DiscardEdits(*args, **kwargs)
e811c8ce
RD
1834
1835 def SetMaxLength(*args, **kwargs):
a95a7133 1836 """SetMaxLength(self, unsigned long len)"""
54f9ee45 1837 return _controls_.TextCtrl_SetMaxLength(*args, **kwargs)
e811c8ce
RD
1838
1839 def WriteText(*args, **kwargs):
a95a7133 1840 """WriteText(self, String text)"""
54f9ee45 1841 return _controls_.TextCtrl_WriteText(*args, **kwargs)
e811c8ce
RD
1842
1843 def AppendText(*args, **kwargs):
a95a7133 1844 """AppendText(self, String text)"""
54f9ee45 1845 return _controls_.TextCtrl_AppendText(*args, **kwargs)
e811c8ce
RD
1846
1847 def EmulateKeyPress(*args, **kwargs):
a95a7133 1848 """EmulateKeyPress(self, KeyEvent event) -> bool"""
54f9ee45 1849 return _controls_.TextCtrl_EmulateKeyPress(*args, **kwargs)
e811c8ce
RD
1850
1851 def SetStyle(*args, **kwargs):
a95a7133 1852 """SetStyle(self, long start, long end, TextAttr style) -> bool"""
54f9ee45 1853 return _controls_.TextCtrl_SetStyle(*args, **kwargs)
e811c8ce
RD
1854
1855 def GetStyle(*args, **kwargs):
a95a7133 1856 """GetStyle(self, long position, TextAttr style) -> bool"""
54f9ee45 1857 return _controls_.TextCtrl_GetStyle(*args, **kwargs)
e811c8ce
RD
1858
1859 def SetDefaultStyle(*args, **kwargs):
a95a7133 1860 """SetDefaultStyle(self, TextAttr style) -> bool"""
54f9ee45 1861 return _controls_.TextCtrl_SetDefaultStyle(*args, **kwargs)
e811c8ce
RD
1862
1863 def GetDefaultStyle(*args, **kwargs):
a95a7133 1864 """GetDefaultStyle(self) -> TextAttr"""
54f9ee45 1865 return _controls_.TextCtrl_GetDefaultStyle(*args, **kwargs)
e811c8ce
RD
1866
1867 def XYToPosition(*args, **kwargs):
a95a7133 1868 """XYToPosition(self, long x, long y) -> long"""
54f9ee45 1869 return _controls_.TextCtrl_XYToPosition(*args, **kwargs)
e811c8ce
RD
1870
1871 def PositionToXY(*args, **kwargs):
322913ce 1872 """PositionToXY(long pos) -> (x, y)"""
54f9ee45 1873 return _controls_.TextCtrl_PositionToXY(*args, **kwargs)
e811c8ce
RD
1874
1875 def ShowPosition(*args, **kwargs):
a95a7133 1876 """ShowPosition(self, long pos)"""
54f9ee45 1877 return _controls_.TextCtrl_ShowPosition(*args, **kwargs)
e811c8ce 1878
4d5c3d91 1879 def HitTest(*args, **kwargs):
fd2dc343 1880 """
51b83b37 1881 HitTest(Point pt) -> (result, col, row)
fd2dc343 1882
4896ac9e
RD
1883 Find the row, col coresponding to the character at the point given in
1884 pixels. NB: pt is in device coords but is not adjusted for the client
1885 area origin nor scrolling.
fd2dc343 1886 """
54f9ee45 1887 return _controls_.TextCtrl_HitTest(*args, **kwargs)
4d5c3d91 1888
4896ac9e
RD
1889 def HitTestPos(*args, **kwargs):
1890 """
1891 HitTestPos(Point pt) -> (result, position)
1892
1893 Find the character position in the text coresponding to the point
1894 given in pixels. NB: pt is in device coords but is not adjusted for
1895 the client area origin nor scrolling.
1896 """
1897 return _controls_.TextCtrl_HitTestPos(*args, **kwargs)
1898
e811c8ce 1899 def Copy(*args, **kwargs):
a95a7133 1900 """Copy(self)"""
54f9ee45 1901 return _controls_.TextCtrl_Copy(*args, **kwargs)
e811c8ce
RD
1902
1903 def Cut(*args, **kwargs):
a95a7133 1904 """Cut(self)"""
54f9ee45 1905 return _controls_.TextCtrl_Cut(*args, **kwargs)
e811c8ce
RD
1906
1907 def Paste(*args, **kwargs):
a95a7133 1908 """Paste(self)"""
54f9ee45 1909 return _controls_.TextCtrl_Paste(*args, **kwargs)
e811c8ce
RD
1910
1911 def CanCopy(*args, **kwargs):
a95a7133 1912 """CanCopy(self) -> bool"""
54f9ee45 1913 return _controls_.TextCtrl_CanCopy(*args, **kwargs)
e811c8ce
RD
1914
1915 def CanCut(*args, **kwargs):
a95a7133 1916 """CanCut(self) -> bool"""
54f9ee45 1917 return _controls_.TextCtrl_CanCut(*args, **kwargs)
e811c8ce
RD
1918
1919 def CanPaste(*args, **kwargs):
a95a7133 1920 """CanPaste(self) -> bool"""
54f9ee45 1921 return _controls_.TextCtrl_CanPaste(*args, **kwargs)
e811c8ce
RD
1922
1923 def Undo(*args, **kwargs):
a95a7133 1924 """Undo(self)"""
54f9ee45 1925 return _controls_.TextCtrl_Undo(*args, **kwargs)
e811c8ce
RD
1926
1927 def Redo(*args, **kwargs):
a95a7133 1928 """Redo(self)"""
54f9ee45 1929 return _controls_.TextCtrl_Redo(*args, **kwargs)
e811c8ce
RD
1930
1931 def CanUndo(*args, **kwargs):
a95a7133 1932 """CanUndo(self) -> bool"""
54f9ee45 1933 return _controls_.TextCtrl_CanUndo(*args, **kwargs)
e811c8ce
RD
1934
1935 def CanRedo(*args, **kwargs):
a95a7133 1936 """CanRedo(self) -> bool"""
54f9ee45 1937 return _controls_.TextCtrl_CanRedo(*args, **kwargs)
e811c8ce
RD
1938
1939 def SetInsertionPoint(*args, **kwargs):
a95a7133 1940 """SetInsertionPoint(self, long pos)"""
54f9ee45 1941 return _controls_.TextCtrl_SetInsertionPoint(*args, **kwargs)
e811c8ce
RD
1942
1943 def SetInsertionPointEnd(*args, **kwargs):
a95a7133 1944 """SetInsertionPointEnd(self)"""
54f9ee45 1945 return _controls_.TextCtrl_SetInsertionPointEnd(*args, **kwargs)
e811c8ce
RD
1946
1947 def GetInsertionPoint(*args, **kwargs):
a95a7133 1948 """GetInsertionPoint(self) -> long"""
54f9ee45 1949 return _controls_.TextCtrl_GetInsertionPoint(*args, **kwargs)
e811c8ce
RD
1950
1951 def GetLastPosition(*args, **kwargs):
a95a7133 1952 """GetLastPosition(self) -> long"""
54f9ee45 1953 return _controls_.TextCtrl_GetLastPosition(*args, **kwargs)
e811c8ce
RD
1954
1955 def SetSelection(*args, **kwargs):
a95a7133 1956 """SetSelection(self, long from, long to)"""
54f9ee45 1957 return _controls_.TextCtrl_SetSelection(*args, **kwargs)
e811c8ce
RD
1958
1959 def SelectAll(*args, **kwargs):
a95a7133 1960 """SelectAll(self)"""
54f9ee45 1961 return _controls_.TextCtrl_SelectAll(*args, **kwargs)
e811c8ce
RD
1962
1963 def SetEditable(*args, **kwargs):
a95a7133 1964 """SetEditable(self, bool editable)"""
54f9ee45 1965 return _controls_.TextCtrl_SetEditable(*args, **kwargs)
e811c8ce
RD
1966
1967 def write(*args, **kwargs):
a95a7133 1968 """write(self, String text)"""
54f9ee45 1969 return _controls_.TextCtrl_write(*args, **kwargs)
e811c8ce
RD
1970
1971 def GetString(*args, **kwargs):
a95a7133 1972 """GetString(self, long from, long to) -> String"""
54f9ee45 1973 return _controls_.TextCtrl_GetString(*args, **kwargs)
e811c8ce 1974
22bfe96c 1975 def GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
1976 """
1977 GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
1978
1979 Get the default attributes for this class. This is useful if you want
1980 to use the same font or colour in your own control as in a standard
1981 control -- which is a much better idea than hard coding specific
1982 colours or fonts which might look completely out of place on the
1983 user's system, especially if it uses themes.
1984
1985 The variant parameter is only relevant under Mac currently and is
1986 ignore under other platforms. Under Mac, it will change the size of
1987 the returned font. See `wx.Window.SetWindowVariant` for more about
1988 this.
1989 """
22bfe96c
RD
1990 return _controls_.TextCtrl_GetClassDefaultAttributes(*args, **kwargs)
1991
1992 GetClassDefaultAttributes = staticmethod(GetClassDefaultAttributes)
d24a34bb 1993
d14a1e28
RD
1994class TextCtrlPtr(TextCtrl):
1995 def __init__(self, this):
1996 self.this = this
1997 if not hasattr(self,"thisown"): self.thisown = 0
1998 self.__class__ = TextCtrl
54f9ee45 1999_controls_.TextCtrl_swigregister(TextCtrlPtr)
d24a34bb 2000
d14a1e28 2001def PreTextCtrl(*args, **kwargs):
e811c8ce 2002 """PreTextCtrl() -> TextCtrl"""
54f9ee45 2003 val = _controls_.new_PreTextCtrl(*args, **kwargs)
aa2a5b86
RD
2004 val.thisown = 1
2005 return val
2006
22bfe96c 2007def TextCtrl_GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
2008 """
2009 TextCtrl_GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
2010
2011 Get the default attributes for this class. This is useful if you want
2012 to use the same font or colour in your own control as in a standard
2013 control -- which is a much better idea than hard coding specific
2014 colours or fonts which might look completely out of place on the
2015 user's system, especially if it uses themes.
2016
2017 The variant parameter is only relevant under Mac currently and is
2018 ignore under other platforms. Under Mac, it will change the size of
2019 the returned font. See `wx.Window.SetWindowVariant` for more about
2020 this.
2021 """
22bfe96c
RD
2022 return _controls_.TextCtrl_GetClassDefaultAttributes(*args, **kwargs)
2023
54f9ee45
RD
2024wxEVT_COMMAND_TEXT_UPDATED = _controls_.wxEVT_COMMAND_TEXT_UPDATED
2025wxEVT_COMMAND_TEXT_ENTER = _controls_.wxEVT_COMMAND_TEXT_ENTER
2026wxEVT_COMMAND_TEXT_URL = _controls_.wxEVT_COMMAND_TEXT_URL
2027wxEVT_COMMAND_TEXT_MAXLEN = _controls_.wxEVT_COMMAND_TEXT_MAXLEN
2028class TextUrlEvent(_core.CommandEvent):
093d3ff1 2029 """Proxy of C++ TextUrlEvent class"""
e811c8ce
RD
2030 def __repr__(self):
2031 return "<%s.%s; proxy of C++ wxTextUrlEvent instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 2032 def __init__(self, *args, **kwargs):
a95a7133 2033 """__init__(self, int winid, MouseEvent evtMouse, long start, long end) -> TextUrlEvent"""
54f9ee45 2034 newobj = _controls_.new_TextUrlEvent(*args, **kwargs)
d14a1e28
RD
2035 self.this = newobj.this
2036 self.thisown = 1
2037 del newobj.thisown
e811c8ce 2038 def GetMouseEvent(*args, **kwargs):
a95a7133 2039 """GetMouseEvent(self) -> MouseEvent"""
54f9ee45 2040 return _controls_.TextUrlEvent_GetMouseEvent(*args, **kwargs)
e811c8ce
RD
2041
2042 def GetURLStart(*args, **kwargs):
a95a7133 2043 """GetURLStart(self) -> long"""
54f9ee45 2044 return _controls_.TextUrlEvent_GetURLStart(*args, **kwargs)
e811c8ce
RD
2045
2046 def GetURLEnd(*args, **kwargs):
a95a7133 2047 """GetURLEnd(self) -> long"""
54f9ee45 2048 return _controls_.TextUrlEvent_GetURLEnd(*args, **kwargs)
e811c8ce 2049
d24a34bb 2050
d14a1e28
RD
2051class TextUrlEventPtr(TextUrlEvent):
2052 def __init__(self, this):
70551f47 2053 self.this = this
d14a1e28
RD
2054 if not hasattr(self,"thisown"): self.thisown = 0
2055 self.__class__ = TextUrlEvent
54f9ee45 2056_controls_.TextUrlEvent_swigregister(TextUrlEventPtr)
d14a1e28
RD
2057
2058EVT_TEXT = wx.PyEventBinder( wxEVT_COMMAND_TEXT_UPDATED, 1)
2059EVT_TEXT_ENTER = wx.PyEventBinder( wxEVT_COMMAND_TEXT_ENTER, 1)
2060EVT_TEXT_URL = wx.PyEventBinder( wxEVT_COMMAND_TEXT_URL, 1)
2061EVT_TEXT_MAXLEN = wx.PyEventBinder( wxEVT_COMMAND_TEXT_MAXLEN, 1)
2062
2063#---------------------------------------------------------------------------
2064
54f9ee45 2065class ScrollBar(_core.Control):
093d3ff1 2066 """Proxy of C++ ScrollBar class"""
e811c8ce
RD
2067 def __repr__(self):
2068 return "<%s.%s; proxy of C++ wxScrollBar instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 2069 def __init__(self, *args, **kwargs):
0df68c9f 2070 """
a95a7133 2071 __init__(self, Window parent, int id=-1, Point pos=DefaultPosition,
0df68c9f 2072 Size size=DefaultSize, long style=SB_HORIZONTAL,
b2dc1044 2073 Validator validator=DefaultValidator, String name=ScrollBarNameStr) -> ScrollBar
0df68c9f 2074 """
54f9ee45 2075 newobj = _controls_.new_ScrollBar(*args, **kwargs)
d14a1e28 2076 self.this = newobj.this
70551f47 2077 self.thisown = 1
d14a1e28 2078 del newobj.thisown
0220cbc1 2079 self._setOORInfo(self)
e811c8ce
RD
2080
2081 def Create(*args, **kwargs):
0df68c9f 2082 """
a95a7133 2083 Create(self, Window parent, int id=-1, Point pos=DefaultPosition,
0df68c9f 2084 Size size=DefaultSize, long style=SB_HORIZONTAL,
b2dc1044 2085 Validator validator=DefaultValidator, String name=ScrollBarNameStr) -> bool
15afbcd0
RD
2086
2087 Do the 2nd phase and create the GUI control.
0df68c9f 2088 """
54f9ee45 2089 return _controls_.ScrollBar_Create(*args, **kwargs)
e811c8ce
RD
2090
2091 def GetThumbPosition(*args, **kwargs):
a95a7133 2092 """GetThumbPosition(self) -> int"""
54f9ee45 2093 return _controls_.ScrollBar_GetThumbPosition(*args, **kwargs)
e811c8ce
RD
2094
2095 def GetThumbSize(*args, **kwargs):
a95a7133 2096 """GetThumbSize(self) -> int"""
54f9ee45 2097 return _controls_.ScrollBar_GetThumbSize(*args, **kwargs)
e811c8ce 2098
d14a1e28 2099 GetThumbLength = GetThumbSize
e811c8ce 2100 def GetPageSize(*args, **kwargs):
a95a7133 2101 """GetPageSize(self) -> int"""
54f9ee45 2102 return _controls_.ScrollBar_GetPageSize(*args, **kwargs)
e811c8ce
RD
2103
2104 def GetRange(*args, **kwargs):
a95a7133 2105 """GetRange(self) -> int"""
54f9ee45 2106 return _controls_.ScrollBar_GetRange(*args, **kwargs)
e811c8ce
RD
2107
2108 def IsVertical(*args, **kwargs):
a95a7133 2109 """IsVertical(self) -> bool"""
54f9ee45 2110 return _controls_.ScrollBar_IsVertical(*args, **kwargs)
e811c8ce
RD
2111
2112 def SetThumbPosition(*args, **kwargs):
a95a7133 2113 """SetThumbPosition(self, int viewStart)"""
54f9ee45 2114 return _controls_.ScrollBar_SetThumbPosition(*args, **kwargs)
e811c8ce
RD
2115
2116 def SetScrollbar(*args, **kwargs):
0df68c9f 2117 """
a95a7133 2118 SetScrollbar(self, int position, int thumbSize, int range, int pageSize,
0df68c9f 2119 bool refresh=True)
15afbcd0
RD
2120
2121 Sets the scrollbar properties of a built-in scrollbar.
0df68c9f 2122 """
54f9ee45 2123 return _controls_.ScrollBar_SetScrollbar(*args, **kwargs)
e811c8ce 2124
22bfe96c 2125 def GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
2126 """
2127 GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
2128
2129 Get the default attributes for this class. This is useful if you want
2130 to use the same font or colour in your own control as in a standard
2131 control -- which is a much better idea than hard coding specific
2132 colours or fonts which might look completely out of place on the
2133 user's system, especially if it uses themes.
2134
2135 The variant parameter is only relevant under Mac currently and is
2136 ignore under other platforms. Under Mac, it will change the size of
2137 the returned font. See `wx.Window.SetWindowVariant` for more about
2138 this.
2139 """
22bfe96c
RD
2140 return _controls_.ScrollBar_GetClassDefaultAttributes(*args, **kwargs)
2141
2142 GetClassDefaultAttributes = staticmethod(GetClassDefaultAttributes)
70551f47 2143
d14a1e28
RD
2144class ScrollBarPtr(ScrollBar):
2145 def __init__(self, this):
2146 self.this = this
2147 if not hasattr(self,"thisown"): self.thisown = 0
2148 self.__class__ = ScrollBar
54f9ee45 2149_controls_.ScrollBar_swigregister(ScrollBarPtr)
b2dc1044 2150ScrollBarNameStr = cvar.ScrollBarNameStr
70551f47 2151
d14a1e28 2152def PreScrollBar(*args, **kwargs):
e811c8ce 2153 """PreScrollBar() -> ScrollBar"""
54f9ee45 2154 val = _controls_.new_PreScrollBar(*args, **kwargs)
aa2a5b86
RD
2155 val.thisown = 1
2156 return val
2157
22bfe96c 2158def ScrollBar_GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
2159 """
2160 ScrollBar_GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
2161
2162 Get the default attributes for this class. This is useful if you want
2163 to use the same font or colour in your own control as in a standard
2164 control -- which is a much better idea than hard coding specific
2165 colours or fonts which might look completely out of place on the
2166 user's system, especially if it uses themes.
2167
2168 The variant parameter is only relevant under Mac currently and is
2169 ignore under other platforms. Under Mac, it will change the size of
2170 the returned font. See `wx.Window.SetWindowVariant` for more about
2171 this.
2172 """
22bfe96c
RD
2173 return _controls_.ScrollBar_GetClassDefaultAttributes(*args, **kwargs)
2174
d14a1e28 2175#---------------------------------------------------------------------------
70551f47 2176
54f9ee45
RD
2177SP_HORIZONTAL = _controls_.SP_HORIZONTAL
2178SP_VERTICAL = _controls_.SP_VERTICAL
2179SP_ARROW_KEYS = _controls_.SP_ARROW_KEYS
2180SP_WRAP = _controls_.SP_WRAP
2181class SpinButton(_core.Control):
093d3ff1 2182 """Proxy of C++ SpinButton class"""
e811c8ce
RD
2183 def __repr__(self):
2184 return "<%s.%s; proxy of C++ wxSpinButton instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 2185 def __init__(self, *args, **kwargs):
0df68c9f 2186 """
a95a7133 2187 __init__(self, Window parent, int id=-1, Point pos=DefaultPosition,
0df68c9f 2188 Size size=DefaultSize, long style=SP_HORIZONTAL,
b2dc1044 2189 String name=SPIN_BUTTON_NAME) -> SpinButton
0df68c9f 2190 """
54f9ee45 2191 newobj = _controls_.new_SpinButton(*args, **kwargs)
d14a1e28 2192 self.this = newobj.this
70551f47 2193 self.thisown = 1
d14a1e28 2194 del newobj.thisown
0220cbc1 2195 self._setOORInfo(self)
70551f47 2196
e811c8ce 2197 def Create(*args, **kwargs):
0df68c9f 2198 """
a95a7133 2199 Create(self, Window parent, int id=-1, Point pos=DefaultPosition,
0df68c9f 2200 Size size=DefaultSize, long style=SP_HORIZONTAL,
b2dc1044 2201 String name=SPIN_BUTTON_NAME) -> bool
0df68c9f 2202 """
54f9ee45 2203 return _controls_.SpinButton_Create(*args, **kwargs)
e811c8ce
RD
2204
2205 def GetValue(*args, **kwargs):
a95a7133 2206 """GetValue(self) -> int"""
54f9ee45 2207 return _controls_.SpinButton_GetValue(*args, **kwargs)
e811c8ce
RD
2208
2209 def GetMin(*args, **kwargs):
a95a7133 2210 """GetMin(self) -> int"""
54f9ee45 2211 return _controls_.SpinButton_GetMin(*args, **kwargs)
e811c8ce
RD
2212
2213 def GetMax(*args, **kwargs):
a95a7133 2214 """GetMax(self) -> int"""
54f9ee45 2215 return _controls_.SpinButton_GetMax(*args, **kwargs)
e811c8ce
RD
2216
2217 def SetValue(*args, **kwargs):
a95a7133 2218 """SetValue(self, int val)"""
54f9ee45 2219 return _controls_.SpinButton_SetValue(*args, **kwargs)
e811c8ce
RD
2220
2221 def SetMin(*args, **kwargs):
a95a7133 2222 """SetMin(self, int minVal)"""
54f9ee45 2223 return _controls_.SpinButton_SetMin(*args, **kwargs)
e811c8ce
RD
2224
2225 def SetMax(*args, **kwargs):
a95a7133 2226 """SetMax(self, int maxVal)"""
54f9ee45 2227 return _controls_.SpinButton_SetMax(*args, **kwargs)
e811c8ce
RD
2228
2229 def SetRange(*args, **kwargs):
a95a7133 2230 """SetRange(self, int minVal, int maxVal)"""
54f9ee45 2231 return _controls_.SpinButton_SetRange(*args, **kwargs)
e811c8ce 2232
22bfe96c
RD
2233 def IsVertical(*args, **kwargs):
2234 """IsVertical(self) -> bool"""
2235 return _controls_.SpinButton_IsVertical(*args, **kwargs)
2236
2237 def GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
2238 """
2239 GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
2240
2241 Get the default attributes for this class. This is useful if you want
2242 to use the same font or colour in your own control as in a standard
2243 control -- which is a much better idea than hard coding specific
2244 colours or fonts which might look completely out of place on the
2245 user's system, especially if it uses themes.
2246
2247 The variant parameter is only relevant under Mac currently and is
2248 ignore under other platforms. Under Mac, it will change the size of
2249 the returned font. See `wx.Window.SetWindowVariant` for more about
2250 this.
2251 """
22bfe96c 2252 return _controls_.SpinButton_GetClassDefaultAttributes(*args, **kwargs)
e811c8ce 2253
22bfe96c 2254 GetClassDefaultAttributes = staticmethod(GetClassDefaultAttributes)
e811c8ce
RD
2255
2256class SpinButtonPtr(SpinButton):
2257 def __init__(self, this):
2258 self.this = this
2259 if not hasattr(self,"thisown"): self.thisown = 0
d14a1e28 2260 self.__class__ = SpinButton
54f9ee45 2261_controls_.SpinButton_swigregister(SpinButtonPtr)
b2dc1044
RD
2262SPIN_BUTTON_NAME = cvar.SPIN_BUTTON_NAME
2263SpinCtrlNameStr = cvar.SpinCtrlNameStr
70551f47 2264
d14a1e28 2265def PreSpinButton(*args, **kwargs):
e811c8ce 2266 """PreSpinButton() -> SpinButton"""
54f9ee45 2267 val = _controls_.new_PreSpinButton(*args, **kwargs)
aa2a5b86
RD
2268 val.thisown = 1
2269 return val
2270
22bfe96c 2271def SpinButton_GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
2272 """
2273 SpinButton_GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
2274
2275 Get the default attributes for this class. This is useful if you want
2276 to use the same font or colour in your own control as in a standard
2277 control -- which is a much better idea than hard coding specific
2278 colours or fonts which might look completely out of place on the
2279 user's system, especially if it uses themes.
2280
2281 The variant parameter is only relevant under Mac currently and is
2282 ignore under other platforms. Under Mac, it will change the size of
2283 the returned font. See `wx.Window.SetWindowVariant` for more about
2284 this.
2285 """
22bfe96c
RD
2286 return _controls_.SpinButton_GetClassDefaultAttributes(*args, **kwargs)
2287
54f9ee45 2288class SpinCtrl(_core.Control):
093d3ff1 2289 """Proxy of C++ SpinCtrl class"""
e811c8ce
RD
2290 def __repr__(self):
2291 return "<%s.%s; proxy of C++ wxSpinCtrl instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 2292 def __init__(self, *args, **kwargs):
0df68c9f 2293 """
a95a7133 2294 __init__(self, Window parent, int id=-1, String value=EmptyString,
0df68c9f 2295 Point pos=DefaultPosition, Size size=DefaultSize,
196addbf 2296 long style=SP_ARROW_KEYS, int min=0, int max=100,
b2dc1044 2297 int initial=0, String name=SpinCtrlNameStr) -> SpinCtrl
0df68c9f 2298 """
54f9ee45 2299 newobj = _controls_.new_SpinCtrl(*args, **kwargs)
d14a1e28
RD
2300 self.this = newobj.this
2301 self.thisown = 1
2302 del newobj.thisown
2303 self._setOORInfo(self)
e811c8ce
RD
2304
2305 def Create(*args, **kwargs):
0df68c9f 2306 """
a95a7133 2307 Create(self, Window parent, int id=-1, String value=EmptyString,
0df68c9f 2308 Point pos=DefaultPosition, Size size=DefaultSize,
196addbf 2309 long style=SP_ARROW_KEYS, int min=0, int max=100,
b2dc1044 2310 int initial=0, String name=SpinCtrlNameStr) -> bool
0df68c9f 2311 """
54f9ee45 2312 return _controls_.SpinCtrl_Create(*args, **kwargs)
e811c8ce
RD
2313
2314 def GetValue(*args, **kwargs):
a95a7133 2315 """GetValue(self) -> int"""
54f9ee45 2316 return _controls_.SpinCtrl_GetValue(*args, **kwargs)
e811c8ce
RD
2317
2318 def SetValue(*args, **kwargs):
a95a7133 2319 """SetValue(self, int value)"""
54f9ee45 2320 return _controls_.SpinCtrl_SetValue(*args, **kwargs)
e811c8ce
RD
2321
2322 def SetValueString(*args, **kwargs):
a95a7133 2323 """SetValueString(self, String text)"""
54f9ee45 2324 return _controls_.SpinCtrl_SetValueString(*args, **kwargs)
e811c8ce
RD
2325
2326 def SetRange(*args, **kwargs):
a95a7133 2327 """SetRange(self, int minVal, int maxVal)"""
54f9ee45 2328 return _controls_.SpinCtrl_SetRange(*args, **kwargs)
e811c8ce
RD
2329
2330 def GetMin(*args, **kwargs):
a95a7133 2331 """GetMin(self) -> int"""
54f9ee45 2332 return _controls_.SpinCtrl_GetMin(*args, **kwargs)
e811c8ce
RD
2333
2334 def GetMax(*args, **kwargs):
a95a7133 2335 """GetMax(self) -> int"""
54f9ee45 2336 return _controls_.SpinCtrl_GetMax(*args, **kwargs)
e811c8ce
RD
2337
2338 def SetSelection(*args, **kwargs):
a95a7133 2339 """SetSelection(self, long from, long to)"""
54f9ee45 2340 return _controls_.SpinCtrl_SetSelection(*args, **kwargs)
e811c8ce 2341
22bfe96c 2342 def GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
2343 """
2344 GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
2345
2346 Get the default attributes for this class. This is useful if you want
2347 to use the same font or colour in your own control as in a standard
2348 control -- which is a much better idea than hard coding specific
2349 colours or fonts which might look completely out of place on the
2350 user's system, especially if it uses themes.
2351
2352 The variant parameter is only relevant under Mac currently and is
2353 ignore under other platforms. Under Mac, it will change the size of
2354 the returned font. See `wx.Window.SetWindowVariant` for more about
2355 this.
2356 """
22bfe96c
RD
2357 return _controls_.SpinCtrl_GetClassDefaultAttributes(*args, **kwargs)
2358
2359 GetClassDefaultAttributes = staticmethod(GetClassDefaultAttributes)
70551f47 2360
d14a1e28
RD
2361class SpinCtrlPtr(SpinCtrl):
2362 def __init__(self, this):
c95e68d8 2363 self.this = this
d14a1e28
RD
2364 if not hasattr(self,"thisown"): self.thisown = 0
2365 self.__class__ = SpinCtrl
54f9ee45 2366_controls_.SpinCtrl_swigregister(SpinCtrlPtr)
d14a1e28
RD
2367
2368def PreSpinCtrl(*args, **kwargs):
e811c8ce 2369 """PreSpinCtrl() -> SpinCtrl"""
54f9ee45 2370 val = _controls_.new_PreSpinCtrl(*args, **kwargs)
d14a1e28
RD
2371 val.thisown = 1
2372 return val
2373
22bfe96c 2374def SpinCtrl_GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
2375 """
2376 SpinCtrl_GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
2377
2378 Get the default attributes for this class. This is useful if you want
2379 to use the same font or colour in your own control as in a standard
2380 control -- which is a much better idea than hard coding specific
2381 colours or fonts which might look completely out of place on the
2382 user's system, especially if it uses themes.
2383
2384 The variant parameter is only relevant under Mac currently and is
2385 ignore under other platforms. Under Mac, it will change the size of
2386 the returned font. See `wx.Window.SetWindowVariant` for more about
2387 this.
2388 """
22bfe96c
RD
2389 return _controls_.SpinCtrl_GetClassDefaultAttributes(*args, **kwargs)
2390
54f9ee45 2391class SpinEvent(_core.NotifyEvent):
093d3ff1 2392 """Proxy of C++ SpinEvent class"""
d1e20054
RD
2393 def __repr__(self):
2394 return "<%s.%s; proxy of C++ wxSpinEvent instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
2395 def __init__(self, *args, **kwargs):
a95a7133 2396 """__init__(self, wxEventType commandType=wxEVT_NULL, int winid=0) -> SpinEvent"""
54f9ee45 2397 newobj = _controls_.new_SpinEvent(*args, **kwargs)
d1e20054
RD
2398 self.this = newobj.this
2399 self.thisown = 1
2400 del newobj.thisown
2401 def GetPosition(*args, **kwargs):
a95a7133 2402 """GetPosition(self) -> int"""
54f9ee45 2403 return _controls_.SpinEvent_GetPosition(*args, **kwargs)
d1e20054
RD
2404
2405 def SetPosition(*args, **kwargs):
a95a7133 2406 """SetPosition(self, int pos)"""
54f9ee45 2407 return _controls_.SpinEvent_SetPosition(*args, **kwargs)
d1e20054
RD
2408
2409
2410class SpinEventPtr(SpinEvent):
2411 def __init__(self, this):
2412 self.this = this
2413 if not hasattr(self,"thisown"): self.thisown = 0
2414 self.__class__ = SpinEvent
54f9ee45 2415_controls_.SpinEvent_swigregister(SpinEventPtr)
d1e20054 2416
54f9ee45 2417wxEVT_COMMAND_SPINCTRL_UPDATED = _controls_.wxEVT_COMMAND_SPINCTRL_UPDATED
d1e20054
RD
2418EVT_SPIN_UP = wx.PyEventBinder( wx.wxEVT_SCROLL_LINEUP, 1)
2419EVT_SPIN_DOWN = wx.PyEventBinder( wx.wxEVT_SCROLL_LINEDOWN, 1)
2420EVT_SPIN = wx.PyEventBinder( wx.wxEVT_SCROLL_THUMBTRACK, 1)
2421EVT_SPINCTRL = wx.PyEventBinder( wxEVT_COMMAND_SPINCTRL_UPDATED, 1)
d14a1e28
RD
2422
2423#---------------------------------------------------------------------------
2424
54f9ee45 2425class RadioBox(_core.Control):
093d3ff1 2426 """Proxy of C++ RadioBox class"""
e811c8ce
RD
2427 def __repr__(self):
2428 return "<%s.%s; proxy of C++ wxRadioBox instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 2429 def __init__(self, *args, **kwargs):
0df68c9f 2430 """
248ed943
RD
2431 __init__(self, Window parent, int id=-1, String label=EmptyString,
2432 Point pos=DefaultPosition, Size size=DefaultSize,
2433 wxArrayString choices=wxPyEmptyStringArray,
2434 int majorDimension=0, long style=RA_HORIZONTAL,
2435 Validator validator=DefaultValidator,
b2dc1044 2436 String name=RadioBoxNameStr) -> RadioBox
0df68c9f 2437 """
69223c70 2438 if kwargs.has_key('point'): kwargs['pos'] = kwargs['point'];del kwargs['point']
54f9ee45 2439 newobj = _controls_.new_RadioBox(*args, **kwargs)
d14a1e28 2440 self.this = newobj.this
c95e68d8 2441 self.thisown = 1
d14a1e28 2442 del newobj.thisown
0220cbc1 2443 self._setOORInfo(self)
e811c8ce
RD
2444
2445 def Create(*args, **kwargs):
0df68c9f 2446 """
248ed943
RD
2447 Create(self, Window parent, int id=-1, String label=EmptyString,
2448 Point pos=DefaultPosition, Size size=DefaultSize,
2449 wxArrayString choices=wxPyEmptyStringArray,
2450 int majorDimension=0, long style=RA_HORIZONTAL,
2451 Validator validator=DefaultValidator,
b2dc1044 2452 String name=RadioBoxNameStr) -> bool
0df68c9f 2453 """
54f9ee45 2454 return _controls_.RadioBox_Create(*args, **kwargs)
e811c8ce
RD
2455
2456 def SetSelection(*args, **kwargs):
a95a7133 2457 """SetSelection(self, int n)"""
54f9ee45 2458 return _controls_.RadioBox_SetSelection(*args, **kwargs)
e811c8ce
RD
2459
2460 def GetSelection(*args, **kwargs):
a95a7133 2461 """GetSelection(self) -> int"""
54f9ee45 2462 return _controls_.RadioBox_GetSelection(*args, **kwargs)
e811c8ce
RD
2463
2464 def GetStringSelection(*args, **kwargs):
a95a7133 2465 """GetStringSelection(self) -> String"""
54f9ee45 2466 return _controls_.RadioBox_GetStringSelection(*args, **kwargs)
e811c8ce
RD
2467
2468 def SetStringSelection(*args, **kwargs):
a95a7133 2469 """SetStringSelection(self, String s) -> bool"""
54f9ee45 2470 return _controls_.RadioBox_SetStringSelection(*args, **kwargs)
e811c8ce
RD
2471
2472 def GetCount(*args, **kwargs):
a95a7133 2473 """GetCount(self) -> int"""
54f9ee45 2474 return _controls_.RadioBox_GetCount(*args, **kwargs)
e811c8ce
RD
2475
2476 def FindString(*args, **kwargs):
a95a7133 2477 """FindString(self, String s) -> int"""
54f9ee45 2478 return _controls_.RadioBox_FindString(*args, **kwargs)
e811c8ce
RD
2479
2480 def GetString(*args, **kwargs):
a95a7133 2481 """GetString(self, int n) -> String"""
54f9ee45 2482 return _controls_.RadioBox_GetString(*args, **kwargs)
e811c8ce
RD
2483
2484 def SetString(*args, **kwargs):
a95a7133 2485 """SetString(self, int n, String label)"""
54f9ee45 2486 return _controls_.RadioBox_SetString(*args, **kwargs)
e811c8ce 2487
d14a1e28
RD
2488 GetItemLabel = GetString
2489 SetItemLabel = SetString
e811c8ce 2490 def EnableItem(*args, **kwargs):
a95a7133 2491 """EnableItem(self, int n, bool enable=True)"""
54f9ee45 2492 return _controls_.RadioBox_EnableItem(*args, **kwargs)
e811c8ce
RD
2493
2494 def ShowItem(*args, **kwargs):
a95a7133 2495 """ShowItem(self, int n, bool show=True)"""
54f9ee45 2496 return _controls_.RadioBox_ShowItem(*args, **kwargs)
e811c8ce
RD
2497
2498 def GetColumnCount(*args, **kwargs):
a95a7133 2499 """GetColumnCount(self) -> int"""
54f9ee45 2500 return _controls_.RadioBox_GetColumnCount(*args, **kwargs)
e811c8ce
RD
2501
2502 def GetRowCount(*args, **kwargs):
a95a7133 2503 """GetRowCount(self) -> int"""
54f9ee45 2504 return _controls_.RadioBox_GetRowCount(*args, **kwargs)
e811c8ce
RD
2505
2506 def GetNextItem(*args, **kwargs):
a95a7133 2507 """GetNextItem(self, int item, int dir, long style) -> int"""
54f9ee45 2508 return _controls_.RadioBox_GetNextItem(*args, **kwargs)
e811c8ce 2509
22bfe96c 2510 def GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
2511 """
2512 GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
2513
2514 Get the default attributes for this class. This is useful if you want
2515 to use the same font or colour in your own control as in a standard
2516 control -- which is a much better idea than hard coding specific
2517 colours or fonts which might look completely out of place on the
2518 user's system, especially if it uses themes.
2519
2520 The variant parameter is only relevant under Mac currently and is
2521 ignore under other platforms. Under Mac, it will change the size of
2522 the returned font. See `wx.Window.SetWindowVariant` for more about
2523 this.
2524 """
22bfe96c
RD
2525 return _controls_.RadioBox_GetClassDefaultAttributes(*args, **kwargs)
2526
2527 GetClassDefaultAttributes = staticmethod(GetClassDefaultAttributes)
c95e68d8 2528
d14a1e28
RD
2529class RadioBoxPtr(RadioBox):
2530 def __init__(self, this):
2531 self.this = this
2532 if not hasattr(self,"thisown"): self.thisown = 0
2533 self.__class__ = RadioBox
54f9ee45 2534_controls_.RadioBox_swigregister(RadioBoxPtr)
b2dc1044
RD
2535RadioBoxNameStr = cvar.RadioBoxNameStr
2536RadioButtonNameStr = cvar.RadioButtonNameStr
c95e68d8 2537
d14a1e28 2538def PreRadioBox(*args, **kwargs):
e811c8ce 2539 """PreRadioBox() -> RadioBox"""
54f9ee45 2540 val = _controls_.new_PreRadioBox(*args, **kwargs)
aa2a5b86
RD
2541 val.thisown = 1
2542 return val
2543
22bfe96c 2544def RadioBox_GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
2545 """
2546 RadioBox_GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
2547
2548 Get the default attributes for this class. This is useful if you want
2549 to use the same font or colour in your own control as in a standard
2550 control -- which is a much better idea than hard coding specific
2551 colours or fonts which might look completely out of place on the
2552 user's system, especially if it uses themes.
2553
2554 The variant parameter is only relevant under Mac currently and is
2555 ignore under other platforms. Under Mac, it will change the size of
2556 the returned font. See `wx.Window.SetWindowVariant` for more about
2557 this.
2558 """
22bfe96c
RD
2559 return _controls_.RadioBox_GetClassDefaultAttributes(*args, **kwargs)
2560
d14a1e28 2561#---------------------------------------------------------------------------
c95e68d8 2562
54f9ee45 2563class RadioButton(_core.Control):
093d3ff1 2564 """Proxy of C++ RadioButton class"""
e811c8ce
RD
2565 def __repr__(self):
2566 return "<%s.%s; proxy of C++ wxRadioButton instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 2567 def __init__(self, *args, **kwargs):
0df68c9f 2568 """
248ed943
RD
2569 __init__(self, Window parent, int id=-1, String label=EmptyString,
2570 Point pos=DefaultPosition, Size size=DefaultSize,
2571 long style=0, Validator validator=DefaultValidator,
2572 String name=RadioButtonNameStr) -> RadioButton
0df68c9f 2573 """
54f9ee45 2574 newobj = _controls_.new_RadioButton(*args, **kwargs)
d14a1e28 2575 self.this = newobj.this
9d6da64a 2576 self.thisown = 1
d14a1e28
RD
2577 del newobj.thisown
2578 self._setOORInfo(self)
e811c8ce
RD
2579
2580 def Create(*args, **kwargs):
0df68c9f 2581 """
248ed943
RD
2582 Create(self, Window parent, int id=-1, String label=EmptyString,
2583 Point pos=DefaultPosition, Size size=DefaultSize,
2584 long style=0, Validator validator=DefaultValidator,
2585 String name=RadioButtonNameStr) -> bool
0df68c9f 2586 """
54f9ee45 2587 return _controls_.RadioButton_Create(*args, **kwargs)
e811c8ce
RD
2588
2589 def GetValue(*args, **kwargs):
a95a7133 2590 """GetValue(self) -> bool"""
54f9ee45 2591 return _controls_.RadioButton_GetValue(*args, **kwargs)
e811c8ce
RD
2592
2593 def SetValue(*args, **kwargs):
a95a7133 2594 """SetValue(self, bool value)"""
54f9ee45 2595 return _controls_.RadioButton_SetValue(*args, **kwargs)
e811c8ce 2596
22bfe96c 2597 def GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
2598 """
2599 GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
2600
2601 Get the default attributes for this class. This is useful if you want
2602 to use the same font or colour in your own control as in a standard
2603 control -- which is a much better idea than hard coding specific
2604 colours or fonts which might look completely out of place on the
2605 user's system, especially if it uses themes.
2606
2607 The variant parameter is only relevant under Mac currently and is
2608 ignore under other platforms. Under Mac, it will change the size of
2609 the returned font. See `wx.Window.SetWindowVariant` for more about
2610 this.
2611 """
22bfe96c
RD
2612 return _controls_.RadioButton_GetClassDefaultAttributes(*args, **kwargs)
2613
2614 GetClassDefaultAttributes = staticmethod(GetClassDefaultAttributes)
9d6da64a 2615
d14a1e28
RD
2616class RadioButtonPtr(RadioButton):
2617 def __init__(self, this):
2618 self.this = this
2619 if not hasattr(self,"thisown"): self.thisown = 0
2620 self.__class__ = RadioButton
54f9ee45 2621_controls_.RadioButton_swigregister(RadioButtonPtr)
9d6da64a 2622
d14a1e28 2623def PreRadioButton(*args, **kwargs):
e811c8ce 2624 """PreRadioButton() -> RadioButton"""
54f9ee45 2625 val = _controls_.new_PreRadioButton(*args, **kwargs)
d14a1e28
RD
2626 val.thisown = 1
2627 return val
9d6da64a 2628
22bfe96c 2629def RadioButton_GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
2630 """
2631 RadioButton_GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
2632
2633 Get the default attributes for this class. This is useful if you want
2634 to use the same font or colour in your own control as in a standard
2635 control -- which is a much better idea than hard coding specific
2636 colours or fonts which might look completely out of place on the
2637 user's system, especially if it uses themes.
2638
2639 The variant parameter is only relevant under Mac currently and is
2640 ignore under other platforms. Under Mac, it will change the size of
2641 the returned font. See `wx.Window.SetWindowVariant` for more about
2642 this.
2643 """
22bfe96c
RD
2644 return _controls_.RadioButton_GetClassDefaultAttributes(*args, **kwargs)
2645
d14a1e28 2646#---------------------------------------------------------------------------
9d6da64a 2647
7557b9b5
RD
2648SL_HORIZONTAL = _controls_.SL_HORIZONTAL
2649SL_VERTICAL = _controls_.SL_VERTICAL
70b7a5fe 2650SL_TICKS = _controls_.SL_TICKS
7557b9b5
RD
2651SL_AUTOTICKS = _controls_.SL_AUTOTICKS
2652SL_LABELS = _controls_.SL_LABELS
2653SL_LEFT = _controls_.SL_LEFT
2654SL_TOP = _controls_.SL_TOP
2655SL_RIGHT = _controls_.SL_RIGHT
2656SL_BOTTOM = _controls_.SL_BOTTOM
2657SL_BOTH = _controls_.SL_BOTH
2658SL_SELRANGE = _controls_.SL_SELRANGE
2659SL_INVERSE = _controls_.SL_INVERSE
54f9ee45 2660class Slider(_core.Control):
093d3ff1 2661 """Proxy of C++ Slider class"""
e811c8ce
RD
2662 def __repr__(self):
2663 return "<%s.%s; proxy of C++ wxSlider instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 2664 def __init__(self, *args, **kwargs):
0df68c9f 2665 """
248ed943
RD
2666 __init__(self, Window parent, int id=-1, int value=0, int minValue=0,
2667 int maxValue=100, Point pos=DefaultPosition,
2668 Size size=DefaultSize, long style=SL_HORIZONTAL,
2669 Validator validator=DefaultValidator,
b2dc1044 2670 String name=SliderNameStr) -> Slider
0df68c9f 2671 """
69223c70 2672 if kwargs.has_key('point'): kwargs['pos'] = kwargs['point'];del kwargs['point']
54f9ee45 2673 newobj = _controls_.new_Slider(*args, **kwargs)
d14a1e28 2674 self.this = newobj.this
70551f47 2675 self.thisown = 1
d14a1e28 2676 del newobj.thisown
0220cbc1 2677 self._setOORInfo(self)
e811c8ce
RD
2678
2679 def Create(*args, **kwargs):
0df68c9f 2680 """
248ed943
RD
2681 Create(self, Window parent, int id=-1, int value=0, int minValue=0,
2682 int maxValue=100, Point pos=DefaultPosition,
2683 Size size=DefaultSize, long style=SL_HORIZONTAL,
2684 Validator validator=DefaultValidator,
b2dc1044 2685 String name=SliderNameStr) -> bool
0df68c9f 2686 """
54f9ee45 2687 return _controls_.Slider_Create(*args, **kwargs)
e811c8ce
RD
2688
2689 def GetValue(*args, **kwargs):
a95a7133 2690 """GetValue(self) -> int"""
54f9ee45 2691 return _controls_.Slider_GetValue(*args, **kwargs)
e811c8ce
RD
2692
2693 def SetValue(*args, **kwargs):
a95a7133 2694 """SetValue(self, int value)"""
54f9ee45 2695 return _controls_.Slider_SetValue(*args, **kwargs)
e811c8ce
RD
2696
2697 def SetRange(*args, **kwargs):
a95a7133 2698 """SetRange(self, int minValue, int maxValue)"""
54f9ee45 2699 return _controls_.Slider_SetRange(*args, **kwargs)
e811c8ce
RD
2700
2701 def GetMin(*args, **kwargs):
a95a7133 2702 """GetMin(self) -> int"""
54f9ee45 2703 return _controls_.Slider_GetMin(*args, **kwargs)
e811c8ce
RD
2704
2705 def GetMax(*args, **kwargs):
a95a7133 2706 """GetMax(self) -> int"""
54f9ee45 2707 return _controls_.Slider_GetMax(*args, **kwargs)
e811c8ce
RD
2708
2709 def SetMin(*args, **kwargs):
a95a7133 2710 """SetMin(self, int minValue)"""
54f9ee45 2711 return _controls_.Slider_SetMin(*args, **kwargs)
e811c8ce
RD
2712
2713 def SetMax(*args, **kwargs):
a95a7133 2714 """SetMax(self, int maxValue)"""
54f9ee45 2715 return _controls_.Slider_SetMax(*args, **kwargs)
e811c8ce
RD
2716
2717 def SetLineSize(*args, **kwargs):
a95a7133 2718 """SetLineSize(self, int lineSize)"""
54f9ee45 2719 return _controls_.Slider_SetLineSize(*args, **kwargs)
e811c8ce
RD
2720
2721 def SetPageSize(*args, **kwargs):
a95a7133 2722 """SetPageSize(self, int pageSize)"""
54f9ee45 2723 return _controls_.Slider_SetPageSize(*args, **kwargs)
e811c8ce
RD
2724
2725 def GetLineSize(*args, **kwargs):
a95a7133 2726 """GetLineSize(self) -> int"""
54f9ee45 2727 return _controls_.Slider_GetLineSize(*args, **kwargs)
e811c8ce
RD
2728
2729 def GetPageSize(*args, **kwargs):
a95a7133 2730 """GetPageSize(self) -> int"""
54f9ee45 2731 return _controls_.Slider_GetPageSize(*args, **kwargs)
e811c8ce
RD
2732
2733 def SetThumbLength(*args, **kwargs):
a95a7133 2734 """SetThumbLength(self, int lenPixels)"""
54f9ee45 2735 return _controls_.Slider_SetThumbLength(*args, **kwargs)
e811c8ce
RD
2736
2737 def GetThumbLength(*args, **kwargs):
a95a7133 2738 """GetThumbLength(self) -> int"""
54f9ee45 2739 return _controls_.Slider_GetThumbLength(*args, **kwargs)
e811c8ce
RD
2740
2741 def SetTickFreq(*args, **kwargs):
a95a7133 2742 """SetTickFreq(self, int n, int pos=1)"""
54f9ee45 2743 return _controls_.Slider_SetTickFreq(*args, **kwargs)
e811c8ce
RD
2744
2745 def GetTickFreq(*args, **kwargs):
a95a7133 2746 """GetTickFreq(self) -> int"""
54f9ee45 2747 return _controls_.Slider_GetTickFreq(*args, **kwargs)
e811c8ce
RD
2748
2749 def ClearTicks(*args, **kwargs):
a95a7133 2750 """ClearTicks(self)"""
54f9ee45 2751 return _controls_.Slider_ClearTicks(*args, **kwargs)
e811c8ce
RD
2752
2753 def SetTick(*args, **kwargs):
a95a7133 2754 """SetTick(self, int tickPos)"""
54f9ee45 2755 return _controls_.Slider_SetTick(*args, **kwargs)
e811c8ce
RD
2756
2757 def ClearSel(*args, **kwargs):
a95a7133 2758 """ClearSel(self)"""
54f9ee45 2759 return _controls_.Slider_ClearSel(*args, **kwargs)
e811c8ce
RD
2760
2761 def GetSelEnd(*args, **kwargs):
a95a7133 2762 """GetSelEnd(self) -> int"""
54f9ee45 2763 return _controls_.Slider_GetSelEnd(*args, **kwargs)
e811c8ce
RD
2764
2765 def GetSelStart(*args, **kwargs):
a95a7133 2766 """GetSelStart(self) -> int"""
54f9ee45 2767 return _controls_.Slider_GetSelStart(*args, **kwargs)
e811c8ce
RD
2768
2769 def SetSelection(*args, **kwargs):
a95a7133 2770 """SetSelection(self, int min, int max)"""
54f9ee45 2771 return _controls_.Slider_SetSelection(*args, **kwargs)
e811c8ce 2772
22bfe96c 2773 def GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
2774 """
2775 GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
2776
2777 Get the default attributes for this class. This is useful if you want
2778 to use the same font or colour in your own control as in a standard
2779 control -- which is a much better idea than hard coding specific
2780 colours or fonts which might look completely out of place on the
2781 user's system, especially if it uses themes.
2782
2783 The variant parameter is only relevant under Mac currently and is
2784 ignore under other platforms. Under Mac, it will change the size of
2785 the returned font. See `wx.Window.SetWindowVariant` for more about
2786 this.
2787 """
22bfe96c
RD
2788 return _controls_.Slider_GetClassDefaultAttributes(*args, **kwargs)
2789
2790 GetClassDefaultAttributes = staticmethod(GetClassDefaultAttributes)
70551f47 2791
d14a1e28
RD
2792class SliderPtr(Slider):
2793 def __init__(self, this):
2794 self.this = this
2795 if not hasattr(self,"thisown"): self.thisown = 0
2796 self.__class__ = Slider
54f9ee45 2797_controls_.Slider_swigregister(SliderPtr)
b2dc1044 2798SliderNameStr = cvar.SliderNameStr
70551f47 2799
d14a1e28 2800def PreSlider(*args, **kwargs):
e811c8ce 2801 """PreSlider() -> Slider"""
54f9ee45 2802 val = _controls_.new_PreSlider(*args, **kwargs)
aa2a5b86
RD
2803 val.thisown = 1
2804 return val
2805
22bfe96c 2806def Slider_GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
2807 """
2808 Slider_GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
2809
2810 Get the default attributes for this class. This is useful if you want
2811 to use the same font or colour in your own control as in a standard
2812 control -- which is a much better idea than hard coding specific
2813 colours or fonts which might look completely out of place on the
2814 user's system, especially if it uses themes.
2815
2816 The variant parameter is only relevant under Mac currently and is
2817 ignore under other platforms. Under Mac, it will change the size of
2818 the returned font. See `wx.Window.SetWindowVariant` for more about
2819 this.
2820 """
22bfe96c
RD
2821 return _controls_.Slider_GetClassDefaultAttributes(*args, **kwargs)
2822
d14a1e28 2823#---------------------------------------------------------------------------
70551f47 2824
54f9ee45 2825wxEVT_COMMAND_TOGGLEBUTTON_CLICKED = _controls_.wxEVT_COMMAND_TOGGLEBUTTON_CLICKED
d14a1e28
RD
2826EVT_TOGGLEBUTTON = wx.PyEventBinder( wxEVT_COMMAND_TOGGLEBUTTON_CLICKED, 1)
2827
54f9ee45 2828class ToggleButton(_core.Control):
093d3ff1 2829 """Proxy of C++ ToggleButton class"""
e811c8ce
RD
2830 def __repr__(self):
2831 return "<%s.%s; proxy of C++ wxToggleButton instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 2832 def __init__(self, *args, **kwargs):
0df68c9f 2833 """
248ed943
RD
2834 __init__(self, Window parent, int id=-1, String label=EmptyString,
2835 Point pos=DefaultPosition, Size size=DefaultSize,
2836 long style=0, Validator validator=DefaultValidator,
2837 String name=ToggleButtonNameStr) -> ToggleButton
0df68c9f 2838 """
54f9ee45 2839 newobj = _controls_.new_ToggleButton(*args, **kwargs)
d14a1e28 2840 self.this = newobj.this
70551f47 2841 self.thisown = 1
d14a1e28 2842 del newobj.thisown
0220cbc1 2843 self._setOORInfo(self)
e811c8ce
RD
2844
2845 def Create(*args, **kwargs):
0df68c9f 2846 """
248ed943
RD
2847 Create(self, Window parent, int id=-1, String label=EmptyString,
2848 Point pos=DefaultPosition, Size size=DefaultSize,
2849 long style=0, Validator validator=DefaultValidator,
2850 String name=ToggleButtonNameStr) -> bool
0df68c9f 2851 """
54f9ee45 2852 return _controls_.ToggleButton_Create(*args, **kwargs)
e811c8ce
RD
2853
2854 def SetValue(*args, **kwargs):
a95a7133 2855 """SetValue(self, bool value)"""
54f9ee45 2856 return _controls_.ToggleButton_SetValue(*args, **kwargs)
e811c8ce
RD
2857
2858 def GetValue(*args, **kwargs):
a95a7133 2859 """GetValue(self) -> bool"""
54f9ee45 2860 return _controls_.ToggleButton_GetValue(*args, **kwargs)
e811c8ce
RD
2861
2862 def SetLabel(*args, **kwargs):
15afbcd0 2863 """
a95a7133 2864 SetLabel(self, String label)
15afbcd0
RD
2865
2866 Sets the item's text.
2867 """
54f9ee45 2868 return _controls_.ToggleButton_SetLabel(*args, **kwargs)
e811c8ce 2869
22bfe96c 2870 def GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
2871 """
2872 GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
2873
2874 Get the default attributes for this class. This is useful if you want
2875 to use the same font or colour in your own control as in a standard
2876 control -- which is a much better idea than hard coding specific
2877 colours or fonts which might look completely out of place on the
2878 user's system, especially if it uses themes.
2879
2880 The variant parameter is only relevant under Mac currently and is
2881 ignore under other platforms. Under Mac, it will change the size of
2882 the returned font. See `wx.Window.SetWindowVariant` for more about
2883 this.
2884 """
22bfe96c
RD
2885 return _controls_.ToggleButton_GetClassDefaultAttributes(*args, **kwargs)
2886
2887 GetClassDefaultAttributes = staticmethod(GetClassDefaultAttributes)
70551f47 2888
d14a1e28
RD
2889class ToggleButtonPtr(ToggleButton):
2890 def __init__(self, this):
2891 self.this = this
2892 if not hasattr(self,"thisown"): self.thisown = 0
2893 self.__class__ = ToggleButton
54f9ee45 2894_controls_.ToggleButton_swigregister(ToggleButtonPtr)
b2dc1044 2895ToggleButtonNameStr = cvar.ToggleButtonNameStr
70551f47 2896
d14a1e28 2897def PreToggleButton(*args, **kwargs):
e811c8ce 2898 """PreToggleButton() -> ToggleButton"""
54f9ee45 2899 val = _controls_.new_PreToggleButton(*args, **kwargs)
aa2a5b86
RD
2900 val.thisown = 1
2901 return val
2902
22bfe96c 2903def ToggleButton_GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
2904 """
2905 ToggleButton_GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
2906
2907 Get the default attributes for this class. This is useful if you want
2908 to use the same font or colour in your own control as in a standard
2909 control -- which is a much better idea than hard coding specific
2910 colours or fonts which might look completely out of place on the
2911 user's system, especially if it uses themes.
2912
2913 The variant parameter is only relevant under Mac currently and is
2914 ignore under other platforms. Under Mac, it will change the size of
2915 the returned font. See `wx.Window.SetWindowVariant` for more about
2916 this.
2917 """
22bfe96c
RD
2918 return _controls_.ToggleButton_GetClassDefaultAttributes(*args, **kwargs)
2919
d14a1e28
RD
2920#---------------------------------------------------------------------------
2921
8ac8dba0 2922class BookCtrlBase(_core.Control):
093d3ff1 2923 """Proxy of C++ BookCtrlBase class"""
d14a1e28
RD
2924 def __init__(self): raise RuntimeError, "No constructor defined"
2925 def __repr__(self):
8ac8dba0 2926 return "<%s.%s; proxy of C++ wxBookCtrlBase instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
e811c8ce 2927 def GetPageCount(*args, **kwargs):
a95a7133 2928 """GetPageCount(self) -> size_t"""
8ac8dba0 2929 return _controls_.BookCtrlBase_GetPageCount(*args, **kwargs)
e811c8ce
RD
2930
2931 def GetPage(*args, **kwargs):
a95a7133 2932 """GetPage(self, size_t n) -> Window"""
8ac8dba0 2933 return _controls_.BookCtrlBase_GetPage(*args, **kwargs)
e811c8ce 2934
8fb0e70a
RD
2935 def GetCurrentPage(*args, **kwargs):
2936 """GetCurrentPage(self) -> Window"""
8ac8dba0 2937 return _controls_.BookCtrlBase_GetCurrentPage(*args, **kwargs)
8fb0e70a 2938
e811c8ce 2939 def GetSelection(*args, **kwargs):
a95a7133 2940 """GetSelection(self) -> int"""
8ac8dba0 2941 return _controls_.BookCtrlBase_GetSelection(*args, **kwargs)
e811c8ce
RD
2942
2943 def SetPageText(*args, **kwargs):
a95a7133 2944 """SetPageText(self, size_t n, String strText) -> bool"""
8ac8dba0 2945 return _controls_.BookCtrlBase_SetPageText(*args, **kwargs)
e811c8ce
RD
2946
2947 def GetPageText(*args, **kwargs):
a95a7133 2948 """GetPageText(self, size_t n) -> String"""
8ac8dba0 2949 return _controls_.BookCtrlBase_GetPageText(*args, **kwargs)
e811c8ce
RD
2950
2951 def SetImageList(*args, **kwargs):
a95a7133 2952 """SetImageList(self, ImageList imageList)"""
8ac8dba0 2953 return _controls_.BookCtrlBase_SetImageList(*args, **kwargs)
e811c8ce
RD
2954
2955 def AssignImageList(*args, **kwargs):
a95a7133 2956 """AssignImageList(self, ImageList imageList)"""
8ac8dba0 2957 return _controls_.BookCtrlBase_AssignImageList(*args, **kwargs)
e811c8ce
RD
2958
2959 def GetImageList(*args, **kwargs):
a95a7133 2960 """GetImageList(self) -> ImageList"""
8ac8dba0 2961 return _controls_.BookCtrlBase_GetImageList(*args, **kwargs)
e811c8ce
RD
2962
2963 def GetPageImage(*args, **kwargs):
a95a7133 2964 """GetPageImage(self, size_t n) -> int"""
8ac8dba0 2965 return _controls_.BookCtrlBase_GetPageImage(*args, **kwargs)
e811c8ce
RD
2966
2967 def SetPageImage(*args, **kwargs):
a95a7133 2968 """SetPageImage(self, size_t n, int imageId) -> bool"""
8ac8dba0 2969 return _controls_.BookCtrlBase_SetPageImage(*args, **kwargs)
e811c8ce
RD
2970
2971 def SetPageSize(*args, **kwargs):
a95a7133 2972 """SetPageSize(self, Size size)"""
8ac8dba0 2973 return _controls_.BookCtrlBase_SetPageSize(*args, **kwargs)
e811c8ce
RD
2974
2975 def CalcSizeFromPage(*args, **kwargs):
a95a7133 2976 """CalcSizeFromPage(self, Size sizePage) -> Size"""
8ac8dba0 2977 return _controls_.BookCtrlBase_CalcSizeFromPage(*args, **kwargs)
e811c8ce
RD
2978
2979 def DeletePage(*args, **kwargs):
a95a7133 2980 """DeletePage(self, size_t n) -> bool"""
8ac8dba0 2981 return _controls_.BookCtrlBase_DeletePage(*args, **kwargs)
e811c8ce
RD
2982
2983 def RemovePage(*args, **kwargs):
a95a7133 2984 """RemovePage(self, size_t n) -> bool"""
8ac8dba0 2985 return _controls_.BookCtrlBase_RemovePage(*args, **kwargs)
e811c8ce
RD
2986
2987 def DeleteAllPages(*args, **kwargs):
a95a7133 2988 """DeleteAllPages(self) -> bool"""
8ac8dba0 2989 return _controls_.BookCtrlBase_DeleteAllPages(*args, **kwargs)
e811c8ce
RD
2990
2991 def AddPage(*args, **kwargs):
a95a7133 2992 """AddPage(self, Window page, String text, bool select=False, int imageId=-1) -> bool"""
8ac8dba0 2993 return _controls_.BookCtrlBase_AddPage(*args, **kwargs)
e811c8ce
RD
2994
2995 def InsertPage(*args, **kwargs):
0df68c9f 2996 """
a95a7133 2997 InsertPage(self, size_t n, Window page, String text, bool select=False,
0df68c9f
RD
2998 int imageId=-1) -> bool
2999 """
8ac8dba0 3000 return _controls_.BookCtrlBase_InsertPage(*args, **kwargs)
e811c8ce
RD
3001
3002 def SetSelection(*args, **kwargs):
a95a7133 3003 """SetSelection(self, size_t n) -> int"""
8ac8dba0 3004 return _controls_.BookCtrlBase_SetSelection(*args, **kwargs)
e811c8ce
RD
3005
3006 def AdvanceSelection(*args, **kwargs):
a95a7133 3007 """AdvanceSelection(self, bool forward=True)"""
8ac8dba0 3008 return _controls_.BookCtrlBase_AdvanceSelection(*args, **kwargs)
e811c8ce 3009
22bfe96c 3010 def GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
3011 """
3012 GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
3013
3014 Get the default attributes for this class. This is useful if you want
3015 to use the same font or colour in your own control as in a standard
3016 control -- which is a much better idea than hard coding specific
3017 colours or fonts which might look completely out of place on the
3018 user's system, especially if it uses themes.
3019
3020 The variant parameter is only relevant under Mac currently and is
3021 ignore under other platforms. Under Mac, it will change the size of
3022 the returned font. See `wx.Window.SetWindowVariant` for more about
3023 this.
3024 """
8ac8dba0 3025 return _controls_.BookCtrlBase_GetClassDefaultAttributes(*args, **kwargs)
22bfe96c
RD
3026
3027 GetClassDefaultAttributes = staticmethod(GetClassDefaultAttributes)
70551f47 3028
8ac8dba0 3029class BookCtrlBasePtr(BookCtrlBase):
d14a1e28 3030 def __init__(self, this):
62bd0874 3031 self.this = this
d14a1e28 3032 if not hasattr(self,"thisown"): self.thisown = 0
8ac8dba0
RD
3033 self.__class__ = BookCtrlBase
3034_controls_.BookCtrlBase_swigregister(BookCtrlBasePtr)
51b83b37 3035NotebookNameStr = cvar.NotebookNameStr
d14a1e28 3036
8ac8dba0 3037def BookCtrlBase_GetClassDefaultAttributes(*args, **kwargs):
110da5b0 3038 """
8ac8dba0 3039 BookCtrlBase_GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
110da5b0
RD
3040
3041 Get the default attributes for this class. This is useful if you want
3042 to use the same font or colour in your own control as in a standard
3043 control -- which is a much better idea than hard coding specific
3044 colours or fonts which might look completely out of place on the
3045 user's system, especially if it uses themes.
3046
3047 The variant parameter is only relevant under Mac currently and is
3048 ignore under other platforms. Under Mac, it will change the size of
3049 the returned font. See `wx.Window.SetWindowVariant` for more about
3050 this.
3051 """
8ac8dba0 3052 return _controls_.BookCtrlBase_GetClassDefaultAttributes(*args, **kwargs)
22bfe96c 3053
8ac8dba0 3054class BookCtrlBaseEvent(_core.NotifyEvent):
093d3ff1 3055 """Proxy of C++ BookCtrlBaseEvent class"""
e811c8ce 3056 def __repr__(self):
8ac8dba0 3057 return "<%s.%s; proxy of C++ wxBookCtrlBaseEvent instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 3058 def __init__(self, *args, **kwargs):
0df68c9f 3059 """
a95a7133 3060 __init__(self, wxEventType commandType=wxEVT_NULL, int id=0, int nSel=-1,
8ac8dba0 3061 int nOldSel=-1) -> BookCtrlBaseEvent
0df68c9f 3062 """
8ac8dba0 3063 newobj = _controls_.new_BookCtrlBaseEvent(*args, **kwargs)
d14a1e28
RD
3064 self.this = newobj.this
3065 self.thisown = 1
3066 del newobj.thisown
e811c8ce 3067 def GetSelection(*args, **kwargs):
a95a7133 3068 """GetSelection(self) -> int"""
8ac8dba0 3069 return _controls_.BookCtrlBaseEvent_GetSelection(*args, **kwargs)
e811c8ce
RD
3070
3071 def SetSelection(*args, **kwargs):
a95a7133 3072 """SetSelection(self, int nSel)"""
8ac8dba0 3073 return _controls_.BookCtrlBaseEvent_SetSelection(*args, **kwargs)
e811c8ce
RD
3074
3075 def GetOldSelection(*args, **kwargs):
a95a7133 3076 """GetOldSelection(self) -> int"""
8ac8dba0 3077 return _controls_.BookCtrlBaseEvent_GetOldSelection(*args, **kwargs)
e811c8ce
RD
3078
3079 def SetOldSelection(*args, **kwargs):
a95a7133 3080 """SetOldSelection(self, int nOldSel)"""
8ac8dba0 3081 return _controls_.BookCtrlBaseEvent_SetOldSelection(*args, **kwargs)
e811c8ce 3082
d14a1e28 3083
8ac8dba0 3084class BookCtrlBaseEventPtr(BookCtrlBaseEvent):
d14a1e28
RD
3085 def __init__(self, this):
3086 self.this = this
3087 if not hasattr(self,"thisown"): self.thisown = 0
8ac8dba0
RD
3088 self.__class__ = BookCtrlBaseEvent
3089_controls_.BookCtrlBaseEvent_swigregister(BookCtrlBaseEventPtr)
d14a1e28
RD
3090
3091#---------------------------------------------------------------------------
3092
54f9ee45
RD
3093NB_FIXEDWIDTH = _controls_.NB_FIXEDWIDTH
3094NB_TOP = _controls_.NB_TOP
3095NB_LEFT = _controls_.NB_LEFT
3096NB_RIGHT = _controls_.NB_RIGHT
3097NB_BOTTOM = _controls_.NB_BOTTOM
3098NB_MULTILINE = _controls_.NB_MULTILINE
8e738329 3099NB_NOPAGETHEME = _controls_.NB_NOPAGETHEME
54f9ee45
RD
3100NB_HITTEST_NOWHERE = _controls_.NB_HITTEST_NOWHERE
3101NB_HITTEST_ONICON = _controls_.NB_HITTEST_ONICON
3102NB_HITTEST_ONLABEL = _controls_.NB_HITTEST_ONLABEL
3103NB_HITTEST_ONITEM = _controls_.NB_HITTEST_ONITEM
8ac8dba0 3104class Notebook(BookCtrlBase):
093d3ff1 3105 """Proxy of C++ Notebook class"""
e811c8ce
RD
3106 def __repr__(self):
3107 return "<%s.%s; proxy of C++ wxNotebook instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 3108 def __init__(self, *args, **kwargs):
0df68c9f 3109 """
a95a7133 3110 __init__(self, Window parent, int id=-1, Point pos=DefaultPosition,
51b83b37 3111 Size size=DefaultSize, long style=0, String name=NotebookNameStr) -> Notebook
0df68c9f 3112 """
54f9ee45 3113 newobj = _controls_.new_Notebook(*args, **kwargs)
d14a1e28 3114 self.this = newobj.this
62bd0874 3115 self.thisown = 1
d14a1e28 3116 del newobj.thisown
0220cbc1 3117 self._setOORInfo(self)
e811c8ce
RD
3118
3119 def Create(*args, **kwargs):
0df68c9f 3120 """
248ed943 3121 Create(self, Window parent, int id=-1, Point pos=DefaultPosition,
51b83b37 3122 Size size=DefaultSize, long style=0, String name=NotebookNameStr) -> bool
0df68c9f 3123 """
54f9ee45 3124 return _controls_.Notebook_Create(*args, **kwargs)
e811c8ce
RD
3125
3126 def GetRowCount(*args, **kwargs):
a95a7133 3127 """GetRowCount(self) -> int"""
54f9ee45 3128 return _controls_.Notebook_GetRowCount(*args, **kwargs)
e811c8ce
RD
3129
3130 def SetPadding(*args, **kwargs):
a95a7133 3131 """SetPadding(self, Size padding)"""
54f9ee45 3132 return _controls_.Notebook_SetPadding(*args, **kwargs)
e811c8ce
RD
3133
3134 def SetTabSize(*args, **kwargs):
a95a7133 3135 """SetTabSize(self, Size sz)"""
54f9ee45 3136 return _controls_.Notebook_SetTabSize(*args, **kwargs)
e811c8ce
RD
3137
3138 def HitTest(*args, **kwargs):
fd2dc343
RD
3139 """
3140 HitTest(Point pt) -> (tab, where)
3141
3142 Returns the tab which is hit, and flags indicating where using
3143 wx.NB_HITTEST flags.
3144 """
54f9ee45 3145 return _controls_.Notebook_HitTest(*args, **kwargs)
e811c8ce
RD
3146
3147 def CalcSizeFromPage(*args, **kwargs):
a95a7133 3148 """CalcSizeFromPage(self, Size sizePage) -> Size"""
54f9ee45 3149 return _controls_.Notebook_CalcSizeFromPage(*args, **kwargs)
e811c8ce 3150
8e738329
RD
3151 def GetThemeBackgroundColour(*args, **kwargs):
3152 """GetThemeBackgroundColour(self) -> Colour"""
3153 return _controls_.Notebook_GetThemeBackgroundColour(*args, **kwargs)
3154
22bfe96c 3155 def GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
3156 """
3157 GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
3158
3159 Get the default attributes for this class. This is useful if you want
3160 to use the same font or colour in your own control as in a standard
3161 control -- which is a much better idea than hard coding specific
3162 colours or fonts which might look completely out of place on the
3163 user's system, especially if it uses themes.
3164
3165 The variant parameter is only relevant under Mac currently and is
3166 ignore under other platforms. Under Mac, it will change the size of
3167 the returned font. See `wx.Window.SetWindowVariant` for more about
3168 this.
3169 """
22bfe96c
RD
3170 return _controls_.Notebook_GetClassDefaultAttributes(*args, **kwargs)
3171
3172 GetClassDefaultAttributes = staticmethod(GetClassDefaultAttributes)
62bd0874 3173
d14a1e28
RD
3174class NotebookPtr(Notebook):
3175 def __init__(self, this):
3176 self.this = this
3177 if not hasattr(self,"thisown"): self.thisown = 0
3178 self.__class__ = Notebook
54f9ee45 3179_controls_.Notebook_swigregister(NotebookPtr)
62bd0874 3180
d14a1e28 3181def PreNotebook(*args, **kwargs):
e811c8ce 3182 """PreNotebook() -> Notebook"""
54f9ee45 3183 val = _controls_.new_PreNotebook(*args, **kwargs)
aa2a5b86
RD
3184 val.thisown = 1
3185 return val
3186
22bfe96c 3187def Notebook_GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
3188 """
3189 Notebook_GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
3190
3191 Get the default attributes for this class. This is useful if you want
3192 to use the same font or colour in your own control as in a standard
3193 control -- which is a much better idea than hard coding specific
3194 colours or fonts which might look completely out of place on the
3195 user's system, especially if it uses themes.
3196
3197 The variant parameter is only relevant under Mac currently and is
3198 ignore under other platforms. Under Mac, it will change the size of
3199 the returned font. See `wx.Window.SetWindowVariant` for more about
3200 this.
3201 """
22bfe96c
RD
3202 return _controls_.Notebook_GetClassDefaultAttributes(*args, **kwargs)
3203
8ac8dba0 3204class NotebookEvent(BookCtrlBaseEvent):
093d3ff1 3205 """Proxy of C++ NotebookEvent class"""
e811c8ce
RD
3206 def __repr__(self):
3207 return "<%s.%s; proxy of C++ wxNotebookEvent instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 3208 def __init__(self, *args, **kwargs):
0df68c9f 3209 """
a95a7133 3210 __init__(self, wxEventType commandType=wxEVT_NULL, int id=0, int nSel=-1,
0df68c9f
RD
3211 int nOldSel=-1) -> NotebookEvent
3212 """
54f9ee45 3213 newobj = _controls_.new_NotebookEvent(*args, **kwargs)
d14a1e28
RD
3214 self.this = newobj.this
3215 self.thisown = 1
3216 del newobj.thisown
62bd0874 3217
d14a1e28
RD
3218class NotebookEventPtr(NotebookEvent):
3219 def __init__(self, this):
70551f47 3220 self.this = this
d14a1e28
RD
3221 if not hasattr(self,"thisown"): self.thisown = 0
3222 self.__class__ = NotebookEvent
54f9ee45 3223_controls_.NotebookEvent_swigregister(NotebookEventPtr)
d14a1e28 3224
54f9ee45
RD
3225wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGED = _controls_.wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGED
3226wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGING = _controls_.wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGING
d14a1e28
RD
3227# wxNotebook events
3228EVT_NOTEBOOK_PAGE_CHANGED = wx.PyEventBinder( wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGED, 1 )
3229EVT_NOTEBOOK_PAGE_CHANGING = wx.PyEventBinder( wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGING, 1 )
3230
3231#----------------------------------------------------------------------------
3232
3233class NotebookPage(wx.Panel):
3234 """
3235 There is an old (and apparently unsolvable) bug when placing a
7557b9b5 3236 window with a nonstandard background colour in a wx.Notebook on
70b7a5fe 3237 wxGTK1, as the notbooks's background colour would always be used
d14a1e28
RD
3238 when the window is refreshed. The solution is to place a panel in
3239 the notbook and the coloured window on the panel, sized to cover
3240 the panel. This simple class does that for you, just put an
3241 instance of this in the notebook and make your regular window a
3242 child of this one and it will handle the resize for you.
3243 """
3244 def __init__(self, parent, id=-1,
3245 pos=wx.DefaultPosition, size=wx.DefaultSize,
3246 style=wx.TAB_TRAVERSAL, name="panel"):
3247 wx.Panel.__init__(self, parent, id, pos, size, style, name)
3248 self.child = None
7557b9b5 3249 self.Bind(wx.EVT_SIZE, self.OnSize)
2ef75293 3250
d14a1e28
RD
3251 def OnSize(self, evt):
3252 if self.child is None:
3253 children = self.GetChildren()
3254 if len(children):
3255 self.child = children[0]
3256 if self.child:
3257 self.child.SetPosition((0,0))
3258 self.child.SetSize(self.GetSize())
3259
3260
3261#---------------------------------------------------------------------------
3262
54f9ee45
RD
3263LB_DEFAULT = _controls_.LB_DEFAULT
3264LB_TOP = _controls_.LB_TOP
3265LB_BOTTOM = _controls_.LB_BOTTOM
3266LB_LEFT = _controls_.LB_LEFT
3267LB_RIGHT = _controls_.LB_RIGHT
3268LB_ALIGN_MASK = _controls_.LB_ALIGN_MASK
8ac8dba0 3269class Listbook(BookCtrlBase):
093d3ff1 3270 """Proxy of C++ Listbook class"""
e811c8ce
RD
3271 def __repr__(self):
3272 return "<%s.%s; proxy of C++ wxListbook instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 3273 def __init__(self, *args, **kwargs):
0df68c9f 3274 """
a95a7133 3275 __init__(self, Window parent, int id=-1, Point pos=DefaultPosition,
4f89f6a3 3276 Size size=DefaultSize, long style=0, String name=EmptyString) -> Listbook
0df68c9f 3277 """
54f9ee45 3278 newobj = _controls_.new_Listbook(*args, **kwargs)
d14a1e28 3279 self.this = newobj.this
70551f47 3280 self.thisown = 1
d14a1e28 3281 del newobj.thisown
0220cbc1 3282 self._setOORInfo(self)
e811c8ce
RD
3283
3284 def Create(*args, **kwargs):
0df68c9f 3285 """
248ed943
RD
3286 Create(self, Window parent, int id=-1, Point pos=DefaultPosition,
3287 Size size=DefaultSize, long style=0, String name=EmptyString) -> bool
0df68c9f 3288 """
54f9ee45 3289 return _controls_.Listbook_Create(*args, **kwargs)
e811c8ce
RD
3290
3291 def IsVertical(*args, **kwargs):
a95a7133 3292 """IsVertical(self) -> bool"""
54f9ee45 3293 return _controls_.Listbook_IsVertical(*args, **kwargs)
e811c8ce 3294
1fbf26be
RD
3295 def GetListView(*args, **kwargs):
3296 """GetListView(self) -> ListView"""
3297 return _controls_.Listbook_GetListView(*args, **kwargs)
3298
70551f47 3299
d14a1e28
RD
3300class ListbookPtr(Listbook):
3301 def __init__(self, this):
3302 self.this = this
3303 if not hasattr(self,"thisown"): self.thisown = 0
3304 self.__class__ = Listbook
54f9ee45 3305_controls_.Listbook_swigregister(ListbookPtr)
70551f47 3306
d14a1e28 3307def PreListbook(*args, **kwargs):
e811c8ce 3308 """PreListbook() -> Listbook"""
54f9ee45 3309 val = _controls_.new_PreListbook(*args, **kwargs)
aa2a5b86
RD
3310 val.thisown = 1
3311 return val
3312
8ac8dba0 3313class ListbookEvent(BookCtrlBaseEvent):
093d3ff1 3314 """Proxy of C++ ListbookEvent class"""
e811c8ce
RD
3315 def __repr__(self):
3316 return "<%s.%s; proxy of C++ wxListbookEvent instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 3317 def __init__(self, *args, **kwargs):
0df68c9f 3318 """
a95a7133 3319 __init__(self, wxEventType commandType=wxEVT_NULL, int id=0, int nSel=-1,
0df68c9f
RD
3320 int nOldSel=-1) -> ListbookEvent
3321 """
54f9ee45 3322 newobj = _controls_.new_ListbookEvent(*args, **kwargs)
d14a1e28
RD
3323 self.this = newobj.this
3324 self.thisown = 1
3325 del newobj.thisown
70551f47 3326
d14a1e28
RD
3327class ListbookEventPtr(ListbookEvent):
3328 def __init__(self, this):
70551f47 3329 self.this = this
d14a1e28
RD
3330 if not hasattr(self,"thisown"): self.thisown = 0
3331 self.__class__ = ListbookEvent
54f9ee45 3332_controls_.ListbookEvent_swigregister(ListbookEventPtr)
d14a1e28 3333
54f9ee45
RD
3334wxEVT_COMMAND_LISTBOOK_PAGE_CHANGED = _controls_.wxEVT_COMMAND_LISTBOOK_PAGE_CHANGED
3335wxEVT_COMMAND_LISTBOOK_PAGE_CHANGING = _controls_.wxEVT_COMMAND_LISTBOOK_PAGE_CHANGING
d14a1e28
RD
3336EVT_LISTBOOK_PAGE_CHANGED = wx.PyEventBinder( wxEVT_COMMAND_LISTBOOK_PAGE_CHANGED, 1 )
3337EVT_LISTBOOK_PAGE_CHANGING = wx.PyEventBinder( wxEVT_COMMAND_LISTBOOK_PAGE_CHANGING, 1 )
3338
2ef75293
RD
3339CHB_DEFAULT = _controls_.CHB_DEFAULT
3340CHB_TOP = _controls_.CHB_TOP
3341CHB_BOTTOM = _controls_.CHB_BOTTOM
3342CHB_LEFT = _controls_.CHB_LEFT
3343CHB_RIGHT = _controls_.CHB_RIGHT
3344CHB_ALIGN_MASK = _controls_.CHB_ALIGN_MASK
8ac8dba0 3345class Choicebook(BookCtrlBase):
093d3ff1 3346 """Proxy of C++ Choicebook class"""
2ef75293
RD
3347 def __repr__(self):
3348 return "<%s.%s; proxy of C++ wxChoicebook instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
3349 def __init__(self, *args, **kwargs):
3350 """
3351 __init__(self, Window parent, int id, Point pos=DefaultPosition, Size size=DefaultSize,
3352 long style=0, String name=EmptyString) -> Choicebook
3353 """
3354 newobj = _controls_.new_Choicebook(*args, **kwargs)
3355 self.this = newobj.this
3356 self.thisown = 1
3357 del newobj.thisown
3358 self._setOORInfo(self)
3359
3360 def Create(*args, **kwargs):
3361 """
3362 Create(self, Window parent, int id, Point pos=DefaultPosition, Size size=DefaultSize,
3363 long style=0, String name=EmptyString) -> bool
3364 """
3365 return _controls_.Choicebook_Create(*args, **kwargs)
3366
3367 def IsVertical(*args, **kwargs):
3368 """IsVertical(self) -> bool"""
3369 return _controls_.Choicebook_IsVertical(*args, **kwargs)
3370
70b7a5fe
RD
3371 def GetChoiceCtrl(*args, **kwargs):
3372 """GetChoiceCtrl(self) -> Choice"""
3373 return _controls_.Choicebook_GetChoiceCtrl(*args, **kwargs)
3374
2ef75293
RD
3375 def DeleteAllPages(*args, **kwargs):
3376 """DeleteAllPages(self) -> bool"""
3377 return _controls_.Choicebook_DeleteAllPages(*args, **kwargs)
3378
3379
3380class ChoicebookPtr(Choicebook):
3381 def __init__(self, this):
3382 self.this = this
3383 if not hasattr(self,"thisown"): self.thisown = 0
3384 self.__class__ = Choicebook
3385_controls_.Choicebook_swigregister(ChoicebookPtr)
3386
3387def PreChoicebook(*args, **kwargs):
3388 """PreChoicebook() -> Choicebook"""
3389 val = _controls_.new_PreChoicebook(*args, **kwargs)
3390 val.thisown = 1
3391 return val
3392
8ac8dba0 3393class ChoicebookEvent(BookCtrlBaseEvent):
093d3ff1 3394 """Proxy of C++ ChoicebookEvent class"""
2ef75293
RD
3395 def __repr__(self):
3396 return "<%s.%s; proxy of C++ wxChoicebookEvent instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
3397 def __init__(self, *args, **kwargs):
3398 """
3399 __init__(self, wxEventType commandType=wxEVT_NULL, int id=0, int nSel=-1,
3400 int nOldSel=-1) -> ChoicebookEvent
3401 """
3402 newobj = _controls_.new_ChoicebookEvent(*args, **kwargs)
3403 self.this = newobj.this
3404 self.thisown = 1
3405 del newobj.thisown
3406
3407class ChoicebookEventPtr(ChoicebookEvent):
3408 def __init__(self, this):
3409 self.this = this
3410 if not hasattr(self,"thisown"): self.thisown = 0
3411 self.__class__ = ChoicebookEvent
3412_controls_.ChoicebookEvent_swigregister(ChoicebookEventPtr)
3413
3414wxEVT_COMMAND_CHOICEBOOK_PAGE_CHANGED = _controls_.wxEVT_COMMAND_CHOICEBOOK_PAGE_CHANGED
3415wxEVT_COMMAND_CHOICEBOOK_PAGE_CHANGING = _controls_.wxEVT_COMMAND_CHOICEBOOK_PAGE_CHANGING
3416EVT_CHOICEBOOK_PAGE_CHANGED = wx.PyEventBinder( wxEVT_COMMAND_CHOICEBOOK_PAGE_CHANGED, 1 )
3417EVT_CHOICEBOOK_PAGE_CHANGING = wx.PyEventBinder( wxEVT_COMMAND_CHOICEBOOK_PAGE_CHANGING, 1 )
3418
d14a1e28
RD
3419#---------------------------------------------------------------------------
3420
54f9ee45 3421class BookCtrlSizer(_core.Sizer):
093d3ff1 3422 """Proxy of C++ BookCtrlSizer class"""
e811c8ce
RD
3423 def __repr__(self):
3424 return "<%s.%s; proxy of C++ wxBookCtrlSizer instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 3425 def __init__(self, *args, **kwargs):
8ac8dba0 3426 """__init__(self, BookCtrlBase nb) -> BookCtrlSizer"""
54f9ee45 3427 newobj = _controls_.new_BookCtrlSizer(*args, **kwargs)
d14a1e28
RD
3428 self.this = newobj.this
3429 self.thisown = 1
3430 del newobj.thisown
3431 self._setOORInfo(self)
e811c8ce
RD
3432
3433 def RecalcSizes(*args, **kwargs):
248ed943
RD
3434 """
3435 RecalcSizes(self)
3436
3437 Using the sizes calculated by `CalcMin` reposition and resize all the
3438 items managed by this sizer. You should not need to call this directly as
3439 it is called by `Layout`.
3440 """
54f9ee45 3441 return _controls_.BookCtrlSizer_RecalcSizes(*args, **kwargs)
e811c8ce
RD
3442
3443 def CalcMin(*args, **kwargs):
248ed943
RD
3444 """
3445 CalcMin(self) -> Size
3446
3447 This method is where the sizer will do the actual calculation of its
3448 children's minimal sizes. You should not need to call this directly as
3449 it is called by `Layout`.
3450 """
54f9ee45 3451 return _controls_.BookCtrlSizer_CalcMin(*args, **kwargs)
e811c8ce
RD
3452
3453 def GetControl(*args, **kwargs):
8ac8dba0 3454 """GetControl(self) -> BookCtrlBase"""
54f9ee45 3455 return _controls_.BookCtrlSizer_GetControl(*args, **kwargs)
e811c8ce 3456
d14a1e28
RD
3457
3458class BookCtrlSizerPtr(BookCtrlSizer):
3459 def __init__(self, this):
3460 self.this = this
3461 if not hasattr(self,"thisown"): self.thisown = 0
3462 self.__class__ = BookCtrlSizer
54f9ee45 3463_controls_.BookCtrlSizer_swigregister(BookCtrlSizerPtr)
d14a1e28 3464
54f9ee45 3465class NotebookSizer(_core.Sizer):
093d3ff1 3466 """Proxy of C++ NotebookSizer class"""
e811c8ce
RD
3467 def __repr__(self):
3468 return "<%s.%s; proxy of C++ wxNotebookSizer instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 3469 def __init__(self, *args, **kwargs):
a95a7133 3470 """__init__(self, Notebook nb) -> NotebookSizer"""
54f9ee45 3471 newobj = _controls_.new_NotebookSizer(*args, **kwargs)
d14a1e28 3472 self.this = newobj.this
70551f47 3473 self.thisown = 1
d14a1e28 3474 del newobj.thisown
0220cbc1 3475 self._setOORInfo(self)
e811c8ce
RD
3476
3477 def RecalcSizes(*args, **kwargs):
248ed943
RD
3478 """
3479 RecalcSizes(self)
3480
3481 Using the sizes calculated by `CalcMin` reposition and resize all the
3482 items managed by this sizer. You should not need to call this directly as
3483 it is called by `Layout`.
3484 """
54f9ee45 3485 return _controls_.NotebookSizer_RecalcSizes(*args, **kwargs)
e811c8ce
RD
3486
3487 def CalcMin(*args, **kwargs):
248ed943
RD
3488 """
3489 CalcMin(self) -> Size
3490
3491 This method is where the sizer will do the actual calculation of its
3492 children's minimal sizes. You should not need to call this directly as
3493 it is called by `Layout`.
3494 """
54f9ee45 3495 return _controls_.NotebookSizer_CalcMin(*args, **kwargs)
e811c8ce
RD
3496
3497 def GetNotebook(*args, **kwargs):
a95a7133 3498 """GetNotebook(self) -> Notebook"""
54f9ee45 3499 return _controls_.NotebookSizer_GetNotebook(*args, **kwargs)
e811c8ce 3500
d14a1e28
RD
3501
3502class NotebookSizerPtr(NotebookSizer):
3503 def __init__(self, this):
3504 self.this = this
3505 if not hasattr(self,"thisown"): self.thisown = 0
3506 self.__class__ = NotebookSizer
54f9ee45 3507_controls_.NotebookSizer_swigregister(NotebookSizerPtr)
d14a1e28 3508
18ef9f51
RD
3509NotebookSizer.__init__ = wx._deprecated(NotebookSizer.__init__, "NotebookSizer is no longer needed.")
3510BookCtrlSizer.__init__ = wx._deprecated(BookCtrlSizer.__init__, "BookCtrlSizer is no longer needed.")
d14a1e28
RD
3511#---------------------------------------------------------------------------
3512
54f9ee45
RD
3513TOOL_STYLE_BUTTON = _controls_.TOOL_STYLE_BUTTON
3514TOOL_STYLE_SEPARATOR = _controls_.TOOL_STYLE_SEPARATOR
3515TOOL_STYLE_CONTROL = _controls_.TOOL_STYLE_CONTROL
3516TB_HORIZONTAL = _controls_.TB_HORIZONTAL
3517TB_VERTICAL = _controls_.TB_VERTICAL
3518TB_3DBUTTONS = _controls_.TB_3DBUTTONS
3519TB_FLAT = _controls_.TB_FLAT
3520TB_DOCKABLE = _controls_.TB_DOCKABLE
3521TB_NOICONS = _controls_.TB_NOICONS
3522TB_TEXT = _controls_.TB_TEXT
3523TB_NODIVIDER = _controls_.TB_NODIVIDER
3524TB_NOALIGN = _controls_.TB_NOALIGN
3525TB_HORZ_LAYOUT = _controls_.TB_HORZ_LAYOUT
3526TB_HORZ_TEXT = _controls_.TB_HORZ_TEXT
3527class ToolBarToolBase(_core.Object):
093d3ff1 3528 """Proxy of C++ ToolBarToolBase class"""
e811c8ce
RD
3529 def __init__(self): raise RuntimeError, "No constructor defined"
3530 def __repr__(self):
3531 return "<%s.%s; proxy of C++ wxToolBarToolBase instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
3532 def GetId(*args, **kwargs):
a95a7133 3533 """GetId(self) -> int"""
54f9ee45 3534 return _controls_.ToolBarToolBase_GetId(*args, **kwargs)
e811c8ce
RD
3535
3536 def GetControl(*args, **kwargs):
a95a7133 3537 """GetControl(self) -> Control"""
54f9ee45 3538 return _controls_.ToolBarToolBase_GetControl(*args, **kwargs)
e811c8ce
RD
3539
3540 def GetToolBar(*args, **kwargs):
a95a7133 3541 """GetToolBar(self) -> ToolBarBase"""
54f9ee45 3542 return _controls_.ToolBarToolBase_GetToolBar(*args, **kwargs)
e811c8ce
RD
3543
3544 def IsButton(*args, **kwargs):
a95a7133 3545 """IsButton(self) -> int"""
54f9ee45 3546 return _controls_.ToolBarToolBase_IsButton(*args, **kwargs)
e811c8ce
RD
3547
3548 def IsControl(*args, **kwargs):
a95a7133 3549 """IsControl(self) -> int"""
54f9ee45 3550 return _controls_.ToolBarToolBase_IsControl(*args, **kwargs)
e811c8ce
RD
3551
3552 def IsSeparator(*args, **kwargs):
a95a7133 3553 """IsSeparator(self) -> int"""
54f9ee45 3554 return _controls_.ToolBarToolBase_IsSeparator(*args, **kwargs)
e811c8ce
RD
3555
3556 def GetStyle(*args, **kwargs):
a95a7133 3557 """GetStyle(self) -> int"""
54f9ee45 3558 return _controls_.ToolBarToolBase_GetStyle(*args, **kwargs)
e811c8ce
RD
3559
3560 def GetKind(*args, **kwargs):
a95a7133 3561 """GetKind(self) -> int"""
54f9ee45 3562 return _controls_.ToolBarToolBase_GetKind(*args, **kwargs)
e811c8ce
RD
3563
3564 def IsEnabled(*args, **kwargs):
a95a7133 3565 """IsEnabled(self) -> bool"""
54f9ee45 3566 return _controls_.ToolBarToolBase_IsEnabled(*args, **kwargs)
e811c8ce
RD
3567
3568 def IsToggled(*args, **kwargs):
a95a7133 3569 """IsToggled(self) -> bool"""
54f9ee45 3570 return _controls_.ToolBarToolBase_IsToggled(*args, **kwargs)
e811c8ce
RD
3571
3572 def CanBeToggled(*args, **kwargs):
a95a7133 3573 """CanBeToggled(self) -> bool"""
54f9ee45 3574 return _controls_.ToolBarToolBase_CanBeToggled(*args, **kwargs)
e811c8ce
RD
3575
3576 def GetNormalBitmap(*args, **kwargs):
a95a7133 3577 """GetNormalBitmap(self) -> Bitmap"""
54f9ee45 3578 return _controls_.ToolBarToolBase_GetNormalBitmap(*args, **kwargs)
e811c8ce
RD
3579
3580 def GetDisabledBitmap(*args, **kwargs):
a95a7133 3581 """GetDisabledBitmap(self) -> Bitmap"""
54f9ee45 3582 return _controls_.ToolBarToolBase_GetDisabledBitmap(*args, **kwargs)
e811c8ce
RD
3583
3584 def GetBitmap(*args, **kwargs):
a95a7133 3585 """GetBitmap(self) -> Bitmap"""
54f9ee45 3586 return _controls_.ToolBarToolBase_GetBitmap(*args, **kwargs)
e811c8ce
RD
3587
3588 def GetLabel(*args, **kwargs):
a95a7133 3589 """GetLabel(self) -> String"""
54f9ee45 3590 return _controls_.ToolBarToolBase_GetLabel(*args, **kwargs)
e811c8ce
RD
3591
3592 def GetShortHelp(*args, **kwargs):
a95a7133 3593 """GetShortHelp(self) -> String"""
54f9ee45 3594 return _controls_.ToolBarToolBase_GetShortHelp(*args, **kwargs)
e811c8ce
RD
3595
3596 def GetLongHelp(*args, **kwargs):
a95a7133 3597 """GetLongHelp(self) -> String"""
54f9ee45 3598 return _controls_.ToolBarToolBase_GetLongHelp(*args, **kwargs)
e811c8ce
RD
3599
3600 def Enable(*args, **kwargs):
a95a7133 3601 """Enable(self, bool enable) -> bool"""
54f9ee45 3602 return _controls_.ToolBarToolBase_Enable(*args, **kwargs)
e811c8ce
RD
3603
3604 def Toggle(*args, **kwargs):
a95a7133 3605 """Toggle(self)"""
54f9ee45 3606 return _controls_.ToolBarToolBase_Toggle(*args, **kwargs)
e811c8ce
RD
3607
3608 def SetToggle(*args, **kwargs):
a95a7133 3609 """SetToggle(self, bool toggle) -> bool"""
54f9ee45 3610 return _controls_.ToolBarToolBase_SetToggle(*args, **kwargs)
e811c8ce
RD
3611
3612 def SetShortHelp(*args, **kwargs):
a95a7133 3613 """SetShortHelp(self, String help) -> bool"""
54f9ee45 3614 return _controls_.ToolBarToolBase_SetShortHelp(*args, **kwargs)
e811c8ce
RD
3615
3616 def SetLongHelp(*args, **kwargs):
a95a7133 3617 """SetLongHelp(self, String help) -> bool"""
54f9ee45 3618 return _controls_.ToolBarToolBase_SetLongHelp(*args, **kwargs)
e811c8ce
RD
3619
3620 def SetNormalBitmap(*args, **kwargs):
a95a7133 3621 """SetNormalBitmap(self, Bitmap bmp)"""
54f9ee45 3622 return _controls_.ToolBarToolBase_SetNormalBitmap(*args, **kwargs)
e811c8ce
RD
3623
3624 def SetDisabledBitmap(*args, **kwargs):
a95a7133 3625 """SetDisabledBitmap(self, Bitmap bmp)"""
54f9ee45 3626 return _controls_.ToolBarToolBase_SetDisabledBitmap(*args, **kwargs)
e811c8ce
RD
3627
3628 def SetLabel(*args, **kwargs):
a95a7133 3629 """SetLabel(self, String label)"""
54f9ee45 3630 return _controls_.ToolBarToolBase_SetLabel(*args, **kwargs)
e811c8ce
RD
3631
3632 def Detach(*args, **kwargs):
a95a7133 3633 """Detach(self)"""
54f9ee45 3634 return _controls_.ToolBarToolBase_Detach(*args, **kwargs)
e811c8ce
RD
3635
3636 def Attach(*args, **kwargs):
a95a7133 3637 """Attach(self, ToolBarBase tbar)"""
54f9ee45 3638 return _controls_.ToolBarToolBase_Attach(*args, **kwargs)
e811c8ce
RD
3639
3640 def GetClientData(*args, **kwargs):
a95a7133 3641 """GetClientData(self) -> PyObject"""
54f9ee45 3642 return _controls_.ToolBarToolBase_GetClientData(*args, **kwargs)
e811c8ce
RD
3643
3644 def SetClientData(*args, **kwargs):
a95a7133 3645 """SetClientData(self, PyObject clientData)"""
54f9ee45 3646 return _controls_.ToolBarToolBase_SetClientData(*args, **kwargs)
e811c8ce 3647
d14a1e28
RD
3648 GetBitmap1 = GetNormalBitmap
3649 GetBitmap2 = GetDisabledBitmap
3650 SetBitmap1 = SetNormalBitmap
3651 SetBitmap2 = SetDisabledBitmap
3652
70551f47 3653
d14a1e28
RD
3654class ToolBarToolBasePtr(ToolBarToolBase):
3655 def __init__(self, this):
3656 self.this = this
3657 if not hasattr(self,"thisown"): self.thisown = 0
3658 self.__class__ = ToolBarToolBase
54f9ee45 3659_controls_.ToolBarToolBase_swigregister(ToolBarToolBasePtr)
d14a1e28 3660
54f9ee45 3661class ToolBarBase(_core.Control):
093d3ff1 3662 """Proxy of C++ ToolBarBase class"""
e811c8ce
RD
3663 def __init__(self): raise RuntimeError, "No constructor defined"
3664 def __repr__(self):
3665 return "<%s.%s; proxy of C++ wxToolBarBase instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
3666 def DoAddTool(*args, **kwargs):
0df68c9f 3667 """
a95a7133 3668 DoAddTool(self, int id, String label, Bitmap bitmap, Bitmap bmpDisabled=wxNullBitmap,
196addbf
RD
3669 int kind=ITEM_NORMAL, String shortHelp=EmptyString,
3670 String longHelp=EmptyString,
3671 PyObject clientData=None) -> ToolBarToolBase
0df68c9f 3672 """
54f9ee45 3673 return _controls_.ToolBarBase_DoAddTool(*args, **kwargs)
e811c8ce
RD
3674
3675 def DoInsertTool(*args, **kwargs):
0df68c9f 3676 """
a95a7133 3677 DoInsertTool(self, size_t pos, int id, String label, Bitmap bitmap, Bitmap bmpDisabled=wxNullBitmap,
196addbf
RD
3678 int kind=ITEM_NORMAL,
3679 String shortHelp=EmptyString, String longHelp=EmptyString,
0df68c9f
RD
3680 PyObject clientData=None) -> ToolBarToolBase
3681 """
54f9ee45 3682 return _controls_.ToolBarBase_DoInsertTool(*args, **kwargs)
e811c8ce 3683
d14a1e28
RD
3684 # These match the original Add methods for this class, kept for
3685 # backwards compatibility with versions < 2.3.3.
3686
3687
3688 def AddTool(self, id, bitmap,
3689 pushedBitmap = wx.NullBitmap,
3690 isToggle = 0,
3691 clientData = None,
3692 shortHelpString = '',
3693 longHelpString = '') :
3694 '''Old style method to add a tool to the toolbar.'''
3695 kind = wx.ITEM_NORMAL
3696 if isToggle: kind = wx.ITEM_CHECK
3697 return self.DoAddTool(id, '', bitmap, pushedBitmap, kind,
3698 shortHelpString, longHelpString, clientData)
3699
3700 def AddSimpleTool(self, id, bitmap,
3701 shortHelpString = '',
3702 longHelpString = '',
3703 isToggle = 0):
3704 '''Old style method to add a tool to the toolbar.'''
3705 kind = wx.ITEM_NORMAL
3706 if isToggle: kind = wx.ITEM_CHECK
3707 return self.DoAddTool(id, '', bitmap, wx.NullBitmap, kind,
3708 shortHelpString, longHelpString, None)
3709
3710 def InsertTool(self, pos, id, bitmap,
3711 pushedBitmap = wx.NullBitmap,
3712 isToggle = 0,
3713 clientData = None,
3714 shortHelpString = '',
3715 longHelpString = ''):
3716 '''Old style method to insert a tool in the toolbar.'''
3717 kind = wx.ITEM_NORMAL
3718 if isToggle: kind = wx.ITEM_CHECK
3719 return self.DoInsertTool(pos, id, '', bitmap, pushedBitmap, kind,
3720 shortHelpString, longHelpString, clientData)
3721
3722 def InsertSimpleTool(self, pos, id, bitmap,
3723 shortHelpString = '',
3724 longHelpString = '',
3725 isToggle = 0):
3726 '''Old style method to insert a tool in the toolbar.'''
3727 kind = wx.ITEM_NORMAL
3728 if isToggle: kind = wx.ITEM_CHECK
3729 return self.DoInsertTool(pos, id, '', bitmap, wx.NullBitmap, kind,
3730 shortHelpString, longHelpString, None)
3731
3732
3733 # The following are the new toolbar Add methods starting with
3734 # 2.3.3. They are renamed to have 'Label' in the name so as to be
3735 # able to keep backwards compatibility with using the above
3736 # methods. Eventually these should migrate to be the methods used
3737 # primarily and lose the 'Label' in the name...
3738
3739 def AddLabelTool(self, id, label, bitmap,
3740 bmpDisabled = wx.NullBitmap,
3741 kind = wx.ITEM_NORMAL,
3742 shortHelp = '', longHelp = '',
3743 clientData = None):
3744 '''
3745 The full AddTool() function.
3746
3747 If bmpDisabled is wx.NullBitmap, a shadowed version of the normal bitmap
3748 is created and used as the disabled image.
3749 '''
3750 return self.DoAddTool(id, label, bitmap, bmpDisabled, kind,
3751 shortHelp, longHelp, clientData)
3752
3753
3754 def InsertLabelTool(self, pos, id, label, bitmap,
3755 bmpDisabled = wx.NullBitmap,
3756 kind = wx.ITEM_NORMAL,
3757 shortHelp = '', longHelp = '',
3758 clientData = None):
3759 '''
3760 Insert the new tool at the given position, if pos == GetToolsCount(), it
3761 is equivalent to AddTool()
3762 '''
3763 return self.DoInsertTool(pos, id, label, bitmap, bmpDisabled, kind,
3764 shortHelp, longHelp, clientData)
3765
3766 def AddCheckLabelTool(self, id, label, bitmap,
3767 bmpDisabled = wx.NullBitmap,
3768 shortHelp = '', longHelp = '',
3769 clientData = None):
3770 '''Add a check tool, i.e. a tool which can be toggled'''
3771 return self.DoAddTool(id, label, bitmap, bmpDisabled, wx.ITEM_CHECK,
3772 shortHelp, longHelp, clientData)
3773
3774 def AddRadioLabelTool(self, id, label, bitmap,
3775 bmpDisabled = wx.NullBitmap,
3776 shortHelp = '', longHelp = '',
3777 clientData = None):
3778 '''
3779 Add a radio tool, i.e. a tool which can be toggled and releases any
3780 other toggled radio tools in the same group when it happens
3781 '''
3782 return self.DoAddTool(id, label, bitmap, bmpDisabled, wx.ITEM_RADIO,
3783 shortHelp, longHelp, clientData)
3784
3785
3786 # For consistency with the backwards compatible methods above, here are
3787 # some non-'Label' versions of the Check and Radio methods
248ed943 3788
d14a1e28
RD
3789 def AddCheckTool(self, id, bitmap,
3790 bmpDisabled = wx.NullBitmap,
3791 shortHelp = '', longHelp = '',
3792 clientData = None):
3793 '''Add a check tool, i.e. a tool which can be toggled'''
3794 return self.DoAddTool(id, '', bitmap, bmpDisabled, wx.ITEM_CHECK,
3795 shortHelp, longHelp, clientData)
3796
3797 def AddRadioTool(self, id, bitmap,
3798 bmpDisabled = wx.NullBitmap,
3799 shortHelp = '', longHelp = '',
3800 clientData = None):
3801 '''
3802 Add a radio tool, i.e. a tool which can be toggled and releases any
3803 other toggled radio tools in the same group when it happens
3804 '''
3805 return self.DoAddTool(id, '', bitmap, bmpDisabled, wx.ITEM_RADIO,
3806 shortHelp, longHelp, clientData)
3807
3a04f143 3808 def AddToolItem(*args, **kwargs):
a95a7133 3809 """AddToolItem(self, ToolBarToolBase tool) -> ToolBarToolBase"""
54f9ee45 3810 return _controls_.ToolBarBase_AddToolItem(*args, **kwargs)
3a04f143
RD
3811
3812 def InsertToolItem(*args, **kwargs):
a95a7133 3813 """InsertToolItem(self, size_t pos, ToolBarToolBase tool) -> ToolBarToolBase"""
54f9ee45 3814 return _controls_.ToolBarBase_InsertToolItem(*args, **kwargs)
3a04f143 3815
e811c8ce 3816 def AddControl(*args, **kwargs):
a95a7133 3817 """AddControl(self, Control control) -> ToolBarToolBase"""
54f9ee45 3818 return _controls_.ToolBarBase_AddControl(*args, **kwargs)
e811c8ce
RD
3819
3820 def InsertControl(*args, **kwargs):
a95a7133 3821 """InsertControl(self, size_t pos, Control control) -> ToolBarToolBase"""
54f9ee45 3822 return _controls_.ToolBarBase_InsertControl(*args, **kwargs)
e811c8ce
RD
3823
3824 def FindControl(*args, **kwargs):
a95a7133 3825 """FindControl(self, int id) -> Control"""
54f9ee45 3826 return _controls_.ToolBarBase_FindControl(*args, **kwargs)
e811c8ce
RD
3827
3828 def AddSeparator(*args, **kwargs):
a95a7133 3829 """AddSeparator(self) -> ToolBarToolBase"""
54f9ee45 3830 return _controls_.ToolBarBase_AddSeparator(*args, **kwargs)
e811c8ce
RD
3831
3832 def InsertSeparator(*args, **kwargs):
a95a7133 3833 """InsertSeparator(self, size_t pos) -> ToolBarToolBase"""
54f9ee45 3834 return _controls_.ToolBarBase_InsertSeparator(*args, **kwargs)
e811c8ce
RD
3835
3836 def RemoveTool(*args, **kwargs):
a95a7133 3837 """RemoveTool(self, int id) -> ToolBarToolBase"""
54f9ee45 3838 return _controls_.ToolBarBase_RemoveTool(*args, **kwargs)
e811c8ce
RD
3839
3840 def DeleteToolByPos(*args, **kwargs):
a95a7133 3841 """DeleteToolByPos(self, size_t pos) -> bool"""
54f9ee45 3842 return _controls_.ToolBarBase_DeleteToolByPos(*args, **kwargs)
e811c8ce
RD
3843
3844 def DeleteTool(*args, **kwargs):
a95a7133 3845 """DeleteTool(self, int id) -> bool"""
54f9ee45 3846 return _controls_.ToolBarBase_DeleteTool(*args, **kwargs)
e811c8ce
RD
3847
3848 def ClearTools(*args, **kwargs):
a95a7133 3849 """ClearTools(self)"""
54f9ee45 3850 return _controls_.ToolBarBase_ClearTools(*args, **kwargs)
e811c8ce
RD
3851
3852 def Realize(*args, **kwargs):
a95a7133 3853 """Realize(self) -> bool"""
54f9ee45 3854 return _controls_.ToolBarBase_Realize(*args, **kwargs)
e811c8ce
RD
3855
3856 def EnableTool(*args, **kwargs):
a95a7133 3857 """EnableTool(self, int id, bool enable)"""
54f9ee45 3858 return _controls_.ToolBarBase_EnableTool(*args, **kwargs)
e811c8ce
RD
3859
3860 def ToggleTool(*args, **kwargs):
a95a7133 3861 """ToggleTool(self, int id, bool toggle)"""
54f9ee45 3862 return _controls_.ToolBarBase_ToggleTool(*args, **kwargs)
e811c8ce
RD
3863
3864 def SetToggle(*args, **kwargs):
a95a7133 3865 """SetToggle(self, int id, bool toggle)"""
54f9ee45 3866 return _controls_.ToolBarBase_SetToggle(*args, **kwargs)
e811c8ce
RD
3867
3868 def GetToolClientData(*args, **kwargs):
a95a7133 3869 """GetToolClientData(self, int id) -> PyObject"""
54f9ee45 3870 return _controls_.ToolBarBase_GetToolClientData(*args, **kwargs)
e811c8ce
RD
3871
3872 def SetToolClientData(*args, **kwargs):
a95a7133 3873 """SetToolClientData(self, int id, PyObject clientData)"""
54f9ee45 3874 return _controls_.ToolBarBase_SetToolClientData(*args, **kwargs)
e811c8ce
RD
3875
3876 def GetToolPos(*args, **kwargs):
a95a7133 3877 """GetToolPos(self, int id) -> int"""
54f9ee45 3878 return _controls_.ToolBarBase_GetToolPos(*args, **kwargs)
e811c8ce
RD
3879
3880 def GetToolState(*args, **kwargs):
a95a7133 3881 """GetToolState(self, int id) -> bool"""
54f9ee45 3882 return _controls_.ToolBarBase_GetToolState(*args, **kwargs)
e811c8ce
RD
3883
3884 def GetToolEnabled(*args, **kwargs):
a95a7133 3885 """GetToolEnabled(self, int id) -> bool"""
54f9ee45 3886 return _controls_.ToolBarBase_GetToolEnabled(*args, **kwargs)
e811c8ce
RD
3887
3888 def SetToolShortHelp(*args, **kwargs):
a95a7133 3889 """SetToolShortHelp(self, int id, String helpString)"""
54f9ee45 3890 return _controls_.ToolBarBase_SetToolShortHelp(*args, **kwargs)
e811c8ce
RD
3891
3892 def GetToolShortHelp(*args, **kwargs):
a95a7133 3893 """GetToolShortHelp(self, int id) -> String"""
54f9ee45 3894 return _controls_.ToolBarBase_GetToolShortHelp(*args, **kwargs)
e811c8ce
RD
3895
3896 def SetToolLongHelp(*args, **kwargs):
a95a7133 3897 """SetToolLongHelp(self, int id, String helpString)"""
54f9ee45 3898 return _controls_.ToolBarBase_SetToolLongHelp(*args, **kwargs)
e811c8ce
RD
3899
3900 def GetToolLongHelp(*args, **kwargs):
a95a7133 3901 """GetToolLongHelp(self, int id) -> String"""
54f9ee45 3902 return _controls_.ToolBarBase_GetToolLongHelp(*args, **kwargs)
e811c8ce
RD
3903
3904 def SetMarginsXY(*args, **kwargs):
a95a7133 3905 """SetMarginsXY(self, int x, int y)"""
54f9ee45 3906 return _controls_.ToolBarBase_SetMarginsXY(*args, **kwargs)
e811c8ce
RD
3907
3908 def SetMargins(*args, **kwargs):
a95a7133 3909 """SetMargins(self, Size size)"""
54f9ee45 3910 return _controls_.ToolBarBase_SetMargins(*args, **kwargs)
e811c8ce
RD
3911
3912 def SetToolPacking(*args, **kwargs):
a95a7133 3913 """SetToolPacking(self, int packing)"""
54f9ee45 3914 return _controls_.ToolBarBase_SetToolPacking(*args, **kwargs)
e811c8ce
RD
3915
3916 def SetToolSeparation(*args, **kwargs):
a95a7133 3917 """SetToolSeparation(self, int separation)"""
54f9ee45 3918 return _controls_.ToolBarBase_SetToolSeparation(*args, **kwargs)
e811c8ce
RD
3919
3920 def GetToolMargins(*args, **kwargs):
a95a7133 3921 """GetToolMargins(self) -> Size"""
54f9ee45 3922 return _controls_.ToolBarBase_GetToolMargins(*args, **kwargs)
e811c8ce
RD
3923
3924 def GetMargins(*args, **kwargs):
a95a7133 3925 """GetMargins(self) -> Size"""
54f9ee45 3926 return _controls_.ToolBarBase_GetMargins(*args, **kwargs)
e811c8ce
RD
3927
3928 def GetToolPacking(*args, **kwargs):
a95a7133 3929 """GetToolPacking(self) -> int"""
54f9ee45 3930 return _controls_.ToolBarBase_GetToolPacking(*args, **kwargs)
e811c8ce
RD
3931
3932 def GetToolSeparation(*args, **kwargs):
a95a7133 3933 """GetToolSeparation(self) -> int"""
54f9ee45 3934 return _controls_.ToolBarBase_GetToolSeparation(*args, **kwargs)
e811c8ce
RD
3935
3936 def SetRows(*args, **kwargs):
a95a7133 3937 """SetRows(self, int nRows)"""
54f9ee45 3938 return _controls_.ToolBarBase_SetRows(*args, **kwargs)
e811c8ce
RD
3939
3940 def SetMaxRowsCols(*args, **kwargs):
a95a7133 3941 """SetMaxRowsCols(self, int rows, int cols)"""
54f9ee45 3942 return _controls_.ToolBarBase_SetMaxRowsCols(*args, **kwargs)
e811c8ce
RD
3943
3944 def GetMaxRows(*args, **kwargs):
a95a7133 3945 """GetMaxRows(self) -> int"""
54f9ee45 3946 return _controls_.ToolBarBase_GetMaxRows(*args, **kwargs)
e811c8ce
RD
3947
3948 def GetMaxCols(*args, **kwargs):
a95a7133 3949 """GetMaxCols(self) -> int"""
54f9ee45 3950 return _controls_.ToolBarBase_GetMaxCols(*args, **kwargs)
e811c8ce
RD
3951
3952 def SetToolBitmapSize(*args, **kwargs):
a95a7133 3953 """SetToolBitmapSize(self, Size size)"""
54f9ee45 3954 return _controls_.ToolBarBase_SetToolBitmapSize(*args, **kwargs)
e811c8ce
RD
3955
3956 def GetToolBitmapSize(*args, **kwargs):
a95a7133 3957 """GetToolBitmapSize(self) -> Size"""
54f9ee45 3958 return _controls_.ToolBarBase_GetToolBitmapSize(*args, **kwargs)
e811c8ce
RD
3959
3960 def GetToolSize(*args, **kwargs):
a95a7133 3961 """GetToolSize(self) -> Size"""
54f9ee45 3962 return _controls_.ToolBarBase_GetToolSize(*args, **kwargs)
e811c8ce
RD
3963
3964 def FindToolForPosition(*args, **kwargs):
a95a7133 3965 """FindToolForPosition(self, int x, int y) -> ToolBarToolBase"""
54f9ee45 3966 return _controls_.ToolBarBase_FindToolForPosition(*args, **kwargs)
e811c8ce 3967
3a04f143 3968 def FindById(*args, **kwargs):
a95a7133 3969 """FindById(self, int toolid) -> ToolBarToolBase"""
54f9ee45 3970 return _controls_.ToolBarBase_FindById(*args, **kwargs)
3a04f143 3971
e811c8ce 3972 def IsVertical(*args, **kwargs):
a95a7133 3973 """IsVertical(self) -> bool"""
54f9ee45 3974 return _controls_.ToolBarBase_IsVertical(*args, **kwargs)
e811c8ce 3975
d14a1e28
RD
3976
3977class ToolBarBasePtr(ToolBarBase):
3978 def __init__(self, this):
3979 self.this = this
3980 if not hasattr(self,"thisown"): self.thisown = 0
3981 self.__class__ = ToolBarBase
54f9ee45 3982_controls_.ToolBarBase_swigregister(ToolBarBasePtr)
d14a1e28
RD
3983
3984class ToolBar(ToolBarBase):
093d3ff1 3985 """Proxy of C++ ToolBar class"""
e811c8ce
RD
3986 def __repr__(self):
3987 return "<%s.%s; proxy of C++ wxToolBar instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 3988 def __init__(self, *args, **kwargs):
0df68c9f 3989 """
248ed943
RD
3990 __init__(self, Window parent, int id=-1, Point pos=DefaultPosition,
3991 Size size=DefaultSize, long style=wxNO_BORDER|wxTB_HORIZONTAL,
196addbf 3992 String name=wxPyToolBarNameStr) -> ToolBar
0df68c9f 3993 """
54f9ee45 3994 newobj = _controls_.new_ToolBar(*args, **kwargs)
d14a1e28
RD
3995 self.this = newobj.this
3996 self.thisown = 1
3997 del newobj.thisown
3998 self._setOORInfo(self)
e811c8ce
RD
3999
4000 def Create(*args, **kwargs):
0df68c9f 4001 """
248ed943
RD
4002 Create(self, Window parent, int id=-1, Point pos=DefaultPosition,
4003 Size size=DefaultSize, long style=wxNO_BORDER|wxTB_HORIZONTAL,
196addbf 4004 String name=wxPyToolBarNameStr) -> bool
0df68c9f 4005 """
54f9ee45 4006 return _controls_.ToolBar_Create(*args, **kwargs)
e811c8ce
RD
4007
4008 def FindToolForPosition(*args, **kwargs):
a95a7133 4009 """FindToolForPosition(self, int x, int y) -> ToolBarToolBase"""
54f9ee45 4010 return _controls_.ToolBar_FindToolForPosition(*args, **kwargs)
e811c8ce 4011
22bfe96c 4012 def GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
4013 """
4014 GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
4015
4016 Get the default attributes for this class. This is useful if you want
4017 to use the same font or colour in your own control as in a standard
4018 control -- which is a much better idea than hard coding specific
4019 colours or fonts which might look completely out of place on the
4020 user's system, especially if it uses themes.
4021
4022 The variant parameter is only relevant under Mac currently and is
4023 ignore under other platforms. Under Mac, it will change the size of
4024 the returned font. See `wx.Window.SetWindowVariant` for more about
4025 this.
4026 """
22bfe96c
RD
4027 return _controls_.ToolBar_GetClassDefaultAttributes(*args, **kwargs)
4028
4029 GetClassDefaultAttributes = staticmethod(GetClassDefaultAttributes)
70551f47 4030
d14a1e28
RD
4031class ToolBarPtr(ToolBar):
4032 def __init__(self, this):
4033 self.this = this
4034 if not hasattr(self,"thisown"): self.thisown = 0
4035 self.__class__ = ToolBar
54f9ee45 4036_controls_.ToolBar_swigregister(ToolBarPtr)
70551f47 4037
d14a1e28 4038def PreToolBar(*args, **kwargs):
e811c8ce 4039 """PreToolBar() -> ToolBar"""
54f9ee45 4040 val = _controls_.new_PreToolBar(*args, **kwargs)
aa2a5b86
RD
4041 val.thisown = 1
4042 return val
4043
22bfe96c 4044def ToolBar_GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
4045 """
4046 ToolBar_GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
4047
4048 Get the default attributes for this class. This is useful if you want
4049 to use the same font or colour in your own control as in a standard
4050 control -- which is a much better idea than hard coding specific
4051 colours or fonts which might look completely out of place on the
4052 user's system, especially if it uses themes.
4053
4054 The variant parameter is only relevant under Mac currently and is
4055 ignore under other platforms. Under Mac, it will change the size of
4056 the returned font. See `wx.Window.SetWindowVariant` for more about
4057 this.
4058 """
22bfe96c
RD
4059 return _controls_.ToolBar_GetClassDefaultAttributes(*args, **kwargs)
4060
d14a1e28
RD
4061#---------------------------------------------------------------------------
4062
54f9ee45
RD
4063LC_VRULES = _controls_.LC_VRULES
4064LC_HRULES = _controls_.LC_HRULES
4065LC_ICON = _controls_.LC_ICON
4066LC_SMALL_ICON = _controls_.LC_SMALL_ICON
4067LC_LIST = _controls_.LC_LIST
4068LC_REPORT = _controls_.LC_REPORT
4069LC_ALIGN_TOP = _controls_.LC_ALIGN_TOP
4070LC_ALIGN_LEFT = _controls_.LC_ALIGN_LEFT
4071LC_AUTOARRANGE = _controls_.LC_AUTOARRANGE
4072LC_VIRTUAL = _controls_.LC_VIRTUAL
4073LC_EDIT_LABELS = _controls_.LC_EDIT_LABELS
4074LC_NO_HEADER = _controls_.LC_NO_HEADER
4075LC_NO_SORT_HEADER = _controls_.LC_NO_SORT_HEADER
4076LC_SINGLE_SEL = _controls_.LC_SINGLE_SEL
4077LC_SORT_ASCENDING = _controls_.LC_SORT_ASCENDING
4078LC_SORT_DESCENDING = _controls_.LC_SORT_DESCENDING
4079LC_MASK_TYPE = _controls_.LC_MASK_TYPE
4080LC_MASK_ALIGN = _controls_.LC_MASK_ALIGN
4081LC_MASK_SORT = _controls_.LC_MASK_SORT
4082LIST_MASK_STATE = _controls_.LIST_MASK_STATE
4083LIST_MASK_TEXT = _controls_.LIST_MASK_TEXT
4084LIST_MASK_IMAGE = _controls_.LIST_MASK_IMAGE
4085LIST_MASK_DATA = _controls_.LIST_MASK_DATA
4086LIST_SET_ITEM = _controls_.LIST_SET_ITEM
4087LIST_MASK_WIDTH = _controls_.LIST_MASK_WIDTH
4088LIST_MASK_FORMAT = _controls_.LIST_MASK_FORMAT
4089LIST_STATE_DONTCARE = _controls_.LIST_STATE_DONTCARE
4090LIST_STATE_DROPHILITED = _controls_.LIST_STATE_DROPHILITED
4091LIST_STATE_FOCUSED = _controls_.LIST_STATE_FOCUSED
4092LIST_STATE_SELECTED = _controls_.LIST_STATE_SELECTED
4093LIST_STATE_CUT = _controls_.LIST_STATE_CUT
4094LIST_STATE_DISABLED = _controls_.LIST_STATE_DISABLED
4095LIST_STATE_FILTERED = _controls_.LIST_STATE_FILTERED
4096LIST_STATE_INUSE = _controls_.LIST_STATE_INUSE
4097LIST_STATE_PICKED = _controls_.LIST_STATE_PICKED
4098LIST_STATE_SOURCE = _controls_.LIST_STATE_SOURCE
4099LIST_HITTEST_ABOVE = _controls_.LIST_HITTEST_ABOVE
4100LIST_HITTEST_BELOW = _controls_.LIST_HITTEST_BELOW
4101LIST_HITTEST_NOWHERE = _controls_.LIST_HITTEST_NOWHERE
4102LIST_HITTEST_ONITEMICON = _controls_.LIST_HITTEST_ONITEMICON
4103LIST_HITTEST_ONITEMLABEL = _controls_.LIST_HITTEST_ONITEMLABEL
4104LIST_HITTEST_ONITEMRIGHT = _controls_.LIST_HITTEST_ONITEMRIGHT
4105LIST_HITTEST_ONITEMSTATEICON = _controls_.LIST_HITTEST_ONITEMSTATEICON
4106LIST_HITTEST_TOLEFT = _controls_.LIST_HITTEST_TOLEFT
4107LIST_HITTEST_TORIGHT = _controls_.LIST_HITTEST_TORIGHT
4108LIST_HITTEST_ONITEM = _controls_.LIST_HITTEST_ONITEM
4109LIST_NEXT_ABOVE = _controls_.LIST_NEXT_ABOVE
4110LIST_NEXT_ALL = _controls_.LIST_NEXT_ALL
4111LIST_NEXT_BELOW = _controls_.LIST_NEXT_BELOW
4112LIST_NEXT_LEFT = _controls_.LIST_NEXT_LEFT
4113LIST_NEXT_RIGHT = _controls_.LIST_NEXT_RIGHT
4114LIST_ALIGN_DEFAULT = _controls_.LIST_ALIGN_DEFAULT
4115LIST_ALIGN_LEFT = _controls_.LIST_ALIGN_LEFT
4116LIST_ALIGN_TOP = _controls_.LIST_ALIGN_TOP
4117LIST_ALIGN_SNAP_TO_GRID = _controls_.LIST_ALIGN_SNAP_TO_GRID
4118LIST_FORMAT_LEFT = _controls_.LIST_FORMAT_LEFT
4119LIST_FORMAT_RIGHT = _controls_.LIST_FORMAT_RIGHT
4120LIST_FORMAT_CENTRE = _controls_.LIST_FORMAT_CENTRE
4121LIST_FORMAT_CENTER = _controls_.LIST_FORMAT_CENTER
4122LIST_AUTOSIZE = _controls_.LIST_AUTOSIZE
4123LIST_AUTOSIZE_USEHEADER = _controls_.LIST_AUTOSIZE_USEHEADER
4124LIST_RECT_BOUNDS = _controls_.LIST_RECT_BOUNDS
4125LIST_RECT_ICON = _controls_.LIST_RECT_ICON
4126LIST_RECT_LABEL = _controls_.LIST_RECT_LABEL
4127LIST_FIND_UP = _controls_.LIST_FIND_UP
4128LIST_FIND_DOWN = _controls_.LIST_FIND_DOWN
4129LIST_FIND_LEFT = _controls_.LIST_FIND_LEFT
4130LIST_FIND_RIGHT = _controls_.LIST_FIND_RIGHT
d14a1e28
RD
4131#---------------------------------------------------------------------------
4132
4133class ListItemAttr(object):
093d3ff1 4134 """Proxy of C++ ListItemAttr class"""
e811c8ce
RD
4135 def __repr__(self):
4136 return "<%s.%s; proxy of C++ wxListItemAttr instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 4137 def __init__(self, *args, **kwargs):
0df68c9f 4138 """
a95a7133 4139 __init__(self, Colour colText=wxNullColour, Colour colBack=wxNullColour,
196addbf 4140 Font font=wxNullFont) -> ListItemAttr
0df68c9f 4141 """
54f9ee45 4142 newobj = _controls_.new_ListItemAttr(*args, **kwargs)
d14a1e28
RD
4143 self.this = newobj.this
4144 self.thisown = 1
4145 del newobj.thisown
e811c8ce 4146 def SetTextColour(*args, **kwargs):
a95a7133 4147 """SetTextColour(self, Colour colText)"""
54f9ee45 4148 return _controls_.ListItemAttr_SetTextColour(*args, **kwargs)
e811c8ce
RD
4149
4150 def SetBackgroundColour(*args, **kwargs):
a95a7133 4151 """SetBackgroundColour(self, Colour colBack)"""
54f9ee45 4152 return _controls_.ListItemAttr_SetBackgroundColour(*args, **kwargs)
e811c8ce
RD
4153
4154 def SetFont(*args, **kwargs):
a95a7133 4155 """SetFont(self, Font font)"""
54f9ee45 4156 return _controls_.ListItemAttr_SetFont(*args, **kwargs)
e811c8ce
RD
4157
4158 def HasTextColour(*args, **kwargs):
a95a7133 4159 """HasTextColour(self) -> bool"""
54f9ee45 4160 return _controls_.ListItemAttr_HasTextColour(*args, **kwargs)
e811c8ce
RD
4161
4162 def HasBackgroundColour(*args, **kwargs):
a95a7133 4163 """HasBackgroundColour(self) -> bool"""
54f9ee45 4164 return _controls_.ListItemAttr_HasBackgroundColour(*args, **kwargs)
e811c8ce
RD
4165
4166 def HasFont(*args, **kwargs):
a95a7133 4167 """HasFont(self) -> bool"""
54f9ee45 4168 return _controls_.ListItemAttr_HasFont(*args, **kwargs)
e811c8ce
RD
4169
4170 def GetTextColour(*args, **kwargs):
a95a7133 4171 """GetTextColour(self) -> Colour"""
54f9ee45 4172 return _controls_.ListItemAttr_GetTextColour(*args, **kwargs)
e811c8ce
RD
4173
4174 def GetBackgroundColour(*args, **kwargs):
a95a7133 4175 """GetBackgroundColour(self) -> Colour"""
54f9ee45 4176 return _controls_.ListItemAttr_GetBackgroundColour(*args, **kwargs)
e811c8ce
RD
4177
4178 def GetFont(*args, **kwargs):
a95a7133 4179 """GetFont(self) -> Font"""
54f9ee45 4180 return _controls_.ListItemAttr_GetFont(*args, **kwargs)
e811c8ce
RD
4181
4182 def Destroy(*args, **kwargs):
a95a7133 4183 """Destroy(self)"""
54f9ee45 4184 return _controls_.ListItemAttr_Destroy(*args, **kwargs)
e811c8ce 4185
70551f47 4186
d14a1e28
RD
4187class ListItemAttrPtr(ListItemAttr):
4188 def __init__(self, this):
70551f47 4189 self.this = this
d14a1e28
RD
4190 if not hasattr(self,"thisown"): self.thisown = 0
4191 self.__class__ = ListItemAttr
54f9ee45 4192_controls_.ListItemAttr_swigregister(ListItemAttrPtr)
b2dc1044 4193ListCtrlNameStr = cvar.ListCtrlNameStr
d14a1e28
RD
4194
4195#---------------------------------------------------------------------------
4196
54f9ee45 4197class ListItem(_core.Object):
093d3ff1 4198 """Proxy of C++ ListItem class"""
e811c8ce
RD
4199 def __repr__(self):
4200 return "<%s.%s; proxy of C++ wxListItem instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 4201 def __init__(self, *args, **kwargs):
a95a7133 4202 """__init__(self) -> ListItem"""
54f9ee45 4203 newobj = _controls_.new_ListItem(*args, **kwargs)
d14a1e28
RD
4204 self.this = newobj.this
4205 self.thisown = 1
4206 del newobj.thisown
54f9ee45 4207 def __del__(self, destroy=_controls_.delete_ListItem):
a95a7133 4208 """__del__(self)"""
d14a1e28
RD
4209 try:
4210 if self.thisown: destroy(self)
4211 except: pass
e811c8ce
RD
4212
4213 def Clear(*args, **kwargs):
a95a7133 4214 """Clear(self)"""
54f9ee45 4215 return _controls_.ListItem_Clear(*args, **kwargs)
e811c8ce
RD
4216
4217 def ClearAttributes(*args, **kwargs):
a95a7133 4218 """ClearAttributes(self)"""
54f9ee45 4219 return _controls_.ListItem_ClearAttributes(*args, **kwargs)
e811c8ce
RD
4220
4221 def SetMask(*args, **kwargs):
a95a7133 4222 """SetMask(self, long mask)"""
54f9ee45 4223 return _controls_.ListItem_SetMask(*args, **kwargs)
e811c8ce
RD
4224
4225 def SetId(*args, **kwargs):
a95a7133 4226 """SetId(self, long id)"""
54f9ee45 4227 return _controls_.ListItem_SetId(*args, **kwargs)
e811c8ce
RD
4228
4229 def SetColumn(*args, **kwargs):
a95a7133 4230 """SetColumn(self, int col)"""
54f9ee45 4231 return _controls_.ListItem_SetColumn(*args, **kwargs)
e811c8ce
RD
4232
4233 def SetState(*args, **kwargs):
a95a7133 4234 """SetState(self, long state)"""
54f9ee45 4235 return _controls_.ListItem_SetState(*args, **kwargs)
e811c8ce
RD
4236
4237 def SetStateMask(*args, **kwargs):
a95a7133 4238 """SetStateMask(self, long stateMask)"""
54f9ee45 4239 return _controls_.ListItem_SetStateMask(*args, **kwargs)
e811c8ce
RD
4240
4241 def SetText(*args, **kwargs):
a95a7133 4242 """SetText(self, String text)"""
54f9ee45 4243 return _controls_.ListItem_SetText(*args, **kwargs)
e811c8ce
RD
4244
4245 def SetImage(*args, **kwargs):
a95a7133 4246 """SetImage(self, int image)"""
54f9ee45 4247 return _controls_.ListItem_SetImage(*args, **kwargs)
e811c8ce
RD
4248
4249 def SetData(*args, **kwargs):
a95a7133 4250 """SetData(self, long data)"""
54f9ee45 4251 return _controls_.ListItem_SetData(*args, **kwargs)
e811c8ce
RD
4252
4253 def SetWidth(*args, **kwargs):
a95a7133 4254 """SetWidth(self, int width)"""
54f9ee45 4255 return _controls_.ListItem_SetWidth(*args, **kwargs)
e811c8ce
RD
4256
4257 def SetAlign(*args, **kwargs):
a95a7133 4258 """SetAlign(self, int align)"""
54f9ee45 4259 return _controls_.ListItem_SetAlign(*args, **kwargs)
e811c8ce
RD
4260
4261 def SetTextColour(*args, **kwargs):
a95a7133 4262 """SetTextColour(self, Colour colText)"""
54f9ee45 4263 return _controls_.ListItem_SetTextColour(*args, **kwargs)
e811c8ce
RD
4264
4265 def SetBackgroundColour(*args, **kwargs):
a95a7133 4266 """SetBackgroundColour(self, Colour colBack)"""
54f9ee45 4267 return _controls_.ListItem_SetBackgroundColour(*args, **kwargs)
e811c8ce
RD
4268
4269 def SetFont(*args, **kwargs):
a95a7133 4270 """SetFont(self, Font font)"""
54f9ee45 4271 return _controls_.ListItem_SetFont(*args, **kwargs)
e811c8ce
RD
4272
4273 def GetMask(*args, **kwargs):
a95a7133 4274 """GetMask(self) -> long"""
54f9ee45 4275 return _controls_.ListItem_GetMask(*args, **kwargs)
e811c8ce
RD
4276
4277 def GetId(*args, **kwargs):
a95a7133 4278 """GetId(self) -> long"""
54f9ee45 4279 return _controls_.ListItem_GetId(*args, **kwargs)
e811c8ce
RD
4280
4281 def GetColumn(*args, **kwargs):
a95a7133 4282 """GetColumn(self) -> int"""
54f9ee45 4283 return _controls_.ListItem_GetColumn(*args, **kwargs)
e811c8ce
RD
4284
4285 def GetState(*args, **kwargs):
a95a7133 4286 """GetState(self) -> long"""
54f9ee45 4287 return _controls_.ListItem_GetState(*args, **kwargs)
e811c8ce
RD
4288
4289 def GetText(*args, **kwargs):
a95a7133 4290 """GetText(self) -> String"""
54f9ee45 4291 return _controls_.ListItem_GetText(*args, **kwargs)
e811c8ce
RD
4292
4293 def GetImage(*args, **kwargs):
a95a7133 4294 """GetImage(self) -> int"""
54f9ee45 4295 return _controls_.ListItem_GetImage(*args, **kwargs)
e811c8ce
RD
4296
4297 def GetData(*args, **kwargs):
a95a7133 4298 """GetData(self) -> long"""
54f9ee45 4299 return _controls_.ListItem_GetData(*args, **kwargs)
e811c8ce
RD
4300
4301 def GetWidth(*args, **kwargs):
a95a7133 4302 """GetWidth(self) -> int"""
54f9ee45 4303 return _controls_.ListItem_GetWidth(*args, **kwargs)
e811c8ce
RD
4304
4305 def GetAlign(*args, **kwargs):
a95a7133 4306 """GetAlign(self) -> int"""
54f9ee45 4307 return _controls_.ListItem_GetAlign(*args, **kwargs)
e811c8ce
RD
4308
4309 def GetAttributes(*args, **kwargs):
a95a7133 4310 """GetAttributes(self) -> ListItemAttr"""
54f9ee45 4311 return _controls_.ListItem_GetAttributes(*args, **kwargs)
e811c8ce
RD
4312
4313 def HasAttributes(*args, **kwargs):
a95a7133 4314 """HasAttributes(self) -> bool"""
54f9ee45 4315 return _controls_.ListItem_HasAttributes(*args, **kwargs)
e811c8ce
RD
4316
4317 def GetTextColour(*args, **kwargs):
a95a7133 4318 """GetTextColour(self) -> Colour"""
54f9ee45 4319 return _controls_.ListItem_GetTextColour(*args, **kwargs)
e811c8ce
RD
4320
4321 def GetBackgroundColour(*args, **kwargs):
a95a7133 4322 """GetBackgroundColour(self) -> Colour"""
54f9ee45 4323 return _controls_.ListItem_GetBackgroundColour(*args, **kwargs)
e811c8ce
RD
4324
4325 def GetFont(*args, **kwargs):
a95a7133 4326 """GetFont(self) -> Font"""
54f9ee45
RD
4327 return _controls_.ListItem_GetFont(*args, **kwargs)
4328
4329 m_mask = property(_controls_.ListItem_m_mask_get, _controls_.ListItem_m_mask_set)
4330 m_itemId = property(_controls_.ListItem_m_itemId_get, _controls_.ListItem_m_itemId_set)
4331 m_col = property(_controls_.ListItem_m_col_get, _controls_.ListItem_m_col_set)
4332 m_state = property(_controls_.ListItem_m_state_get, _controls_.ListItem_m_state_set)
4333 m_stateMask = property(_controls_.ListItem_m_stateMask_get, _controls_.ListItem_m_stateMask_set)
4334 m_text = property(_controls_.ListItem_m_text_get, _controls_.ListItem_m_text_set)
4335 m_image = property(_controls_.ListItem_m_image_get, _controls_.ListItem_m_image_set)
4336 m_data = property(_controls_.ListItem_m_data_get, _controls_.ListItem_m_data_set)
4337 m_format = property(_controls_.ListItem_m_format_get, _controls_.ListItem_m_format_set)
4338 m_width = property(_controls_.ListItem_m_width_get, _controls_.ListItem_m_width_set)
d14a1e28
RD
4339
4340class ListItemPtr(ListItem):
4341 def __init__(self, this):
4342 self.this = this
4343 if not hasattr(self,"thisown"): self.thisown = 0
4344 self.__class__ = ListItem
54f9ee45 4345_controls_.ListItem_swigregister(ListItemPtr)
d14a1e28
RD
4346
4347#---------------------------------------------------------------------------
4348
54f9ee45 4349class ListEvent(_core.NotifyEvent):
093d3ff1 4350 """Proxy of C++ ListEvent class"""
e811c8ce
RD
4351 def __repr__(self):
4352 return "<%s.%s; proxy of C++ wxListEvent instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 4353 def __init__(self, *args, **kwargs):
a95a7133 4354 """__init__(self, wxEventType commandType=wxEVT_NULL, int id=0) -> ListEvent"""
54f9ee45 4355 newobj = _controls_.new_ListEvent(*args, **kwargs)
d14a1e28 4356 self.this = newobj.this
70551f47 4357 self.thisown = 1
d14a1e28 4358 del newobj.thisown
54f9ee45
RD
4359 m_code = property(_controls_.ListEvent_m_code_get, _controls_.ListEvent_m_code_set)
4360 m_oldItemIndex = property(_controls_.ListEvent_m_oldItemIndex_get, _controls_.ListEvent_m_oldItemIndex_set)
4361 m_itemIndex = property(_controls_.ListEvent_m_itemIndex_get, _controls_.ListEvent_m_itemIndex_set)
4362 m_col = property(_controls_.ListEvent_m_col_get, _controls_.ListEvent_m_col_set)
4363 m_pointDrag = property(_controls_.ListEvent_m_pointDrag_get, _controls_.ListEvent_m_pointDrag_set)
4364 m_item = property(_controls_.ListEvent_m_item_get)
e811c8ce 4365 def GetKeyCode(*args, **kwargs):
a95a7133 4366 """GetKeyCode(self) -> int"""
54f9ee45 4367 return _controls_.ListEvent_GetKeyCode(*args, **kwargs)
e811c8ce 4368
d14a1e28 4369 GetCode = GetKeyCode
e811c8ce 4370 def GetIndex(*args, **kwargs):
a95a7133 4371 """GetIndex(self) -> long"""
54f9ee45 4372 return _controls_.ListEvent_GetIndex(*args, **kwargs)
e811c8ce
RD
4373
4374 def GetColumn(*args, **kwargs):
a95a7133 4375 """GetColumn(self) -> int"""
54f9ee45 4376 return _controls_.ListEvent_GetColumn(*args, **kwargs)
e811c8ce
RD
4377
4378 def GetPoint(*args, **kwargs):
a95a7133 4379 """GetPoint(self) -> Point"""
54f9ee45 4380 return _controls_.ListEvent_GetPoint(*args, **kwargs)
e811c8ce 4381
c9c7117a 4382 GetPosition = GetPoint
e811c8ce 4383 def GetLabel(*args, **kwargs):
a95a7133 4384 """GetLabel(self) -> String"""
54f9ee45 4385 return _controls_.ListEvent_GetLabel(*args, **kwargs)
e811c8ce
RD
4386
4387 def GetText(*args, **kwargs):
a95a7133 4388 """GetText(self) -> String"""
54f9ee45 4389 return _controls_.ListEvent_GetText(*args, **kwargs)
e811c8ce
RD
4390
4391 def GetImage(*args, **kwargs):
a95a7133 4392 """GetImage(self) -> int"""
54f9ee45 4393 return _controls_.ListEvent_GetImage(*args, **kwargs)
e811c8ce
RD
4394
4395 def GetData(*args, **kwargs):
a95a7133 4396 """GetData(self) -> long"""
54f9ee45 4397 return _controls_.ListEvent_GetData(*args, **kwargs)
e811c8ce
RD
4398
4399 def GetMask(*args, **kwargs):
a95a7133 4400 """GetMask(self) -> long"""
54f9ee45 4401 return _controls_.ListEvent_GetMask(*args, **kwargs)
e811c8ce
RD
4402
4403 def GetItem(*args, **kwargs):
a95a7133 4404 """GetItem(self) -> ListItem"""
54f9ee45 4405 return _controls_.ListEvent_GetItem(*args, **kwargs)
e811c8ce
RD
4406
4407 def GetCacheFrom(*args, **kwargs):
a95a7133 4408 """GetCacheFrom(self) -> long"""
54f9ee45 4409 return _controls_.ListEvent_GetCacheFrom(*args, **kwargs)
e811c8ce
RD
4410
4411 def GetCacheTo(*args, **kwargs):
a95a7133 4412 """GetCacheTo(self) -> long"""
54f9ee45 4413 return _controls_.ListEvent_GetCacheTo(*args, **kwargs)
e811c8ce
RD
4414
4415 def IsEditCancelled(*args, **kwargs):
a95a7133 4416 """IsEditCancelled(self) -> bool"""
54f9ee45 4417 return _controls_.ListEvent_IsEditCancelled(*args, **kwargs)
e811c8ce
RD
4418
4419 def SetEditCanceled(*args, **kwargs):
a95a7133 4420 """SetEditCanceled(self, bool editCancelled)"""
54f9ee45 4421 return _controls_.ListEvent_SetEditCanceled(*args, **kwargs)
e811c8ce 4422
70551f47 4423
d14a1e28
RD
4424class ListEventPtr(ListEvent):
4425 def __init__(self, this):
4426 self.this = this
4427 if not hasattr(self,"thisown"): self.thisown = 0
4428 self.__class__ = ListEvent
54f9ee45
RD
4429_controls_.ListEvent_swigregister(ListEventPtr)
4430
4431wxEVT_COMMAND_LIST_BEGIN_DRAG = _controls_.wxEVT_COMMAND_LIST_BEGIN_DRAG
4432wxEVT_COMMAND_LIST_BEGIN_RDRAG = _controls_.wxEVT_COMMAND_LIST_BEGIN_RDRAG
4433wxEVT_COMMAND_LIST_BEGIN_LABEL_EDIT = _controls_.wxEVT_COMMAND_LIST_BEGIN_LABEL_EDIT
4434wxEVT_COMMAND_LIST_END_LABEL_EDIT = _controls_.wxEVT_COMMAND_LIST_END_LABEL_EDIT
4435wxEVT_COMMAND_LIST_DELETE_ITEM = _controls_.wxEVT_COMMAND_LIST_DELETE_ITEM
4436wxEVT_COMMAND_LIST_DELETE_ALL_ITEMS = _controls_.wxEVT_COMMAND_LIST_DELETE_ALL_ITEMS
54f9ee45
RD
4437wxEVT_COMMAND_LIST_ITEM_SELECTED = _controls_.wxEVT_COMMAND_LIST_ITEM_SELECTED
4438wxEVT_COMMAND_LIST_ITEM_DESELECTED = _controls_.wxEVT_COMMAND_LIST_ITEM_DESELECTED
4439wxEVT_COMMAND_LIST_KEY_DOWN = _controls_.wxEVT_COMMAND_LIST_KEY_DOWN
4440wxEVT_COMMAND_LIST_INSERT_ITEM = _controls_.wxEVT_COMMAND_LIST_INSERT_ITEM
4441wxEVT_COMMAND_LIST_COL_CLICK = _controls_.wxEVT_COMMAND_LIST_COL_CLICK
4442wxEVT_COMMAND_LIST_ITEM_RIGHT_CLICK = _controls_.wxEVT_COMMAND_LIST_ITEM_RIGHT_CLICK
4443wxEVT_COMMAND_LIST_ITEM_MIDDLE_CLICK = _controls_.wxEVT_COMMAND_LIST_ITEM_MIDDLE_CLICK
4444wxEVT_COMMAND_LIST_ITEM_ACTIVATED = _controls_.wxEVT_COMMAND_LIST_ITEM_ACTIVATED
4445wxEVT_COMMAND_LIST_CACHE_HINT = _controls_.wxEVT_COMMAND_LIST_CACHE_HINT
4446wxEVT_COMMAND_LIST_COL_RIGHT_CLICK = _controls_.wxEVT_COMMAND_LIST_COL_RIGHT_CLICK
4447wxEVT_COMMAND_LIST_COL_BEGIN_DRAG = _controls_.wxEVT_COMMAND_LIST_COL_BEGIN_DRAG
4448wxEVT_COMMAND_LIST_COL_DRAGGING = _controls_.wxEVT_COMMAND_LIST_COL_DRAGGING
4449wxEVT_COMMAND_LIST_COL_END_DRAG = _controls_.wxEVT_COMMAND_LIST_COL_END_DRAG
4450wxEVT_COMMAND_LIST_ITEM_FOCUSED = _controls_.wxEVT_COMMAND_LIST_ITEM_FOCUSED
7557b9b5
RD
4451wxEVT_COMMAND_LIST_GET_INFO = _controls_.wxEVT_COMMAND_LIST_GET_INFO
4452wxEVT_COMMAND_LIST_SET_INFO = _controls_.wxEVT_COMMAND_LIST_SET_INFO
d14a1e28
RD
4453EVT_LIST_BEGIN_DRAG = wx.PyEventBinder(wxEVT_COMMAND_LIST_BEGIN_DRAG , 1)
4454EVT_LIST_BEGIN_RDRAG = wx.PyEventBinder(wxEVT_COMMAND_LIST_BEGIN_RDRAG , 1)
4455EVT_LIST_BEGIN_LABEL_EDIT = wx.PyEventBinder(wxEVT_COMMAND_LIST_BEGIN_LABEL_EDIT , 1)
4456EVT_LIST_END_LABEL_EDIT = wx.PyEventBinder(wxEVT_COMMAND_LIST_END_LABEL_EDIT , 1)
4457EVT_LIST_DELETE_ITEM = wx.PyEventBinder(wxEVT_COMMAND_LIST_DELETE_ITEM , 1)
4458EVT_LIST_DELETE_ALL_ITEMS = wx.PyEventBinder(wxEVT_COMMAND_LIST_DELETE_ALL_ITEMS , 1)
4459EVT_LIST_GET_INFO = wx.PyEventBinder(wxEVT_COMMAND_LIST_GET_INFO , 1)
4460EVT_LIST_SET_INFO = wx.PyEventBinder(wxEVT_COMMAND_LIST_SET_INFO , 1)
4461EVT_LIST_ITEM_SELECTED = wx.PyEventBinder(wxEVT_COMMAND_LIST_ITEM_SELECTED , 1)
4462EVT_LIST_ITEM_DESELECTED = wx.PyEventBinder(wxEVT_COMMAND_LIST_ITEM_DESELECTED , 1)
4463EVT_LIST_KEY_DOWN = wx.PyEventBinder(wxEVT_COMMAND_LIST_KEY_DOWN , 1)
4464EVT_LIST_INSERT_ITEM = wx.PyEventBinder(wxEVT_COMMAND_LIST_INSERT_ITEM , 1)
4465EVT_LIST_COL_CLICK = wx.PyEventBinder(wxEVT_COMMAND_LIST_COL_CLICK , 1)
4466EVT_LIST_ITEM_RIGHT_CLICK = wx.PyEventBinder(wxEVT_COMMAND_LIST_ITEM_RIGHT_CLICK , 1)
4467EVT_LIST_ITEM_MIDDLE_CLICK = wx.PyEventBinder(wxEVT_COMMAND_LIST_ITEM_MIDDLE_CLICK, 1)
4468EVT_LIST_ITEM_ACTIVATED = wx.PyEventBinder(wxEVT_COMMAND_LIST_ITEM_ACTIVATED , 1)
4469EVT_LIST_CACHE_HINT = wx.PyEventBinder(wxEVT_COMMAND_LIST_CACHE_HINT , 1)
4470EVT_LIST_COL_RIGHT_CLICK = wx.PyEventBinder(wxEVT_COMMAND_LIST_COL_RIGHT_CLICK , 1)
4471EVT_LIST_COL_BEGIN_DRAG = wx.PyEventBinder(wxEVT_COMMAND_LIST_COL_BEGIN_DRAG , 1)
4472EVT_LIST_COL_DRAGGING = wx.PyEventBinder(wxEVT_COMMAND_LIST_COL_DRAGGING , 1)
4473EVT_LIST_COL_END_DRAG = wx.PyEventBinder(wxEVT_COMMAND_LIST_COL_END_DRAG , 1)
4474EVT_LIST_ITEM_FOCUSED = wx.PyEventBinder(wxEVT_COMMAND_LIST_ITEM_FOCUSED , 1)
4475
1fc3b23a
RD
4476EVT_LIST_GET_INFO = wx._deprecated(EVT_LIST_GET_INFO)
4477EVT_LIST_SET_INFO = wx._deprecated(EVT_LIST_SET_INFO)
4478
d14a1e28
RD
4479#---------------------------------------------------------------------------
4480
54f9ee45 4481class ListCtrl(_core.Control):
093d3ff1 4482 """Proxy of C++ ListCtrl class"""
e811c8ce
RD
4483 def __repr__(self):
4484 return "<%s.%s; proxy of C++ wxPyListCtrl instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 4485 def __init__(self, *args, **kwargs):
0df68c9f 4486 """
a95a7133 4487 __init__(self, Window parent, int id=-1, Point pos=DefaultPosition,
0df68c9f 4488 Size size=DefaultSize, long style=LC_ICON,
b2dc1044 4489 Validator validator=DefaultValidator, String name=ListCtrlNameStr) -> ListCtrl
0df68c9f 4490 """
54f9ee45 4491 newobj = _controls_.new_ListCtrl(*args, **kwargs)
d14a1e28
RD
4492 self.this = newobj.this
4493 self.thisown = 1
4494 del newobj.thisown
4495 self._setOORInfo(self);self._setCallbackInfo(self, ListCtrl)
e811c8ce
RD
4496
4497 def Create(*args, **kwargs):
0df68c9f 4498 """
a95a7133 4499 Create(self, Window parent, int id=-1, Point pos=DefaultPosition,
0df68c9f 4500 Size size=DefaultSize, long style=LC_ICON,
b2dc1044 4501 Validator validator=DefaultValidator, String name=ListCtrlNameStr) -> bool
15afbcd0
RD
4502
4503 Do the 2nd phase and create the GUI control.
0df68c9f 4504 """
54f9ee45 4505 return _controls_.ListCtrl_Create(*args, **kwargs)
e811c8ce
RD
4506
4507 def _setCallbackInfo(*args, **kwargs):
a95a7133 4508 """_setCallbackInfo(self, PyObject self, PyObject _class)"""
54f9ee45 4509 return _controls_.ListCtrl__setCallbackInfo(*args, **kwargs)
e811c8ce
RD
4510
4511 def SetForegroundColour(*args, **kwargs):
093d3ff1
RD
4512 """
4513 SetForegroundColour(self, Colour col) -> bool
4514
4515 Sets the foreground colour of the window. Returns True is the colour
4516 was changed. The interpretation of foreground colour is dependent on
4517 the window class; it may be the text colour or other colour, or it may
4518 not be used at all.
4519 """
54f9ee45 4520 return _controls_.ListCtrl_SetForegroundColour(*args, **kwargs)
e811c8ce
RD
4521
4522 def SetBackgroundColour(*args, **kwargs):
093d3ff1
RD
4523 """
4524 SetBackgroundColour(self, Colour col) -> bool
4525
4526 Sets the background colour of the window. Returns True if the colour
4527 was changed. The background colour is usually painted by the default
4528 EVT_ERASE_BACKGROUND event handler function under Windows and
4529 automatically under GTK. Using `wx.NullColour` will reset the window
4530 to the default background colour.
4531
4532 Note that setting the background colour may not cause an immediate
4533 refresh, so you may wish to call `ClearBackground` or `Refresh` after
4534 calling this function.
4535
4536 Using this function will disable attempts to use themes for this
4537 window, if the system supports them. Use with care since usually the
4538 themes represent the appearance chosen by the user to be used for all
4539 applications on the system.
4540 """
54f9ee45 4541 return _controls_.ListCtrl_SetBackgroundColour(*args, **kwargs)
e811c8ce
RD
4542
4543 def GetColumn(*args, **kwargs):
a95a7133 4544 """GetColumn(self, int col) -> ListItem"""
54f9ee45 4545 val = _controls_.ListCtrl_GetColumn(*args, **kwargs)
d14a1e28
RD
4546 if val is not None: val.thisown = 1
4547 return val
e811c8ce
RD
4548
4549 def SetColumn(*args, **kwargs):
a95a7133 4550 """SetColumn(self, int col, ListItem item) -> bool"""
54f9ee45 4551 return _controls_.ListCtrl_SetColumn(*args, **kwargs)
e811c8ce
RD
4552
4553 def GetColumnWidth(*args, **kwargs):
a95a7133 4554 """GetColumnWidth(self, int col) -> int"""
54f9ee45 4555 return _controls_.ListCtrl_GetColumnWidth(*args, **kwargs)
e811c8ce
RD
4556
4557 def SetColumnWidth(*args, **kwargs):
a95a7133 4558 """SetColumnWidth(self, int col, int width) -> bool"""
54f9ee45 4559 return _controls_.ListCtrl_SetColumnWidth(*args, **kwargs)
e811c8ce
RD
4560
4561 def GetCountPerPage(*args, **kwargs):
a95a7133 4562 """GetCountPerPage(self) -> int"""
54f9ee45 4563 return _controls_.ListCtrl_GetCountPerPage(*args, **kwargs)
e811c8ce
RD
4564
4565 def GetViewRect(*args, **kwargs):
a95a7133 4566 """GetViewRect(self) -> Rect"""
54f9ee45 4567 return _controls_.ListCtrl_GetViewRect(*args, **kwargs)
e811c8ce
RD
4568
4569 def GetItem(*args, **kwargs):
a95a7133 4570 """GetItem(self, long itemId, int col=0) -> ListItem"""
54f9ee45 4571 val = _controls_.ListCtrl_GetItem(*args, **kwargs)
d14a1e28
RD
4572 if val is not None: val.thisown = 1
4573 return val
e811c8ce
RD
4574
4575 def SetItem(*args, **kwargs):
a95a7133 4576 """SetItem(self, ListItem info) -> bool"""
54f9ee45 4577 return _controls_.ListCtrl_SetItem(*args, **kwargs)
e811c8ce
RD
4578
4579 def SetStringItem(*args, **kwargs):
a95a7133 4580 """SetStringItem(self, long index, int col, String label, int imageId=-1) -> long"""
54f9ee45 4581 return _controls_.ListCtrl_SetStringItem(*args, **kwargs)
e811c8ce
RD
4582
4583 def GetItemState(*args, **kwargs):
a95a7133 4584 """GetItemState(self, long item, long stateMask) -> int"""
54f9ee45 4585 return _controls_.ListCtrl_GetItemState(*args, **kwargs)
e811c8ce
RD
4586
4587 def SetItemState(*args, **kwargs):
a95a7133 4588 """SetItemState(self, long item, long state, long stateMask) -> bool"""
54f9ee45 4589 return _controls_.ListCtrl_SetItemState(*args, **kwargs)
e811c8ce
RD
4590
4591 def SetItemImage(*args, **kwargs):
1fc3b23a 4592 """SetItemImage(self, long item, int image, int selImage=-1) -> bool"""
54f9ee45 4593 return _controls_.ListCtrl_SetItemImage(*args, **kwargs)
e811c8ce
RD
4594
4595 def GetItemText(*args, **kwargs):
a95a7133 4596 """GetItemText(self, long item) -> String"""
54f9ee45 4597 return _controls_.ListCtrl_GetItemText(*args, **kwargs)
e811c8ce
RD
4598
4599 def SetItemText(*args, **kwargs):
a95a7133 4600 """SetItemText(self, long item, String str)"""
54f9ee45 4601 return _controls_.ListCtrl_SetItemText(*args, **kwargs)
e811c8ce
RD
4602
4603 def GetItemData(*args, **kwargs):
a95a7133 4604 """GetItemData(self, long item) -> long"""
54f9ee45 4605 return _controls_.ListCtrl_GetItemData(*args, **kwargs)
e811c8ce
RD
4606
4607 def SetItemData(*args, **kwargs):
a95a7133 4608 """SetItemData(self, long item, long data) -> bool"""
54f9ee45 4609 return _controls_.ListCtrl_SetItemData(*args, **kwargs)
e811c8ce
RD
4610
4611 def GetItemPosition(*args, **kwargs):
a95a7133 4612 """GetItemPosition(self, long item) -> Point"""
54f9ee45 4613 return _controls_.ListCtrl_GetItemPosition(*args, **kwargs)
e811c8ce
RD
4614
4615 def GetItemRect(*args, **kwargs):
a95a7133 4616 """GetItemRect(self, long item, int code=LIST_RECT_BOUNDS) -> Rect"""
54f9ee45 4617 return _controls_.ListCtrl_GetItemRect(*args, **kwargs)
e811c8ce
RD
4618
4619 def SetItemPosition(*args, **kwargs):
a95a7133 4620 """SetItemPosition(self, long item, Point pos) -> bool"""
54f9ee45 4621 return _controls_.ListCtrl_SetItemPosition(*args, **kwargs)
e811c8ce
RD
4622
4623 def GetItemCount(*args, **kwargs):
a95a7133 4624 """GetItemCount(self) -> int"""
54f9ee45 4625 return _controls_.ListCtrl_GetItemCount(*args, **kwargs)
e811c8ce
RD
4626
4627 def GetColumnCount(*args, **kwargs):
a95a7133 4628 """GetColumnCount(self) -> int"""
54f9ee45 4629 return _controls_.ListCtrl_GetColumnCount(*args, **kwargs)
e811c8ce
RD
4630
4631 def GetItemSpacing(*args, **kwargs):
a95a7133 4632 """GetItemSpacing(self) -> Size"""
54f9ee45 4633 return _controls_.ListCtrl_GetItemSpacing(*args, **kwargs)
e811c8ce
RD
4634
4635 def SetItemSpacing(*args, **kwargs):
a95a7133 4636 """SetItemSpacing(self, int spacing, bool isSmall=False)"""
54f9ee45 4637 return _controls_.ListCtrl_SetItemSpacing(*args, **kwargs)
e811c8ce
RD
4638
4639 def GetSelectedItemCount(*args, **kwargs):
a95a7133 4640 """GetSelectedItemCount(self) -> int"""
54f9ee45 4641 return _controls_.ListCtrl_GetSelectedItemCount(*args, **kwargs)
e811c8ce
RD
4642
4643 def GetTextColour(*args, **kwargs):
a95a7133 4644 """GetTextColour(self) -> Colour"""
54f9ee45 4645 return _controls_.ListCtrl_GetTextColour(*args, **kwargs)
e811c8ce
RD
4646
4647 def SetTextColour(*args, **kwargs):
a95a7133 4648 """SetTextColour(self, Colour col)"""
54f9ee45 4649 return _controls_.ListCtrl_SetTextColour(*args, **kwargs)
e811c8ce
RD
4650
4651 def GetTopItem(*args, **kwargs):
a95a7133 4652 """GetTopItem(self) -> long"""
54f9ee45 4653 return _controls_.ListCtrl_GetTopItem(*args, **kwargs)
e811c8ce
RD
4654
4655 def SetSingleStyle(*args, **kwargs):
a95a7133 4656 """SetSingleStyle(self, long style, bool add=True)"""
54f9ee45 4657 return _controls_.ListCtrl_SetSingleStyle(*args, **kwargs)
e811c8ce
RD
4658
4659 def SetWindowStyleFlag(*args, **kwargs):
15afbcd0 4660 """
a95a7133 4661 SetWindowStyleFlag(self, long style)
15afbcd0 4662
41e2b43e
RD
4663 Sets the style of the window. Please note that some styles cannot be
4664 changed after the window creation and that Refresh() might need to be
4665 called after changing the others for the change to take place
4666 immediately.
15afbcd0 4667 """
54f9ee45 4668 return _controls_.ListCtrl_SetWindowStyleFlag(*args, **kwargs)
e811c8ce
RD
4669
4670 def GetNextItem(*args, **kwargs):
a95a7133 4671 """GetNextItem(self, long item, int geometry=LIST_NEXT_ALL, int state=LIST_STATE_DONTCARE) -> long"""
54f9ee45 4672 return _controls_.ListCtrl_GetNextItem(*args, **kwargs)
e811c8ce
RD
4673
4674 def GetImageList(*args, **kwargs):
a95a7133 4675 """GetImageList(self, int which) -> ImageList"""
54f9ee45 4676 return _controls_.ListCtrl_GetImageList(*args, **kwargs)
e811c8ce
RD
4677
4678 def SetImageList(*args, **kwargs):
a95a7133 4679 """SetImageList(self, ImageList imageList, int which)"""
54f9ee45 4680 return _controls_.ListCtrl_SetImageList(*args, **kwargs)
e811c8ce
RD
4681
4682 def AssignImageList(*args, **kwargs):
a95a7133 4683 """AssignImageList(self, ImageList imageList, int which)"""
54f9ee45 4684 return _controls_.ListCtrl_AssignImageList(*args, **kwargs)
e811c8ce 4685
4276dc52 4686 def InReportView(*args, **kwargs):
a95a7133 4687 """InReportView(self) -> bool"""
54f9ee45 4688 return _controls_.ListCtrl_InReportView(*args, **kwargs)
4276dc52 4689
e811c8ce 4690 def IsVirtual(*args, **kwargs):
a95a7133 4691 """IsVirtual(self) -> bool"""
54f9ee45 4692 return _controls_.ListCtrl_IsVirtual(*args, **kwargs)
e811c8ce
RD
4693
4694 def RefreshItem(*args, **kwargs):
a95a7133 4695 """RefreshItem(self, long item)"""
54f9ee45 4696 return _controls_.ListCtrl_RefreshItem(*args, **kwargs)
e811c8ce
RD
4697
4698 def RefreshItems(*args, **kwargs):
a95a7133 4699 """RefreshItems(self, long itemFrom, long itemTo)"""
54f9ee45 4700 return _controls_.ListCtrl_RefreshItems(*args, **kwargs)
e811c8ce
RD
4701
4702 def Arrange(*args, **kwargs):
a95a7133 4703 """Arrange(self, int flag=LIST_ALIGN_DEFAULT) -> bool"""
54f9ee45 4704 return _controls_.ListCtrl_Arrange(*args, **kwargs)
e811c8ce
RD
4705
4706 def DeleteItem(*args, **kwargs):
a95a7133 4707 """DeleteItem(self, long item) -> bool"""
54f9ee45 4708 return _controls_.ListCtrl_DeleteItem(*args, **kwargs)
e811c8ce
RD
4709
4710 def DeleteAllItems(*args, **kwargs):
a95a7133 4711 """DeleteAllItems(self) -> bool"""
54f9ee45 4712 return _controls_.ListCtrl_DeleteAllItems(*args, **kwargs)
e811c8ce
RD
4713
4714 def DeleteColumn(*args, **kwargs):
a95a7133 4715 """DeleteColumn(self, int col) -> bool"""
54f9ee45 4716 return _controls_.ListCtrl_DeleteColumn(*args, **kwargs)
e811c8ce
RD
4717
4718 def DeleteAllColumns(*args, **kwargs):
a95a7133 4719 """DeleteAllColumns(self) -> bool"""
54f9ee45 4720 return _controls_.ListCtrl_DeleteAllColumns(*args, **kwargs)
e811c8ce
RD
4721
4722 def ClearAll(*args, **kwargs):
a95a7133 4723 """ClearAll(self)"""
54f9ee45 4724 return _controls_.ListCtrl_ClearAll(*args, **kwargs)
e811c8ce
RD
4725
4726 def EditLabel(*args, **kwargs):
a95a7133 4727 """EditLabel(self, long item)"""
54f9ee45 4728 return _controls_.ListCtrl_EditLabel(*args, **kwargs)
e811c8ce
RD
4729
4730 def EnsureVisible(*args, **kwargs):
a95a7133 4731 """EnsureVisible(self, long item) -> bool"""
54f9ee45 4732 return _controls_.ListCtrl_EnsureVisible(*args, **kwargs)
e811c8ce
RD
4733
4734 def FindItem(*args, **kwargs):
a95a7133 4735 """FindItem(self, long start, String str, bool partial=False) -> long"""
54f9ee45 4736 return _controls_.ListCtrl_FindItem(*args, **kwargs)
e811c8ce
RD
4737
4738 def FindItemData(*args, **kwargs):
a95a7133 4739 """FindItemData(self, long start, long data) -> long"""
54f9ee45 4740 return _controls_.ListCtrl_FindItemData(*args, **kwargs)
e811c8ce
RD
4741
4742 def FindItemAtPos(*args, **kwargs):
a95a7133 4743 """FindItemAtPos(self, long start, Point pt, int direction) -> long"""
54f9ee45 4744 return _controls_.ListCtrl_FindItemAtPos(*args, **kwargs)
e811c8ce
RD
4745
4746 def HitTest(*args, **kwargs):
fd2dc343
RD
4747 """
4748 HitTest(Point point) -> (item, where)
4749
4750 Determines which item (if any) is at the specified point, giving
53aa7709 4751 in the second return value (see wx.LIST_HITTEST flags.)
fd2dc343 4752 """
54f9ee45 4753 return _controls_.ListCtrl_HitTest(*args, **kwargs)
e811c8ce
RD
4754
4755 def InsertItem(*args, **kwargs):
a95a7133 4756 """InsertItem(self, ListItem info) -> long"""
54f9ee45 4757 return _controls_.ListCtrl_InsertItem(*args, **kwargs)
e811c8ce
RD
4758
4759 def InsertStringItem(*args, **kwargs):
a95a7133 4760 """InsertStringItem(self, long index, String label) -> long"""
54f9ee45 4761 return _controls_.ListCtrl_InsertStringItem(*args, **kwargs)
e811c8ce
RD
4762
4763 def InsertImageItem(*args, **kwargs):
a95a7133 4764 """InsertImageItem(self, long index, int imageIndex) -> long"""
54f9ee45 4765 return _controls_.ListCtrl_InsertImageItem(*args, **kwargs)
e811c8ce
RD
4766
4767 def InsertImageStringItem(*args, **kwargs):
a95a7133 4768 """InsertImageStringItem(self, long index, String label, int imageIndex) -> long"""
54f9ee45 4769 return _controls_.ListCtrl_InsertImageStringItem(*args, **kwargs)
e811c8ce 4770
a3957d3d
RD
4771 def InsertColumnItem(*args, **kwargs):
4772 """InsertColumnItem(self, long col, ListItem info) -> long"""
4773 return _controls_.ListCtrl_InsertColumnItem(*args, **kwargs)
e811c8ce 4774
a3957d3d 4775 InsertColumnInfo = InsertColumnItem
e811c8ce 4776 def InsertColumn(*args, **kwargs):
0df68c9f 4777 """
a95a7133 4778 InsertColumn(self, long col, String heading, int format=LIST_FORMAT_LEFT,
0df68c9f
RD
4779 int width=-1) -> long
4780 """
54f9ee45 4781 return _controls_.ListCtrl_InsertColumn(*args, **kwargs)
e811c8ce
RD
4782
4783 def SetItemCount(*args, **kwargs):
a95a7133 4784 """SetItemCount(self, long count)"""
54f9ee45 4785 return _controls_.ListCtrl_SetItemCount(*args, **kwargs)
e811c8ce
RD
4786
4787 def ScrollList(*args, **kwargs):
a95a7133 4788 """ScrollList(self, int dx, int dy) -> bool"""
54f9ee45 4789 return _controls_.ListCtrl_ScrollList(*args, **kwargs)
e811c8ce
RD
4790
4791 def SetItemTextColour(*args, **kwargs):
a95a7133 4792 """SetItemTextColour(self, long item, Colour col)"""
54f9ee45 4793 return _controls_.ListCtrl_SetItemTextColour(*args, **kwargs)
e811c8ce
RD
4794
4795 def GetItemTextColour(*args, **kwargs):
a95a7133 4796 """GetItemTextColour(self, long item) -> Colour"""
54f9ee45 4797 return _controls_.ListCtrl_GetItemTextColour(*args, **kwargs)
e811c8ce
RD
4798
4799 def SetItemBackgroundColour(*args, **kwargs):
a95a7133 4800 """SetItemBackgroundColour(self, long item, Colour col)"""
54f9ee45 4801 return _controls_.ListCtrl_SetItemBackgroundColour(*args, **kwargs)
e811c8ce
RD
4802
4803 def GetItemBackgroundColour(*args, **kwargs):
a95a7133 4804 """GetItemBackgroundColour(self, long item) -> Colour"""
54f9ee45 4805 return _controls_.ListCtrl_GetItemBackgroundColour(*args, **kwargs)
e811c8ce 4806
d14a1e28
RD
4807 #
4808 # Some helpers...
4809 def Select(self, idx, on=1):
4810 '''[de]select an item'''
e811c8ce 4811 if on: state = wx.LIST_STATE_SELECTED
d14a1e28 4812 else: state = 0
e811c8ce 4813 self.SetItemState(idx, state, wx.LIST_STATE_SELECTED)
d14a1e28
RD
4814
4815 def Focus(self, idx):
4816 '''Focus and show the given item'''
e811c8ce 4817 self.SetItemState(idx, wx.LIST_STATE_FOCUSED, wx.LIST_STATE_FOCUSED)
d14a1e28
RD
4818 self.EnsureVisible(idx)
4819
4820 def GetFocusedItem(self):
4821 '''get the currently focused item or -1 if none'''
e811c8ce 4822 return self.GetNextItem(-1, wx.LIST_NEXT_ALL, wx.LIST_STATE_FOCUSED)
d14a1e28
RD
4823
4824 def GetFirstSelected(self, *args):
4825 '''return first selected item, or -1 when none'''
4826 return self.GetNextSelected(-1)
4827
4828 def GetNextSelected(self, item):
4829 '''return subsequent selected items, or -1 when no more'''
e811c8ce 4830 return self.GetNextItem(item, wx.LIST_NEXT_ALL, wx.LIST_STATE_SELECTED)
d14a1e28
RD
4831
4832 def IsSelected(self, idx):
e811c8ce 4833 '''return True if the item is selected'''
38aff7bb 4834 return (self.GetItemState(idx, wx.LIST_STATE_SELECTED) & wx.LIST_STATE_SELECTED) != 0
d14a1e28
RD
4835
4836 def SetColumnImage(self, col, image):
4837 item = self.GetColumn(col)
e811c8ce
RD
4838 # preserve all other attributes too
4839 item.SetMask( wx.LIST_MASK_STATE |
4840 wx.LIST_MASK_TEXT |
4841 wx.LIST_MASK_IMAGE |
4842 wx.LIST_MASK_DATA |
4843 wx.LIST_SET_ITEM |
4844 wx.LIST_MASK_WIDTH |
4845 wx.LIST_MASK_FORMAT )
d14a1e28
RD
4846 item.SetImage(image)
4847 self.SetColumn(col, item)
4848
4849 def ClearColumnImage(self, col):
4850 self.SetColumnImage(col, -1)
4851
4852 def Append(self, entry):
4853 '''Append an item to the list control. The entry parameter should be a
4854 sequence with an item for each column'''
4855 if len(entry):
e811c8ce 4856 if wx.USE_UNICODE:
d14a1e28
RD
4857 cvtfunc = unicode
4858 else:
4859 cvtfunc = str
4860 pos = self.GetItemCount()
4861 self.InsertStringItem(pos, cvtfunc(entry[0]))
4862 for i in range(1, len(entry)):
4863 self.SetStringItem(pos, i, cvtfunc(entry[i]))
4864 return pos
4865
e811c8ce 4866 def SortItems(*args, **kwargs):
a95a7133 4867 """SortItems(self, PyObject func) -> bool"""
54f9ee45 4868 return _controls_.ListCtrl_SortItems(*args, **kwargs)
e811c8ce
RD
4869
4870 def GetMainWindow(*args, **kwargs):
a95a7133 4871 """GetMainWindow(self) -> Window"""
54f9ee45 4872 return _controls_.ListCtrl_GetMainWindow(*args, **kwargs)
e811c8ce 4873
74a57fcd 4874 def GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
4875 """
4876 GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
4877
4878 Get the default attributes for this class. This is useful if you want
4879 to use the same font or colour in your own control as in a standard
4880 control -- which is a much better idea than hard coding specific
4881 colours or fonts which might look completely out of place on the
4882 user's system, especially if it uses themes.
4883
4884 The variant parameter is only relevant under Mac currently and is
4885 ignore under other platforms. Under Mac, it will change the size of
4886 the returned font. See `wx.Window.SetWindowVariant` for more about
4887 this.
4888 """
54f9ee45 4889 return _controls_.ListCtrl_GetClassDefaultAttributes(*args, **kwargs)
74a57fcd
RD
4890
4891 GetClassDefaultAttributes = staticmethod(GetClassDefaultAttributes)
70551f47 4892
d14a1e28
RD
4893class ListCtrlPtr(ListCtrl):
4894 def __init__(self, this):
4895 self.this = this
4896 if not hasattr(self,"thisown"): self.thisown = 0
4897 self.__class__ = ListCtrl
54f9ee45 4898_controls_.ListCtrl_swigregister(ListCtrlPtr)
70551f47 4899
d14a1e28 4900def PreListCtrl(*args, **kwargs):
e811c8ce 4901 """PreListCtrl() -> ListCtrl"""
54f9ee45 4902 val = _controls_.new_PreListCtrl(*args, **kwargs)
aa2a5b86
RD
4903 val.thisown = 1
4904 return val
4905
74a57fcd 4906def ListCtrl_GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
4907 """
4908 ListCtrl_GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
4909
4910 Get the default attributes for this class. This is useful if you want
4911 to use the same font or colour in your own control as in a standard
4912 control -- which is a much better idea than hard coding specific
4913 colours or fonts which might look completely out of place on the
4914 user's system, especially if it uses themes.
4915
4916 The variant parameter is only relevant under Mac currently and is
4917 ignore under other platforms. Under Mac, it will change the size of
4918 the returned font. See `wx.Window.SetWindowVariant` for more about
4919 this.
4920 """
54f9ee45 4921 return _controls_.ListCtrl_GetClassDefaultAttributes(*args, **kwargs)
74a57fcd 4922
d14a1e28 4923#---------------------------------------------------------------------------
70551f47 4924
d14a1e28 4925class ListView(ListCtrl):
093d3ff1 4926 """Proxy of C++ ListView class"""
e811c8ce
RD
4927 def __repr__(self):
4928 return "<%s.%s; proxy of C++ wxListView instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 4929 def __init__(self, *args, **kwargs):
0df68c9f 4930 """
a95a7133 4931 __init__(self, Window parent, int id=-1, Point pos=DefaultPosition,
0df68c9f 4932 Size size=DefaultSize, long style=LC_REPORT,
b2dc1044 4933 Validator validator=DefaultValidator, String name=ListCtrlNameStr) -> ListView
0df68c9f 4934 """
54f9ee45 4935 newobj = _controls_.new_ListView(*args, **kwargs)
d14a1e28 4936 self.this = newobj.this
70551f47 4937 self.thisown = 1
d14a1e28 4938 del newobj.thisown
0220cbc1 4939 self._setOORInfo(self)
e811c8ce
RD
4940
4941 def Create(*args, **kwargs):
0df68c9f 4942 """
a95a7133 4943 Create(self, Window parent, int id=-1, Point pos=DefaultPosition,
0df68c9f 4944 Size size=DefaultSize, long style=LC_REPORT,
b2dc1044 4945 Validator validator=DefaultValidator, String name=ListCtrlNameStr) -> bool
15afbcd0
RD
4946
4947 Do the 2nd phase and create the GUI control.
0df68c9f 4948 """
54f9ee45 4949 return _controls_.ListView_Create(*args, **kwargs)
e811c8ce
RD
4950
4951 def Select(*args, **kwargs):
a95a7133 4952 """Select(self, long n, bool on=True)"""
54f9ee45 4953 return _controls_.ListView_Select(*args, **kwargs)
e811c8ce
RD
4954
4955 def Focus(*args, **kwargs):
a95a7133 4956 """Focus(self, long index)"""
54f9ee45 4957 return _controls_.ListView_Focus(*args, **kwargs)
e811c8ce
RD
4958
4959 def GetFocusedItem(*args, **kwargs):
a95a7133 4960 """GetFocusedItem(self) -> long"""
54f9ee45 4961 return _controls_.ListView_GetFocusedItem(*args, **kwargs)
e811c8ce
RD
4962
4963 def GetNextSelected(*args, **kwargs):
a95a7133 4964 """GetNextSelected(self, long item) -> long"""
54f9ee45 4965 return _controls_.ListView_GetNextSelected(*args, **kwargs)
e811c8ce
RD
4966
4967 def GetFirstSelected(*args, **kwargs):
a95a7133 4968 """GetFirstSelected(self) -> long"""
54f9ee45 4969 return _controls_.ListView_GetFirstSelected(*args, **kwargs)
e811c8ce
RD
4970
4971 def IsSelected(*args, **kwargs):
a95a7133 4972 """IsSelected(self, long index) -> bool"""
54f9ee45 4973 return _controls_.ListView_IsSelected(*args, **kwargs)
e811c8ce
RD
4974
4975 def SetColumnImage(*args, **kwargs):
a95a7133 4976 """SetColumnImage(self, int col, int image)"""
54f9ee45 4977 return _controls_.ListView_SetColumnImage(*args, **kwargs)
e811c8ce
RD
4978
4979 def ClearColumnImage(*args, **kwargs):
a95a7133 4980 """ClearColumnImage(self, int col)"""
54f9ee45 4981 return _controls_.ListView_ClearColumnImage(*args, **kwargs)
e811c8ce 4982
f6bcfd97 4983
d14a1e28
RD
4984class ListViewPtr(ListView):
4985 def __init__(self, this):
4986 self.this = this
4987 if not hasattr(self,"thisown"): self.thisown = 0
4988 self.__class__ = ListView
54f9ee45 4989_controls_.ListView_swigregister(ListViewPtr)
f6bcfd97 4990
d14a1e28 4991def PreListView(*args, **kwargs):
e811c8ce 4992 """PreListView() -> ListView"""
54f9ee45 4993 val = _controls_.new_PreListView(*args, **kwargs)
aa2a5b86
RD
4994 val.thisown = 1
4995 return val
4996
d14a1e28
RD
4997#---------------------------------------------------------------------------
4998
54f9ee45
RD
4999TR_NO_BUTTONS = _controls_.TR_NO_BUTTONS
5000TR_HAS_BUTTONS = _controls_.TR_HAS_BUTTONS
5001TR_NO_LINES = _controls_.TR_NO_LINES
5002TR_LINES_AT_ROOT = _controls_.TR_LINES_AT_ROOT
5003TR_SINGLE = _controls_.TR_SINGLE
5004TR_MULTIPLE = _controls_.TR_MULTIPLE
5005TR_EXTENDED = _controls_.TR_EXTENDED
5006TR_HAS_VARIABLE_ROW_HEIGHT = _controls_.TR_HAS_VARIABLE_ROW_HEIGHT
5007TR_EDIT_LABELS = _controls_.TR_EDIT_LABELS
5008TR_HIDE_ROOT = _controls_.TR_HIDE_ROOT
5009TR_ROW_LINES = _controls_.TR_ROW_LINES
5010TR_FULL_ROW_HIGHLIGHT = _controls_.TR_FULL_ROW_HIGHLIGHT
5011TR_DEFAULT_STYLE = _controls_.TR_DEFAULT_STYLE
5012TR_TWIST_BUTTONS = _controls_.TR_TWIST_BUTTONS
5013TR_MAC_BUTTONS = _controls_.TR_MAC_BUTTONS
5014TR_AQUA_BUTTONS = _controls_.TR_AQUA_BUTTONS
5015TreeItemIcon_Normal = _controls_.TreeItemIcon_Normal
5016TreeItemIcon_Selected = _controls_.TreeItemIcon_Selected
5017TreeItemIcon_Expanded = _controls_.TreeItemIcon_Expanded
5018TreeItemIcon_SelectedExpanded = _controls_.TreeItemIcon_SelectedExpanded
5019TreeItemIcon_Max = _controls_.TreeItemIcon_Max
5020TREE_HITTEST_ABOVE = _controls_.TREE_HITTEST_ABOVE
5021TREE_HITTEST_BELOW = _controls_.TREE_HITTEST_BELOW
5022TREE_HITTEST_NOWHERE = _controls_.TREE_HITTEST_NOWHERE
5023TREE_HITTEST_ONITEMBUTTON = _controls_.TREE_HITTEST_ONITEMBUTTON
5024TREE_HITTEST_ONITEMICON = _controls_.TREE_HITTEST_ONITEMICON
5025TREE_HITTEST_ONITEMINDENT = _controls_.TREE_HITTEST_ONITEMINDENT
5026TREE_HITTEST_ONITEMLABEL = _controls_.TREE_HITTEST_ONITEMLABEL
5027TREE_HITTEST_ONITEMRIGHT = _controls_.TREE_HITTEST_ONITEMRIGHT
5028TREE_HITTEST_ONITEMSTATEICON = _controls_.TREE_HITTEST_ONITEMSTATEICON
5029TREE_HITTEST_TOLEFT = _controls_.TREE_HITTEST_TOLEFT
5030TREE_HITTEST_TORIGHT = _controls_.TREE_HITTEST_TORIGHT
5031TREE_HITTEST_ONITEMUPPERPART = _controls_.TREE_HITTEST_ONITEMUPPERPART
5032TREE_HITTEST_ONITEMLOWERPART = _controls_.TREE_HITTEST_ONITEMLOWERPART
5033TREE_HITTEST_ONITEM = _controls_.TREE_HITTEST_ONITEM
d14a1e28
RD
5034#---------------------------------------------------------------------------
5035
5036class TreeItemId(object):
093d3ff1 5037 """Proxy of C++ TreeItemId class"""
e811c8ce
RD
5038 def __repr__(self):
5039 return "<%s.%s; proxy of C++ wxTreeItemId instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 5040 def __init__(self, *args, **kwargs):
a95a7133 5041 """__init__(self) -> TreeItemId"""
54f9ee45 5042 newobj = _controls_.new_TreeItemId(*args, **kwargs)
d14a1e28
RD
5043 self.this = newobj.this
5044 self.thisown = 1
5045 del newobj.thisown
54f9ee45 5046 def __del__(self, destroy=_controls_.delete_TreeItemId):
a95a7133 5047 """__del__(self)"""
d14a1e28
RD
5048 try:
5049 if self.thisown: destroy(self)
5050 except: pass
e811c8ce
RD
5051
5052 def IsOk(*args, **kwargs):
a95a7133 5053 """IsOk(self) -> bool"""
54f9ee45 5054 return _controls_.TreeItemId_IsOk(*args, **kwargs)
e811c8ce
RD
5055
5056 def __eq__(*args, **kwargs):
a95a7133 5057 """__eq__(self, TreeItemId other) -> bool"""
54f9ee45 5058 return _controls_.TreeItemId___eq__(*args, **kwargs)
e811c8ce
RD
5059
5060 def __ne__(*args, **kwargs):
a95a7133 5061 """__ne__(self, TreeItemId other) -> bool"""
54f9ee45 5062 return _controls_.TreeItemId___ne__(*args, **kwargs)
e811c8ce 5063
54f9ee45 5064 m_pItem = property(_controls_.TreeItemId_m_pItem_get, _controls_.TreeItemId_m_pItem_set)
d14a1e28
RD
5065 Ok = IsOk
5066 def __nonzero__(self): return self.IsOk()
f6bcfd97 5067
d14a1e28
RD
5068class TreeItemIdPtr(TreeItemId):
5069 def __init__(self, this):
f6bcfd97 5070 self.this = this
d14a1e28
RD
5071 if not hasattr(self,"thisown"): self.thisown = 0
5072 self.__class__ = TreeItemId
54f9ee45 5073_controls_.TreeItemId_swigregister(TreeItemIdPtr)
b2dc1044 5074TreeCtrlNameStr = cvar.TreeCtrlNameStr
d14a1e28
RD
5075
5076class TreeItemData(object):
093d3ff1 5077 """Proxy of C++ TreeItemData class"""
e811c8ce
RD
5078 def __repr__(self):
5079 return "<%s.%s; proxy of C++ wxPyTreeItemData instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 5080 def __init__(self, *args, **kwargs):
a95a7133 5081 """__init__(self, PyObject obj=None) -> TreeItemData"""
54f9ee45 5082 newobj = _controls_.new_TreeItemData(*args, **kwargs)
d14a1e28
RD
5083 self.this = newobj.this
5084 self.thisown = 1
5085 del newobj.thisown
e811c8ce 5086 def GetData(*args, **kwargs):
a95a7133 5087 """GetData(self) -> PyObject"""
54f9ee45 5088 return _controls_.TreeItemData_GetData(*args, **kwargs)
e811c8ce
RD
5089
5090 def SetData(*args, **kwargs):
a95a7133 5091 """SetData(self, PyObject obj)"""
54f9ee45 5092 return _controls_.TreeItemData_SetData(*args, **kwargs)
e811c8ce
RD
5093
5094 def GetId(*args, **kwargs):
a95a7133 5095 """GetId(self) -> TreeItemId"""
54f9ee45 5096 return _controls_.TreeItemData_GetId(*args, **kwargs)
e811c8ce
RD
5097
5098 def SetId(*args, **kwargs):
a95a7133 5099 """SetId(self, TreeItemId id)"""
54f9ee45 5100 return _controls_.TreeItemData_SetId(*args, **kwargs)
e811c8ce
RD
5101
5102 def Destroy(*args, **kwargs):
a95a7133 5103 """Destroy(self)"""
54f9ee45 5104 return _controls_.TreeItemData_Destroy(*args, **kwargs)
e811c8ce 5105
d14a1e28
RD
5106
5107class TreeItemDataPtr(TreeItemData):
5108 def __init__(self, this):
5109 self.this = this
5110 if not hasattr(self,"thisown"): self.thisown = 0
5111 self.__class__ = TreeItemData
54f9ee45 5112_controls_.TreeItemData_swigregister(TreeItemDataPtr)
d14a1e28
RD
5113
5114#---------------------------------------------------------------------------
5115
54f9ee45
RD
5116wxEVT_COMMAND_TREE_BEGIN_DRAG = _controls_.wxEVT_COMMAND_TREE_BEGIN_DRAG
5117wxEVT_COMMAND_TREE_BEGIN_RDRAG = _controls_.wxEVT_COMMAND_TREE_BEGIN_RDRAG
5118wxEVT_COMMAND_TREE_BEGIN_LABEL_EDIT = _controls_.wxEVT_COMMAND_TREE_BEGIN_LABEL_EDIT
5119wxEVT_COMMAND_TREE_END_LABEL_EDIT = _controls_.wxEVT_COMMAND_TREE_END_LABEL_EDIT
5120wxEVT_COMMAND_TREE_DELETE_ITEM = _controls_.wxEVT_COMMAND_TREE_DELETE_ITEM
5121wxEVT_COMMAND_TREE_GET_INFO = _controls_.wxEVT_COMMAND_TREE_GET_INFO
5122wxEVT_COMMAND_TREE_SET_INFO = _controls_.wxEVT_COMMAND_TREE_SET_INFO
5123wxEVT_COMMAND_TREE_ITEM_EXPANDED = _controls_.wxEVT_COMMAND_TREE_ITEM_EXPANDED
5124wxEVT_COMMAND_TREE_ITEM_EXPANDING = _controls_.wxEVT_COMMAND_TREE_ITEM_EXPANDING
5125wxEVT_COMMAND_TREE_ITEM_COLLAPSED = _controls_.wxEVT_COMMAND_TREE_ITEM_COLLAPSED
5126wxEVT_COMMAND_TREE_ITEM_COLLAPSING = _controls_.wxEVT_COMMAND_TREE_ITEM_COLLAPSING
5127wxEVT_COMMAND_TREE_SEL_CHANGED = _controls_.wxEVT_COMMAND_TREE_SEL_CHANGED
5128wxEVT_COMMAND_TREE_SEL_CHANGING = _controls_.wxEVT_COMMAND_TREE_SEL_CHANGING
5129wxEVT_COMMAND_TREE_KEY_DOWN = _controls_.wxEVT_COMMAND_TREE_KEY_DOWN
5130wxEVT_COMMAND_TREE_ITEM_ACTIVATED = _controls_.wxEVT_COMMAND_TREE_ITEM_ACTIVATED
5131wxEVT_COMMAND_TREE_ITEM_RIGHT_CLICK = _controls_.wxEVT_COMMAND_TREE_ITEM_RIGHT_CLICK
5132wxEVT_COMMAND_TREE_ITEM_MIDDLE_CLICK = _controls_.wxEVT_COMMAND_TREE_ITEM_MIDDLE_CLICK
5133wxEVT_COMMAND_TREE_END_DRAG = _controls_.wxEVT_COMMAND_TREE_END_DRAG
5134wxEVT_COMMAND_TREE_STATE_IMAGE_CLICK = _controls_.wxEVT_COMMAND_TREE_STATE_IMAGE_CLICK
5135wxEVT_COMMAND_TREE_ITEM_GETTOOLTIP = _controls_.wxEVT_COMMAND_TREE_ITEM_GETTOOLTIP
e505d15e 5136wxEVT_COMMAND_TREE_ITEM_MENU = _controls_.wxEVT_COMMAND_TREE_ITEM_MENU
d14a1e28
RD
5137EVT_TREE_BEGIN_DRAG = wx.PyEventBinder(wxEVT_COMMAND_TREE_BEGIN_DRAG , 1)
5138EVT_TREE_BEGIN_RDRAG = wx.PyEventBinder(wxEVT_COMMAND_TREE_BEGIN_RDRAG , 1)
5139EVT_TREE_BEGIN_LABEL_EDIT = wx.PyEventBinder(wxEVT_COMMAND_TREE_BEGIN_LABEL_EDIT , 1)
5140EVT_TREE_END_LABEL_EDIT = wx.PyEventBinder(wxEVT_COMMAND_TREE_END_LABEL_EDIT , 1)
5141EVT_TREE_DELETE_ITEM = wx.PyEventBinder(wxEVT_COMMAND_TREE_DELETE_ITEM , 1)
5142EVT_TREE_GET_INFO = wx.PyEventBinder(wxEVT_COMMAND_TREE_GET_INFO , 1)
5143EVT_TREE_SET_INFO = wx.PyEventBinder(wxEVT_COMMAND_TREE_SET_INFO , 1)
5144EVT_TREE_ITEM_EXPANDED = wx.PyEventBinder(wxEVT_COMMAND_TREE_ITEM_EXPANDED , 1)
5145EVT_TREE_ITEM_EXPANDING = wx.PyEventBinder(wxEVT_COMMAND_TREE_ITEM_EXPANDING , 1)
5146EVT_TREE_ITEM_COLLAPSED = wx.PyEventBinder(wxEVT_COMMAND_TREE_ITEM_COLLAPSED , 1)
5147EVT_TREE_ITEM_COLLAPSING = wx.PyEventBinder(wxEVT_COMMAND_TREE_ITEM_COLLAPSING , 1)
5148EVT_TREE_SEL_CHANGED = wx.PyEventBinder(wxEVT_COMMAND_TREE_SEL_CHANGED , 1)
5149EVT_TREE_SEL_CHANGING = wx.PyEventBinder(wxEVT_COMMAND_TREE_SEL_CHANGING , 1)
5150EVT_TREE_KEY_DOWN = wx.PyEventBinder(wxEVT_COMMAND_TREE_KEY_DOWN , 1)
5151EVT_TREE_ITEM_ACTIVATED = wx.PyEventBinder(wxEVT_COMMAND_TREE_ITEM_ACTIVATED , 1)
5152EVT_TREE_ITEM_RIGHT_CLICK = wx.PyEventBinder(wxEVT_COMMAND_TREE_ITEM_RIGHT_CLICK , 1)
5153EVT_TREE_ITEM_MIDDLE_CLICK = wx.PyEventBinder(wxEVT_COMMAND_TREE_ITEM_MIDDLE_CLICK, 1)
5154EVT_TREE_END_DRAG = wx.PyEventBinder(wxEVT_COMMAND_TREE_END_DRAG , 1)
5155EVT_TREE_STATE_IMAGE_CLICK = wx.PyEventBinder(wxEVT_COMMAND_TREE_STATE_IMAGE_CLICK, 1)
c9c7117a 5156EVT_TREE_ITEM_GETTOOLTIP = wx.PyEventBinder(wxEVT_COMMAND_TREE_ITEM_GETTOOLTIP, 1)
a3957d3d 5157EVT_TREE_ITEM_MENU = wx.PyEventBinder(wxEVT_COMMAND_TREE_ITEM_MENU, 1)
d14a1e28 5158
54f9ee45 5159class TreeEvent(_core.NotifyEvent):
093d3ff1 5160 """Proxy of C++ TreeEvent class"""
e811c8ce
RD
5161 def __repr__(self):
5162 return "<%s.%s; proxy of C++ wxTreeEvent instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 5163 def __init__(self, *args, **kwargs):
a95a7133 5164 """__init__(self, wxEventType commandType=wxEVT_NULL, int id=0) -> TreeEvent"""
54f9ee45 5165 newobj = _controls_.new_TreeEvent(*args, **kwargs)
d14a1e28 5166 self.this = newobj.this
f6bcfd97 5167 self.thisown = 1
d14a1e28 5168 del newobj.thisown
e811c8ce 5169 def GetItem(*args, **kwargs):
a95a7133 5170 """GetItem(self) -> TreeItemId"""
54f9ee45 5171 return _controls_.TreeEvent_GetItem(*args, **kwargs)
e811c8ce
RD
5172
5173 def SetItem(*args, **kwargs):
a95a7133 5174 """SetItem(self, TreeItemId item)"""
54f9ee45 5175 return _controls_.TreeEvent_SetItem(*args, **kwargs)
e811c8ce
RD
5176
5177 def GetOldItem(*args, **kwargs):
a95a7133 5178 """GetOldItem(self) -> TreeItemId"""
54f9ee45 5179 return _controls_.TreeEvent_GetOldItem(*args, **kwargs)
e811c8ce
RD
5180
5181 def SetOldItem(*args, **kwargs):
a95a7133 5182 """SetOldItem(self, TreeItemId item)"""
54f9ee45 5183 return _controls_.TreeEvent_SetOldItem(*args, **kwargs)
e811c8ce
RD
5184
5185 def GetPoint(*args, **kwargs):
a95a7133 5186 """GetPoint(self) -> Point"""
54f9ee45 5187 return _controls_.TreeEvent_GetPoint(*args, **kwargs)
e811c8ce
RD
5188
5189 def SetPoint(*args, **kwargs):
a95a7133 5190 """SetPoint(self, Point pt)"""
54f9ee45 5191 return _controls_.TreeEvent_SetPoint(*args, **kwargs)
e811c8ce
RD
5192
5193 def GetKeyEvent(*args, **kwargs):
a95a7133 5194 """GetKeyEvent(self) -> KeyEvent"""
54f9ee45 5195 return _controls_.TreeEvent_GetKeyEvent(*args, **kwargs)
e811c8ce
RD
5196
5197 def GetKeyCode(*args, **kwargs):
a95a7133 5198 """GetKeyCode(self) -> int"""
54f9ee45 5199 return _controls_.TreeEvent_GetKeyCode(*args, **kwargs)
e811c8ce
RD
5200
5201 def SetKeyEvent(*args, **kwargs):
a95a7133 5202 """SetKeyEvent(self, KeyEvent evt)"""
54f9ee45 5203 return _controls_.TreeEvent_SetKeyEvent(*args, **kwargs)
e811c8ce
RD
5204
5205 def GetLabel(*args, **kwargs):
a95a7133 5206 """GetLabel(self) -> String"""
54f9ee45 5207 return _controls_.TreeEvent_GetLabel(*args, **kwargs)
e811c8ce
RD
5208
5209 def SetLabel(*args, **kwargs):
a95a7133 5210 """SetLabel(self, String label)"""
54f9ee45 5211 return _controls_.TreeEvent_SetLabel(*args, **kwargs)
e811c8ce
RD
5212
5213 def IsEditCancelled(*args, **kwargs):
a95a7133 5214 """IsEditCancelled(self) -> bool"""
54f9ee45 5215 return _controls_.TreeEvent_IsEditCancelled(*args, **kwargs)
e811c8ce
RD
5216
5217 def SetEditCanceled(*args, **kwargs):
a95a7133 5218 """SetEditCanceled(self, bool editCancelled)"""
54f9ee45 5219 return _controls_.TreeEvent_SetEditCanceled(*args, **kwargs)
e811c8ce 5220
c9c7117a 5221 def SetToolTip(*args, **kwargs):
a95a7133 5222 """SetToolTip(self, String toolTip)"""
54f9ee45 5223 return _controls_.TreeEvent_SetToolTip(*args, **kwargs)
c9c7117a 5224
562ecc31
RD
5225 def GetToolTip(*args, **kwargs):
5226 """GetToolTip(self) -> String"""
5227 return _controls_.TreeEvent_GetToolTip(*args, **kwargs)
5228
d14a1e28
RD
5229
5230class TreeEventPtr(TreeEvent):
5231 def __init__(self, this):
5232 self.this = this
5233 if not hasattr(self,"thisown"): self.thisown = 0
5234 self.__class__ = TreeEvent
54f9ee45 5235_controls_.TreeEvent_swigregister(TreeEventPtr)
d14a1e28
RD
5236
5237#---------------------------------------------------------------------------
70551f47 5238
54f9ee45 5239class TreeCtrl(_core.Control):
093d3ff1 5240 """Proxy of C++ TreeCtrl class"""
e811c8ce
RD
5241 def __repr__(self):
5242 return "<%s.%s; proxy of C++ wxPyTreeCtrl instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 5243 def __init__(self, *args, **kwargs):
0df68c9f 5244 """
a95a7133 5245 __init__(self, Window parent, int id=-1, Point pos=DefaultPosition,
0df68c9f
RD
5246 Size size=DefaultSize, long style=TR_DEFAULT_STYLE,
5247 Validator validator=DefaultValidator,
b2dc1044 5248 String name=TreeCtrlNameStr) -> TreeCtrl
0df68c9f 5249 """
54f9ee45 5250 newobj = _controls_.new_TreeCtrl(*args, **kwargs)
d14a1e28
RD
5251 self.this = newobj.this
5252 self.thisown = 1
5253 del newobj.thisown
5254 self._setOORInfo(self);self._setCallbackInfo(self, TreeCtrl)
e811c8ce
RD
5255
5256 def Create(*args, **kwargs):
0df68c9f 5257 """
a95a7133 5258 Create(self, Window parent, int id=-1, Point pos=DefaultPosition,
0df68c9f
RD
5259 Size size=DefaultSize, long style=TR_DEFAULT_STYLE,
5260 Validator validator=DefaultValidator,
b2dc1044 5261 String name=TreeCtrlNameStr) -> bool
15afbcd0
RD
5262
5263 Do the 2nd phase and create the GUI control.
0df68c9f 5264 """
54f9ee45 5265 return _controls_.TreeCtrl_Create(*args, **kwargs)
e811c8ce
RD
5266
5267 def _setCallbackInfo(*args, **kwargs):
a95a7133 5268 """_setCallbackInfo(self, PyObject self, PyObject _class)"""
54f9ee45 5269 return _controls_.TreeCtrl__setCallbackInfo(*args, **kwargs)
e811c8ce
RD
5270
5271 def GetCount(*args, **kwargs):
a95a7133 5272 """GetCount(self) -> size_t"""
54f9ee45 5273 return _controls_.TreeCtrl_GetCount(*args, **kwargs)
e811c8ce
RD
5274
5275 def GetIndent(*args, **kwargs):
a95a7133 5276 """GetIndent(self) -> unsigned int"""
54f9ee45 5277 return _controls_.TreeCtrl_GetIndent(*args, **kwargs)
e811c8ce
RD
5278
5279 def SetIndent(*args, **kwargs):
a95a7133 5280 """SetIndent(self, unsigned int indent)"""
54f9ee45 5281 return _controls_.TreeCtrl_SetIndent(*args, **kwargs)
e811c8ce
RD
5282
5283 def GetSpacing(*args, **kwargs):
a95a7133 5284 """GetSpacing(self) -> unsigned int"""
54f9ee45 5285 return _controls_.TreeCtrl_GetSpacing(*args, **kwargs)
e811c8ce
RD
5286
5287 def SetSpacing(*args, **kwargs):
a95a7133 5288 """SetSpacing(self, unsigned int spacing)"""
54f9ee45 5289 return _controls_.TreeCtrl_SetSpacing(*args, **kwargs)
e811c8ce
RD
5290
5291 def GetImageList(*args, **kwargs):
a95a7133 5292 """GetImageList(self) -> ImageList"""
54f9ee45 5293 return _controls_.TreeCtrl_GetImageList(*args, **kwargs)
e811c8ce
RD
5294
5295 def GetStateImageList(*args, **kwargs):
a95a7133 5296 """GetStateImageList(self) -> ImageList"""
54f9ee45 5297 return _controls_.TreeCtrl_GetStateImageList(*args, **kwargs)
e811c8ce
RD
5298
5299 def SetImageList(*args, **kwargs):
a95a7133 5300 """SetImageList(self, ImageList imageList)"""
54f9ee45 5301 return _controls_.TreeCtrl_SetImageList(*args, **kwargs)
e811c8ce
RD
5302
5303 def SetStateImageList(*args, **kwargs):
a95a7133 5304 """SetStateImageList(self, ImageList imageList)"""
54f9ee45 5305 return _controls_.TreeCtrl_SetStateImageList(*args, **kwargs)
e811c8ce
RD
5306
5307 def AssignImageList(*args, **kwargs):
a95a7133 5308 """AssignImageList(self, ImageList imageList)"""
54f9ee45 5309 return _controls_.TreeCtrl_AssignImageList(*args, **kwargs)
e811c8ce
RD
5310
5311 def AssignStateImageList(*args, **kwargs):
a95a7133 5312 """AssignStateImageList(self, ImageList imageList)"""
54f9ee45 5313 return _controls_.TreeCtrl_AssignStateImageList(*args, **kwargs)
e811c8ce
RD
5314
5315 def GetItemText(*args, **kwargs):
a95a7133 5316 """GetItemText(self, TreeItemId item) -> String"""
54f9ee45 5317 return _controls_.TreeCtrl_GetItemText(*args, **kwargs)
e811c8ce
RD
5318
5319 def GetItemImage(*args, **kwargs):
a95a7133 5320 """GetItemImage(self, TreeItemId item, int which=TreeItemIcon_Normal) -> int"""
54f9ee45 5321 return _controls_.TreeCtrl_GetItemImage(*args, **kwargs)
e811c8ce
RD
5322
5323 def GetItemData(*args, **kwargs):
a95a7133 5324 """GetItemData(self, TreeItemId item) -> TreeItemData"""
54f9ee45 5325 return _controls_.TreeCtrl_GetItemData(*args, **kwargs)
e811c8ce
RD
5326
5327 def GetItemPyData(*args, **kwargs):
a95a7133 5328 """GetItemPyData(self, TreeItemId item) -> PyObject"""
54f9ee45 5329 return _controls_.TreeCtrl_GetItemPyData(*args, **kwargs)
e811c8ce 5330
d14a1e28 5331 GetPyData = GetItemPyData
e811c8ce 5332 def GetItemTextColour(*args, **kwargs):
a95a7133 5333 """GetItemTextColour(self, TreeItemId item) -> Colour"""
54f9ee45 5334 return _controls_.TreeCtrl_GetItemTextColour(*args, **kwargs)
e811c8ce
RD
5335
5336 def GetItemBackgroundColour(*args, **kwargs):
a95a7133 5337 """GetItemBackgroundColour(self, TreeItemId item) -> Colour"""
54f9ee45 5338 return _controls_.TreeCtrl_GetItemBackgroundColour(*args, **kwargs)
e811c8ce
RD
5339
5340 def GetItemFont(*args, **kwargs):
a95a7133 5341 """GetItemFont(self, TreeItemId item) -> Font"""
54f9ee45 5342 return _controls_.TreeCtrl_GetItemFont(*args, **kwargs)
e811c8ce
RD
5343
5344 def SetItemText(*args, **kwargs):
a95a7133 5345 """SetItemText(self, TreeItemId item, String text)"""
54f9ee45 5346 return _controls_.TreeCtrl_SetItemText(*args, **kwargs)
e811c8ce
RD
5347
5348 def SetItemImage(*args, **kwargs):
a95a7133 5349 """SetItemImage(self, TreeItemId item, int image, int which=TreeItemIcon_Normal)"""
54f9ee45 5350 return _controls_.TreeCtrl_SetItemImage(*args, **kwargs)
e811c8ce
RD
5351
5352 def SetItemData(*args, **kwargs):
a95a7133 5353 """SetItemData(self, TreeItemId item, TreeItemData data)"""
54f9ee45 5354 return _controls_.TreeCtrl_SetItemData(*args, **kwargs)
e811c8ce
RD
5355
5356 def SetItemPyData(*args, **kwargs):
a95a7133 5357 """SetItemPyData(self, TreeItemId item, PyObject obj)"""
54f9ee45 5358 return _controls_.TreeCtrl_SetItemPyData(*args, **kwargs)
e811c8ce 5359
d14a1e28 5360 SetPyData = SetItemPyData
e811c8ce 5361 def SetItemHasChildren(*args, **kwargs):
a95a7133 5362 """SetItemHasChildren(self, TreeItemId item, bool has=True)"""
54f9ee45 5363 return _controls_.TreeCtrl_SetItemHasChildren(*args, **kwargs)
e811c8ce
RD
5364
5365 def SetItemBold(*args, **kwargs):
a95a7133 5366 """SetItemBold(self, TreeItemId item, bool bold=True)"""
54f9ee45 5367 return _controls_.TreeCtrl_SetItemBold(*args, **kwargs)
e811c8ce 5368
fef4c27a
RD
5369 def SetItemDropHighlight(*args, **kwargs):
5370 """SetItemDropHighlight(self, TreeItemId item, bool highlight=True)"""
5371 return _controls_.TreeCtrl_SetItemDropHighlight(*args, **kwargs)
5372
e811c8ce 5373 def SetItemTextColour(*args, **kwargs):
a95a7133 5374 """SetItemTextColour(self, TreeItemId item, Colour col)"""
54f9ee45 5375 return _controls_.TreeCtrl_SetItemTextColour(*args, **kwargs)
e811c8ce
RD
5376
5377 def SetItemBackgroundColour(*args, **kwargs):
a95a7133 5378 """SetItemBackgroundColour(self, TreeItemId item, Colour col)"""
54f9ee45 5379 return _controls_.TreeCtrl_SetItemBackgroundColour(*args, **kwargs)
e811c8ce
RD
5380
5381 def SetItemFont(*args, **kwargs):
a95a7133 5382 """SetItemFont(self, TreeItemId item, Font font)"""
54f9ee45 5383 return _controls_.TreeCtrl_SetItemFont(*args, **kwargs)
e811c8ce
RD
5384
5385 def IsVisible(*args, **kwargs):
a95a7133 5386 """IsVisible(self, TreeItemId item) -> bool"""
54f9ee45 5387 return _controls_.TreeCtrl_IsVisible(*args, **kwargs)
e811c8ce
RD
5388
5389 def ItemHasChildren(*args, **kwargs):
a95a7133 5390 """ItemHasChildren(self, TreeItemId item) -> bool"""
54f9ee45 5391 return _controls_.TreeCtrl_ItemHasChildren(*args, **kwargs)
e811c8ce
RD
5392
5393 def IsExpanded(*args, **kwargs):
a95a7133 5394 """IsExpanded(self, TreeItemId item) -> bool"""
54f9ee45 5395 return _controls_.TreeCtrl_IsExpanded(*args, **kwargs)
e811c8ce
RD
5396
5397 def IsSelected(*args, **kwargs):
a95a7133 5398 """IsSelected(self, TreeItemId item) -> bool"""
54f9ee45 5399 return _controls_.TreeCtrl_IsSelected(*args, **kwargs)
e811c8ce
RD
5400
5401 def IsBold(*args, **kwargs):
a95a7133 5402 """IsBold(self, TreeItemId item) -> bool"""
54f9ee45 5403 return _controls_.TreeCtrl_IsBold(*args, **kwargs)
e811c8ce
RD
5404
5405 def GetChildrenCount(*args, **kwargs):
a95a7133 5406 """GetChildrenCount(self, TreeItemId item, bool recursively=True) -> size_t"""
54f9ee45 5407 return _controls_.TreeCtrl_GetChildrenCount(*args, **kwargs)
e811c8ce
RD
5408
5409 def GetRootItem(*args, **kwargs):
a95a7133 5410 """GetRootItem(self) -> TreeItemId"""
54f9ee45 5411 return _controls_.TreeCtrl_GetRootItem(*args, **kwargs)
e811c8ce
RD
5412
5413 def GetSelection(*args, **kwargs):
a95a7133 5414 """GetSelection(self) -> TreeItemId"""
54f9ee45 5415 return _controls_.TreeCtrl_GetSelection(*args, **kwargs)
e811c8ce
RD
5416
5417 def GetSelections(*args, **kwargs):
a95a7133 5418 """GetSelections(self) -> PyObject"""
54f9ee45 5419 return _controls_.TreeCtrl_GetSelections(*args, **kwargs)
e811c8ce
RD
5420
5421 def GetItemParent(*args, **kwargs):
a95a7133 5422 """GetItemParent(self, TreeItemId item) -> TreeItemId"""
54f9ee45 5423 return _controls_.TreeCtrl_GetItemParent(*args, **kwargs)
e811c8ce
RD
5424
5425 def GetFirstChild(*args, **kwargs):
a95a7133 5426 """GetFirstChild(self, TreeItemId item) -> PyObject"""
54f9ee45 5427 return _controls_.TreeCtrl_GetFirstChild(*args, **kwargs)
e811c8ce
RD
5428
5429 def GetNextChild(*args, **kwargs):
a95a7133 5430 """GetNextChild(self, TreeItemId item, void cookie) -> PyObject"""
54f9ee45 5431 return _controls_.TreeCtrl_GetNextChild(*args, **kwargs)
e811c8ce
RD
5432
5433 def GetLastChild(*args, **kwargs):
a95a7133 5434 """GetLastChild(self, TreeItemId item) -> TreeItemId"""
54f9ee45 5435 return _controls_.TreeCtrl_GetLastChild(*args, **kwargs)
e811c8ce
RD
5436
5437 def GetNextSibling(*args, **kwargs):
a95a7133 5438 """GetNextSibling(self, TreeItemId item) -> TreeItemId"""
54f9ee45 5439 return _controls_.TreeCtrl_GetNextSibling(*args, **kwargs)
e811c8ce
RD
5440
5441 def GetPrevSibling(*args, **kwargs):
a95a7133 5442 """GetPrevSibling(self, TreeItemId item) -> TreeItemId"""
54f9ee45 5443 return _controls_.TreeCtrl_GetPrevSibling(*args, **kwargs)
e811c8ce
RD
5444
5445 def GetFirstVisibleItem(*args, **kwargs):
a95a7133 5446 """GetFirstVisibleItem(self) -> TreeItemId"""
54f9ee45 5447 return _controls_.TreeCtrl_GetFirstVisibleItem(*args, **kwargs)
e811c8ce
RD
5448
5449 def GetNextVisible(*args, **kwargs):
a95a7133 5450 """GetNextVisible(self, TreeItemId item) -> TreeItemId"""
54f9ee45 5451 return _controls_.TreeCtrl_GetNextVisible(*args, **kwargs)
e811c8ce
RD
5452
5453 def GetPrevVisible(*args, **kwargs):
a95a7133 5454 """GetPrevVisible(self, TreeItemId item) -> TreeItemId"""
54f9ee45 5455 return _controls_.TreeCtrl_GetPrevVisible(*args, **kwargs)
e811c8ce
RD
5456
5457 def AddRoot(*args, **kwargs):
a95a7133 5458 """AddRoot(self, String text, int image=-1, int selectedImage=-1, TreeItemData data=None) -> TreeItemId"""
54f9ee45 5459 return _controls_.TreeCtrl_AddRoot(*args, **kwargs)
e811c8ce
RD
5460
5461 def PrependItem(*args, **kwargs):
0df68c9f 5462 """
a95a7133 5463 PrependItem(self, TreeItemId parent, String text, int image=-1, int selectedImage=-1,
0df68c9f
RD
5464 TreeItemData data=None) -> TreeItemId
5465 """
54f9ee45 5466 return _controls_.TreeCtrl_PrependItem(*args, **kwargs)
e811c8ce
RD
5467
5468 def InsertItem(*args, **kwargs):
0df68c9f 5469 """
a95a7133 5470 InsertItem(self, TreeItemId parent, TreeItemId idPrevious, String text,
0df68c9f
RD
5471 int image=-1, int selectedImage=-1, TreeItemData data=None) -> TreeItemId
5472 """
54f9ee45 5473 return _controls_.TreeCtrl_InsertItem(*args, **kwargs)
e811c8ce
RD
5474
5475 def InsertItemBefore(*args, **kwargs):
0df68c9f 5476 """
a95a7133 5477 InsertItemBefore(self, TreeItemId parent, size_t index, String text, int image=-1,
0df68c9f
RD
5478 int selectedImage=-1, TreeItemData data=None) -> TreeItemId
5479 """
54f9ee45 5480 return _controls_.TreeCtrl_InsertItemBefore(*args, **kwargs)
e811c8ce
RD
5481
5482 def AppendItem(*args, **kwargs):
0df68c9f 5483 """
a95a7133 5484 AppendItem(self, TreeItemId parent, String text, int image=-1, int selectedImage=-1,
0df68c9f
RD
5485 TreeItemData data=None) -> TreeItemId
5486 """
54f9ee45 5487 return _controls_.TreeCtrl_AppendItem(*args, **kwargs)
e811c8ce
RD
5488
5489 def Delete(*args, **kwargs):
a95a7133 5490 """Delete(self, TreeItemId item)"""
54f9ee45 5491 return _controls_.TreeCtrl_Delete(*args, **kwargs)
e811c8ce
RD
5492
5493 def DeleteChildren(*args, **kwargs):
a95a7133 5494 """DeleteChildren(self, TreeItemId item)"""
54f9ee45 5495 return _controls_.TreeCtrl_DeleteChildren(*args, **kwargs)
e811c8ce
RD
5496
5497 def DeleteAllItems(*args, **kwargs):
a95a7133 5498 """DeleteAllItems(self)"""
54f9ee45 5499 return _controls_.TreeCtrl_DeleteAllItems(*args, **kwargs)
e811c8ce
RD
5500
5501 def Expand(*args, **kwargs):
a95a7133 5502 """Expand(self, TreeItemId item)"""
54f9ee45 5503 return _controls_.TreeCtrl_Expand(*args, **kwargs)
e811c8ce
RD
5504
5505 def Collapse(*args, **kwargs):
a95a7133 5506 """Collapse(self, TreeItemId item)"""
54f9ee45 5507 return _controls_.TreeCtrl_Collapse(*args, **kwargs)
e811c8ce
RD
5508
5509 def CollapseAndReset(*args, **kwargs):
a95a7133 5510 """CollapseAndReset(self, TreeItemId item)"""
54f9ee45 5511 return _controls_.TreeCtrl_CollapseAndReset(*args, **kwargs)
e811c8ce
RD
5512
5513 def Toggle(*args, **kwargs):
a95a7133 5514 """Toggle(self, TreeItemId item)"""
54f9ee45 5515 return _controls_.TreeCtrl_Toggle(*args, **kwargs)
e811c8ce
RD
5516
5517 def Unselect(*args, **kwargs):
a95a7133 5518 """Unselect(self)"""
54f9ee45 5519 return _controls_.TreeCtrl_Unselect(*args, **kwargs)
e811c8ce 5520
3adfb63b 5521 def UnselectItem(*args, **kwargs):
a95a7133 5522 """UnselectItem(self, TreeItemId item)"""
54f9ee45 5523 return _controls_.TreeCtrl_UnselectItem(*args, **kwargs)
3adfb63b 5524
e811c8ce 5525 def UnselectAll(*args, **kwargs):
a95a7133 5526 """UnselectAll(self)"""
54f9ee45 5527 return _controls_.TreeCtrl_UnselectAll(*args, **kwargs)
e811c8ce
RD
5528
5529 def SelectItem(*args, **kwargs):
a95a7133 5530 """SelectItem(self, TreeItemId item, bool select=True)"""
54f9ee45 5531 return _controls_.TreeCtrl_SelectItem(*args, **kwargs)
3adfb63b
RD
5532
5533 def ToggleItemSelection(*args, **kwargs):
a95a7133 5534 """ToggleItemSelection(self, TreeItemId item)"""
54f9ee45 5535 return _controls_.TreeCtrl_ToggleItemSelection(*args, **kwargs)
e811c8ce
RD
5536
5537 def EnsureVisible(*args, **kwargs):
a95a7133 5538 """EnsureVisible(self, TreeItemId item)"""
54f9ee45 5539 return _controls_.TreeCtrl_EnsureVisible(*args, **kwargs)
e811c8ce
RD
5540
5541 def ScrollTo(*args, **kwargs):
a95a7133 5542 """ScrollTo(self, TreeItemId item)"""
54f9ee45 5543 return _controls_.TreeCtrl_ScrollTo(*args, **kwargs)
e811c8ce
RD
5544
5545 def EditLabel(*args, **kwargs):
a95a7133 5546 """EditLabel(self, TreeItemId item)"""
54f9ee45 5547 return _controls_.TreeCtrl_EditLabel(*args, **kwargs)
e811c8ce
RD
5548
5549 def GetEditControl(*args, **kwargs):
a95a7133 5550 """GetEditControl(self) -> TextCtrl"""
54f9ee45 5551 return _controls_.TreeCtrl_GetEditControl(*args, **kwargs)
e811c8ce
RD
5552
5553 def SortChildren(*args, **kwargs):
a95a7133 5554 """SortChildren(self, TreeItemId item)"""
54f9ee45 5555 return _controls_.TreeCtrl_SortChildren(*args, **kwargs)
e811c8ce
RD
5556
5557 def HitTest(*args, **kwargs):
fd2dc343
RD
5558 """
5559 HitTest(Point point) -> (item, where)
5560
5561 Determine which item (if any) belongs the given point. The coordinates
5562 specified are relative to the client area of tree ctrl and the where return
5563 value is set to a bitmask of wxTREE_HITTEST_xxx constants.
5564
5565 """
54f9ee45 5566 return _controls_.TreeCtrl_HitTest(*args, **kwargs)
e811c8ce
RD
5567
5568 def GetBoundingRect(*args, **kwargs):
a95a7133 5569 """GetBoundingRect(self, TreeItemId item, bool textOnly=False) -> PyObject"""
54f9ee45 5570 return _controls_.TreeCtrl_GetBoundingRect(*args, **kwargs)
e811c8ce 5571
74a57fcd 5572 def GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
5573 """
5574 GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
5575
5576 Get the default attributes for this class. This is useful if you want
5577 to use the same font or colour in your own control as in a standard
5578 control -- which is a much better idea than hard coding specific
5579 colours or fonts which might look completely out of place on the
5580 user's system, especially if it uses themes.
5581
5582 The variant parameter is only relevant under Mac currently and is
5583 ignore under other platforms. Under Mac, it will change the size of
5584 the returned font. See `wx.Window.SetWindowVariant` for more about
5585 this.
5586 """
54f9ee45 5587 return _controls_.TreeCtrl_GetClassDefaultAttributes(*args, **kwargs)
74a57fcd
RD
5588
5589 GetClassDefaultAttributes = staticmethod(GetClassDefaultAttributes)
70551f47 5590
d14a1e28
RD
5591class TreeCtrlPtr(TreeCtrl):
5592 def __init__(self, this):
5593 self.this = this
5594 if not hasattr(self,"thisown"): self.thisown = 0
5595 self.__class__ = TreeCtrl
54f9ee45 5596_controls_.TreeCtrl_swigregister(TreeCtrlPtr)
70551f47 5597
d14a1e28 5598def PreTreeCtrl(*args, **kwargs):
e811c8ce 5599 """PreTreeCtrl() -> TreeCtrl"""
54f9ee45 5600 val = _controls_.new_PreTreeCtrl(*args, **kwargs)
aa2a5b86
RD
5601 val.thisown = 1
5602 return val
5603
74a57fcd 5604def TreeCtrl_GetClassDefaultAttributes(*args, **kwargs):
110da5b0
RD
5605 """
5606 TreeCtrl_GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
5607
5608 Get the default attributes for this class. This is useful if you want
5609 to use the same font or colour in your own control as in a standard
5610 control -- which is a much better idea than hard coding specific
5611 colours or fonts which might look completely out of place on the
5612 user's system, especially if it uses themes.
5613
5614 The variant parameter is only relevant under Mac currently and is
5615 ignore under other platforms. Under Mac, it will change the size of
5616 the returned font. See `wx.Window.SetWindowVariant` for more about
5617 this.
5618 """
54f9ee45 5619 return _controls_.TreeCtrl_GetClassDefaultAttributes(*args, **kwargs)
74a57fcd 5620
d14a1e28
RD
5621#---------------------------------------------------------------------------
5622
54f9ee45
RD
5623DIRCTRL_DIR_ONLY = _controls_.DIRCTRL_DIR_ONLY
5624DIRCTRL_SELECT_FIRST = _controls_.DIRCTRL_SELECT_FIRST
5625DIRCTRL_SHOW_FILTERS = _controls_.DIRCTRL_SHOW_FILTERS
5626DIRCTRL_3D_INTERNAL = _controls_.DIRCTRL_3D_INTERNAL
5627DIRCTRL_EDIT_LABELS = _controls_.DIRCTRL_EDIT_LABELS
5628class GenericDirCtrl(_core.Control):
093d3ff1 5629 """Proxy of C++ GenericDirCtrl class"""
e811c8ce
RD
5630 def __repr__(self):
5631 return "<%s.%s; proxy of C++ wxGenericDirCtrl instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 5632 def __init__(self, *args, **kwargs):
0df68c9f 5633 """
a95a7133 5634 __init__(self, Window parent, int id=-1, String dir=DirDialogDefaultFolderStr,
196addbf
RD
5635 Point pos=DefaultPosition, Size size=DefaultSize,
5636 long style=wxDIRCTRL_3D_INTERNAL|wxSUNKEN_BORDER,
5637 String filter=EmptyString,
b2dc1044 5638 int defaultFilter=0, String name=TreeCtrlNameStr) -> GenericDirCtrl
0df68c9f 5639 """
54f9ee45 5640 newobj = _controls_.new_GenericDirCtrl(*args, **kwargs)
d14a1e28
RD
5641 self.this = newobj.this
5642 self.thisown = 1
5643 del newobj.thisown
5644 self._setOORInfo(self)
e811c8ce
RD
5645
5646 def Create(*args, **kwargs):
0df68c9f 5647 """
a95a7133 5648 Create(self, Window parent, int id=-1, String dir=DirDialogDefaultFolderStr,
196addbf
RD
5649 Point pos=DefaultPosition, Size size=DefaultSize,
5650 long style=wxDIRCTRL_3D_INTERNAL|wxSUNKEN_BORDER,
5651 String filter=EmptyString,
b2dc1044 5652 int defaultFilter=0, String name=TreeCtrlNameStr) -> bool
0df68c9f 5653 """
54f9ee45 5654 return _controls_.GenericDirCtrl_Create(*args, **kwargs)
e811c8ce
RD
5655
5656 def ExpandPath(*args, **kwargs):
a95a7133 5657 """ExpandPath(self, String path) -> bool"""
54f9ee45 5658 return _controls_.GenericDirCtrl_ExpandPath(*args, **kwargs)
e811c8ce
RD
5659
5660 def GetDefaultPath(*args, **kwargs):
a95a7133 5661 """GetDefaultPath(self) -> String"""
54f9ee45 5662 return _controls_.GenericDirCtrl_GetDefaultPath(*args, **kwargs)
e811c8ce
RD
5663
5664 def SetDefaultPath(*args, **kwargs):
a95a7133 5665 """SetDefaultPath(self, String path)"""
54f9ee45 5666 return _controls_.GenericDirCtrl_SetDefaultPath(*args, **kwargs)
e811c8ce
RD
5667
5668 def GetPath(*args, **kwargs):
a95a7133 5669 """GetPath(self) -> String"""
54f9ee45 5670 return _controls_.GenericDirCtrl_GetPath(*args, **kwargs)
e811c8ce
RD
5671
5672 def GetFilePath(*args, **kwargs):
a95a7133 5673 """GetFilePath(self) -> String"""
54f9ee45 5674 return _controls_.GenericDirCtrl_GetFilePath(*args, **kwargs)
e811c8ce
RD
5675
5676 def SetPath(*args, **kwargs):
a95a7133 5677 """SetPath(self, String path)"""
54f9ee45 5678 return _controls_.GenericDirCtrl_SetPath(*args, **kwargs)
e811c8ce
RD
5679
5680 def ShowHidden(*args, **kwargs):
a95a7133 5681 """ShowHidden(self, bool show)"""
54f9ee45 5682 return _controls_.GenericDirCtrl_ShowHidden(*args, **kwargs)
e811c8ce
RD
5683
5684 def GetShowHidden(*args, **kwargs):
a95a7133 5685 """GetShowHidden(self) -> bool"""
54f9ee45 5686 return _controls_.GenericDirCtrl_GetShowHidden(*args, **kwargs)
e811c8ce
RD
5687
5688 def GetFilter(*args, **kwargs):
a95a7133 5689 """GetFilter(self) -> String"""
54f9ee45 5690 return _controls_.GenericDirCtrl_GetFilter(*args, **kwargs)
e811c8ce
RD
5691
5692 def SetFilter(*args, **kwargs):
a95a7133 5693 """SetFilter(self, String filter)"""
54f9ee45 5694 return _controls_.GenericDirCtrl_SetFilter(*args, **kwargs)
e811c8ce
RD
5695
5696 def GetFilterIndex(*args, **kwargs):
a95a7133 5697 """GetFilterIndex(self) -> int"""
54f9ee45 5698 return _controls_.GenericDirCtrl_GetFilterIndex(*args, **kwargs)
e811c8ce
RD
5699
5700 def SetFilterIndex(*args, **kwargs):
a95a7133 5701 """SetFilterIndex(self, int n)"""
54f9ee45 5702 return _controls_.GenericDirCtrl_SetFilterIndex(*args, **kwargs)
e811c8ce
RD
5703
5704 def GetRootId(*args, **kwargs):
a95a7133 5705 """GetRootId(self) -> TreeItemId"""
54f9ee45 5706 return _controls_.GenericDirCtrl_GetRootId(*args, **kwargs)
e811c8ce
RD
5707
5708 def GetTreeCtrl(*args, **kwargs):
a95a7133 5709 """GetTreeCtrl(self) -> TreeCtrl"""
54f9ee45 5710 return _controls_.GenericDirCtrl_GetTreeCtrl(*args, **kwargs)
e811c8ce
RD
5711
5712 def GetFilterListCtrl(*args, **kwargs):
a95a7133 5713 """GetFilterListCtrl(self) -> DirFilterListCtrl"""
54f9ee45 5714 return _controls_.GenericDirCtrl_GetFilterListCtrl(*args, **kwargs)
e811c8ce
RD
5715
5716 def FindChild(*args, **kwargs):
fd2dc343
RD
5717 """
5718 FindChild(wxTreeItemId parentId, wxString path) -> (item, done)
5719
5720 Find the child that matches the first part of 'path'. E.g. if a child
5721 path is "/usr" and 'path' is "/usr/include" then the child for
5722 /usr is returned. If the path string has been used (we're at the
5723 leaf), done is set to True.
5724
5725 """
54f9ee45 5726 return _controls_.GenericDirCtrl_FindChild(*args, **kwargs)
e811c8ce
RD
5727
5728 def DoResize(*args, **kwargs):
a95a7133 5729 """DoResize(self)"""
54f9ee45 5730 return _controls_.GenericDirCtrl_DoResize(*args, **kwargs)
e811c8ce
RD
5731
5732 def ReCreateTree(*args, **kwargs):
a95a7133 5733 """ReCreateTree(self)"""
54f9ee45 5734 return _controls_.GenericDirCtrl_ReCreateTree(*args, **kwargs)
e811c8ce 5735
70551f47 5736
d14a1e28
RD
5737class GenericDirCtrlPtr(GenericDirCtrl):
5738 def __init__(self, this):
7a446686 5739 self.this = this
d14a1e28
RD
5740 if not hasattr(self,"thisown"): self.thisown = 0
5741 self.__class__ = GenericDirCtrl
54f9ee45 5742_controls_.GenericDirCtrl_swigregister(GenericDirCtrlPtr)
b2dc1044 5743DirDialogDefaultFolderStr = cvar.DirDialogDefaultFolderStr
d14a1e28
RD
5744
5745def PreGenericDirCtrl(*args, **kwargs):
e811c8ce 5746 """PreGenericDirCtrl() -> GenericDirCtrl"""
54f9ee45 5747 val = _controls_.new_PreGenericDirCtrl(*args, **kwargs)
d14a1e28
RD
5748 val.thisown = 1
5749 return val
5750
5751class DirFilterListCtrl(Choice):
093d3ff1 5752 """Proxy of C++ DirFilterListCtrl class"""
e811c8ce
RD
5753 def __repr__(self):
5754 return "<%s.%s; proxy of C++ wxDirFilterListCtrl instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 5755 def __init__(self, *args, **kwargs):
0df68c9f 5756 """
a95a7133 5757 __init__(self, GenericDirCtrl parent, int id=-1, Point pos=DefaultPosition,
0df68c9f
RD
5758 Size size=DefaultSize, long style=0) -> DirFilterListCtrl
5759 """
54f9ee45 5760 newobj = _controls_.new_DirFilterListCtrl(*args, **kwargs)
d14a1e28 5761 self.this = newobj.this
7a446686 5762 self.thisown = 1
d14a1e28 5763 del newobj.thisown
0220cbc1 5764 self._setOORInfo(self)
e811c8ce
RD
5765
5766 def Create(*args, **kwargs):
0df68c9f 5767 """
a95a7133 5768 Create(self, GenericDirCtrl parent, int id=-1, Point pos=DefaultPosition,
0df68c9f
RD
5769 Size size=DefaultSize, long style=0) -> bool
5770 """
54f9ee45 5771 return _controls_.DirFilterListCtrl_Create(*args, **kwargs)
e811c8ce
RD
5772
5773 def FillFilterList(*args, **kwargs):
a95a7133 5774 """FillFilterList(self, String filter, int defaultFilter)"""
54f9ee45 5775 return _controls_.DirFilterListCtrl_FillFilterList(*args, **kwargs)
e811c8ce 5776
7a446686 5777
d14a1e28
RD
5778class DirFilterListCtrlPtr(DirFilterListCtrl):
5779 def __init__(self, this):
5780 self.this = this
5781 if not hasattr(self,"thisown"): self.thisown = 0
5782 self.__class__ = DirFilterListCtrl
54f9ee45 5783_controls_.DirFilterListCtrl_swigregister(DirFilterListCtrlPtr)
7a446686 5784
d14a1e28 5785def PreDirFilterListCtrl(*args, **kwargs):
e811c8ce 5786 """PreDirFilterListCtrl() -> DirFilterListCtrl"""
54f9ee45 5787 val = _controls_.new_PreDirFilterListCtrl(*args, **kwargs)
aa2a5b86
RD
5788 val.thisown = 1
5789 return val
5790
d14a1e28 5791#---------------------------------------------------------------------------
7a446686 5792
54f9ee45 5793class PyControl(_core.Control):
093d3ff1 5794 """Proxy of C++ PyControl class"""
e811c8ce
RD
5795 def __repr__(self):
5796 return "<%s.%s; proxy of C++ wxPyControl instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 5797 def __init__(self, *args, **kwargs):
0df68c9f 5798 """
248ed943
RD
5799 __init__(self, Window parent, int id=-1, Point pos=DefaultPosition,
5800 Size size=DefaultSize, long style=0, Validator validator=DefaultValidator,
b2dc1044 5801 String name=ControlNameStr) -> PyControl
0df68c9f 5802 """
54f9ee45 5803 newobj = _controls_.new_PyControl(*args, **kwargs)
d14a1e28
RD
5804 self.this = newobj.this
5805 self.thisown = 1
5806 del newobj.thisown
5807 self._setOORInfo(self); self._setCallbackInfo(self, PyControl)
e811c8ce
RD
5808
5809 def _setCallbackInfo(*args, **kwargs):
a95a7133 5810 """_setCallbackInfo(self, PyObject self, PyObject _class)"""
54f9ee45 5811 return _controls_.PyControl__setCallbackInfo(*args, **kwargs)
e811c8ce 5812
db3e571a
RD
5813 def SetBestSize(*args, **kwargs):
5814 """SetBestSize(self, Size size)"""
5815 return _controls_.PyControl_SetBestSize(*args, **kwargs)
5816
e811c8ce 5817 def base_DoMoveWindow(*args, **kwargs):
a95a7133 5818 """base_DoMoveWindow(self, int x, int y, int width, int height)"""
54f9ee45 5819 return _controls_.PyControl_base_DoMoveWindow(*args, **kwargs)
e811c8ce
RD
5820
5821 def base_DoSetSize(*args, **kwargs):
a95a7133 5822 """base_DoSetSize(self, int x, int y, int width, int height, int sizeFlags=SIZE_AUTO)"""
54f9ee45 5823 return _controls_.PyControl_base_DoSetSize(*args, **kwargs)
e811c8ce
RD
5824
5825 def base_DoSetClientSize(*args, **kwargs):
a95a7133 5826 """base_DoSetClientSize(self, int width, int height)"""
54f9ee45 5827 return _controls_.PyControl_base_DoSetClientSize(*args, **kwargs)
e811c8ce
RD
5828
5829 def base_DoSetVirtualSize(*args, **kwargs):
a95a7133 5830 """base_DoSetVirtualSize(self, int x, int y)"""
54f9ee45 5831 return _controls_.PyControl_base_DoSetVirtualSize(*args, **kwargs)
e811c8ce
RD
5832
5833 def base_DoGetSize(*args, **kwargs):
322913ce 5834 """base_DoGetSize() -> (width, height)"""
54f9ee45 5835 return _controls_.PyControl_base_DoGetSize(*args, **kwargs)
e811c8ce
RD
5836
5837 def base_DoGetClientSize(*args, **kwargs):
322913ce 5838 """base_DoGetClientSize() -> (width, height)"""
54f9ee45 5839 return _controls_.PyControl_base_DoGetClientSize(*args, **kwargs)
e811c8ce
RD
5840
5841 def base_DoGetPosition(*args, **kwargs):
322913ce 5842 """base_DoGetPosition() -> (x,y)"""
54f9ee45 5843 return _controls_.PyControl_base_DoGetPosition(*args, **kwargs)
e811c8ce
RD
5844
5845 def base_DoGetVirtualSize(*args, **kwargs):
a95a7133 5846 """base_DoGetVirtualSize(self) -> Size"""
54f9ee45 5847 return _controls_.PyControl_base_DoGetVirtualSize(*args, **kwargs)
e811c8ce
RD
5848
5849 def base_DoGetBestSize(*args, **kwargs):
a95a7133 5850 """base_DoGetBestSize(self) -> Size"""
54f9ee45 5851 return _controls_.PyControl_base_DoGetBestSize(*args, **kwargs)
e811c8ce
RD
5852
5853 def base_InitDialog(*args, **kwargs):
a95a7133 5854 """base_InitDialog(self)"""
54f9ee45 5855 return _controls_.PyControl_base_InitDialog(*args, **kwargs)
e811c8ce
RD
5856
5857 def base_TransferDataToWindow(*args, **kwargs):
a95a7133 5858 """base_TransferDataToWindow(self) -> bool"""
54f9ee45 5859 return _controls_.PyControl_base_TransferDataToWindow(*args, **kwargs)
e811c8ce
RD
5860
5861 def base_TransferDataFromWindow(*args, **kwargs):
a95a7133 5862 """base_TransferDataFromWindow(self) -> bool"""
54f9ee45 5863 return _controls_.PyControl_base_TransferDataFromWindow(*args, **kwargs)
e811c8ce
RD
5864
5865 def base_Validate(*args, **kwargs):
a95a7133 5866 """base_Validate(self) -> bool"""
54f9ee45 5867 return _controls_.PyControl_base_Validate(*args, **kwargs)
e811c8ce
RD
5868
5869 def base_AcceptsFocus(*args, **kwargs):
a95a7133 5870 """base_AcceptsFocus(self) -> bool"""
54f9ee45 5871 return _controls_.PyControl_base_AcceptsFocus(*args, **kwargs)
e811c8ce
RD
5872
5873 def base_AcceptsFocusFromKeyboard(*args, **kwargs):
a95a7133 5874 """base_AcceptsFocusFromKeyboard(self) -> bool"""
54f9ee45 5875 return _controls_.PyControl_base_AcceptsFocusFromKeyboard(*args, **kwargs)
e811c8ce
RD
5876
5877 def base_GetMaxSize(*args, **kwargs):
a95a7133 5878 """base_GetMaxSize(self) -> Size"""
54f9ee45 5879 return _controls_.PyControl_base_GetMaxSize(*args, **kwargs)
e811c8ce
RD
5880
5881 def base_AddChild(*args, **kwargs):
a95a7133 5882 """base_AddChild(self, Window child)"""
54f9ee45 5883 return _controls_.PyControl_base_AddChild(*args, **kwargs)
e811c8ce
RD
5884
5885 def base_RemoveChild(*args, **kwargs):
a95a7133 5886 """base_RemoveChild(self, Window child)"""
54f9ee45 5887 return _controls_.PyControl_base_RemoveChild(*args, **kwargs)
e811c8ce 5888
1cb4a8aa 5889 def base_ShouldInheritColours(*args, **kwargs):
a95a7133 5890 """base_ShouldInheritColours(self) -> bool"""
54f9ee45 5891 return _controls_.PyControl_base_ShouldInheritColours(*args, **kwargs)
1cb4a8aa 5892
db3e571a
RD
5893 def base_GetDefaultAttributes(*args, **kwargs):
5894 """base_GetDefaultAttributes(self) -> VisualAttributes"""
5895 return _controls_.PyControl_base_GetDefaultAttributes(*args, **kwargs)
5896
70551f47 5897
d14a1e28
RD
5898class PyControlPtr(PyControl):
5899 def __init__(self, this):
5900 self.this = this
5901 if not hasattr(self,"thisown"): self.thisown = 0
5902 self.__class__ = PyControl
54f9ee45 5903_controls_.PyControl_swigregister(PyControlPtr)
d14a1e28 5904
1cb4a8aa
RD
5905def PrePyControl(*args, **kwargs):
5906 """PrePyControl() -> PyControl"""
54f9ee45 5907 val = _controls_.new_PrePyControl(*args, **kwargs)
1cb4a8aa
RD
5908 val.thisown = 1
5909 return val
5910
d14a1e28
RD
5911#---------------------------------------------------------------------------
5912
54f9ee45
RD
5913FRAME_EX_CONTEXTHELP = _controls_.FRAME_EX_CONTEXTHELP
5914DIALOG_EX_CONTEXTHELP = _controls_.DIALOG_EX_CONTEXTHELP
5915wxEVT_HELP = _controls_.wxEVT_HELP
5916wxEVT_DETAILED_HELP = _controls_.wxEVT_DETAILED_HELP
d14a1e28
RD
5917EVT_HELP = wx.PyEventBinder( wxEVT_HELP, 1)
5918EVT_HELP_RANGE = wx.PyEventBinder( wxEVT_HELP, 2)
5919EVT_DETAILED_HELP = wx.PyEventBinder( wxEVT_DETAILED_HELP, 1)
5920EVT_DETAILED_HELP_RANGE = wx.PyEventBinder( wxEVT_DETAILED_HELP, 2)
5921
54f9ee45 5922class HelpEvent(_core.CommandEvent):
15afbcd0 5923 """
41e2b43e
RD
5924 A help event is sent when the user has requested context-sensitive
5925 help. This can either be caused by the application requesting
5926 context-sensitive help mode via wx.ContextHelp, or (on MS Windows) by
5927 the system generating a WM_HELP message when the user pressed F1 or
5928 clicked on the query button in a dialog caption.
5929
5930 A help event is sent to the window that the user clicked on, and is
5931 propagated up the window hierarchy until the event is processed or
5932 there are no more event handlers. The application should call
5933 event.GetId to check the identity of the clicked-on window, and then
5934 either show some suitable help or call event.Skip if the identifier is
5935 unrecognised. Calling Skip is important because it allows wxWindows to
5936 generate further events for ancestors of the clicked-on
5937 window. Otherwise it would be impossible to show help for container
5938 windows, since processing would stop after the first window found.
15afbcd0 5939 """
e811c8ce
RD
5940 def __repr__(self):
5941 return "<%s.%s; proxy of C++ wxHelpEvent instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 5942 def __init__(self, *args, **kwargs):
a95a7133 5943 """__init__(self, wxEventType type=wxEVT_NULL, int winid=0, Point pt=DefaultPosition) -> HelpEvent"""
54f9ee45 5944 newobj = _controls_.new_HelpEvent(*args, **kwargs)
d14a1e28
RD
5945 self.this = newobj.this
5946 self.thisown = 1
5947 del newobj.thisown
e811c8ce 5948 def GetPosition(*args, **kwargs):
15afbcd0 5949 """
a95a7133 5950 GetPosition(self) -> Point
15afbcd0
RD
5951
5952 Returns the left-click position of the mouse, in screen
5953 coordinates. This allows the application to position the help
5954 appropriately.
5955 """
54f9ee45 5956 return _controls_.HelpEvent_GetPosition(*args, **kwargs)
e811c8ce
RD
5957
5958 def SetPosition(*args, **kwargs):
15afbcd0 5959 """
a95a7133 5960 SetPosition(self, Point pos)
15afbcd0
RD
5961
5962 Sets the left-click position of the mouse, in screen coordinates.
5963 """
54f9ee45 5964 return _controls_.HelpEvent_SetPosition(*args, **kwargs)
e811c8ce
RD
5965
5966 def GetLink(*args, **kwargs):
15afbcd0 5967 """
a95a7133 5968 GetLink(self) -> String
15afbcd0
RD
5969
5970 Get an optional link to further help
5971 """
54f9ee45 5972 return _controls_.HelpEvent_GetLink(*args, **kwargs)
e811c8ce
RD
5973
5974 def SetLink(*args, **kwargs):
15afbcd0 5975 """
a95a7133 5976 SetLink(self, String link)
15afbcd0
RD
5977
5978 Set an optional link to further help
5979 """
54f9ee45 5980 return _controls_.HelpEvent_SetLink(*args, **kwargs)
e811c8ce
RD
5981
5982 def GetTarget(*args, **kwargs):
15afbcd0 5983 """
a95a7133 5984 GetTarget(self) -> String
15afbcd0
RD
5985
5986 Get an optional target to display help in. E.g. a window specification
5987 """
54f9ee45 5988 return _controls_.HelpEvent_GetTarget(*args, **kwargs)
e811c8ce
RD
5989
5990 def SetTarget(*args, **kwargs):
15afbcd0 5991 """
a95a7133 5992 SetTarget(self, String target)
15afbcd0
RD
5993
5994 Set an optional target to display help in. E.g. a window specification
5995 """
54f9ee45 5996 return _controls_.HelpEvent_SetTarget(*args, **kwargs)
e811c8ce 5997
70551f47 5998
d14a1e28
RD
5999class HelpEventPtr(HelpEvent):
6000 def __init__(self, this):
6001 self.this = this
6002 if not hasattr(self,"thisown"): self.thisown = 0
6003 self.__class__ = HelpEvent
54f9ee45 6004_controls_.HelpEvent_swigregister(HelpEventPtr)
d14a1e28 6005
54f9ee45 6006class ContextHelp(_core.Object):
15afbcd0 6007 """
41e2b43e
RD
6008 This class changes the cursor to a query and puts the application into
6009 a 'context-sensitive help mode'. When the user left-clicks on a window
6010 within the specified window, a ``EVT_HELP`` event is sent to that
6011 control, and the application may respond to it by popping up some
6012 help.
15afbcd0
RD
6013
6014 There are a couple of ways to invoke this behaviour implicitly:
6015
41e2b43e
RD
6016 * Use the wx.DIALOG_EX_CONTEXTHELP extended style for a dialog
6017 (Windows only). This will put a question mark in the titlebar,
6018 and Windows will put the application into context-sensitive help
6019 mode automatically, with further programming.
6020
6021 * Create a `wx.ContextHelpButton`, whose predefined behaviour is
6022 to create a context help object. Normally you will write your
6023 application so that this button is only added to a dialog for
6024 non-Windows platforms (use ``wx.DIALOG_EX_CONTEXTHELP`` on
6025 Windows).
15afbcd0 6026
41e2b43e 6027 :see: `wx.ContextHelpButton`
15afbcd0
RD
6028
6029 """
e811c8ce
RD
6030 def __repr__(self):
6031 return "<%s.%s; proxy of C++ wxContextHelp instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 6032 def __init__(self, *args, **kwargs):
15afbcd0 6033 """
a95a7133 6034 __init__(self, Window window=None, bool doNow=True) -> ContextHelp
15afbcd0 6035
41e2b43e
RD
6036 Constructs a context help object, calling BeginContextHelp if doNow is
6037 true (the default).
15afbcd0
RD
6038
6039 If window is None, the top window is used.
6040 """
54f9ee45 6041 newobj = _controls_.new_ContextHelp(*args, **kwargs)
d14a1e28
RD
6042 self.this = newobj.this
6043 self.thisown = 1
6044 del newobj.thisown
54f9ee45 6045 def __del__(self, destroy=_controls_.delete_ContextHelp):
a95a7133 6046 """__del__(self)"""
d14a1e28
RD
6047 try:
6048 if self.thisown: destroy(self)
6049 except: pass
e811c8ce
RD
6050
6051 def BeginContextHelp(*args, **kwargs):
15afbcd0 6052 """
a95a7133 6053 BeginContextHelp(self, Window window=None) -> bool
15afbcd0 6054
41e2b43e
RD
6055 Puts the application into context-sensitive help mode. window is the
6056 window which will be used to catch events; if NULL, the top window
6057 will be used.
15afbcd0
RD
6058
6059 Returns true if the application was successfully put into
41e2b43e
RD
6060 context-sensitive help mode. This function only returns when the event
6061 loop has finished.
15afbcd0 6062 """
54f9ee45 6063 return _controls_.ContextHelp_BeginContextHelp(*args, **kwargs)
e811c8ce
RD
6064
6065 def EndContextHelp(*args, **kwargs):
15afbcd0 6066 """
a95a7133 6067 EndContextHelp(self) -> bool
15afbcd0
RD
6068
6069 Ends context-sensitive help mode. Not normally called by the
6070 application.
6071 """
54f9ee45 6072 return _controls_.ContextHelp_EndContextHelp(*args, **kwargs)
e811c8ce 6073
70551f47 6074
d14a1e28
RD
6075class ContextHelpPtr(ContextHelp):
6076 def __init__(self, this):
6077 self.this = this
6078 if not hasattr(self,"thisown"): self.thisown = 0
6079 self.__class__ = ContextHelp
54f9ee45 6080_controls_.ContextHelp_swigregister(ContextHelpPtr)
d14a1e28
RD
6081
6082class ContextHelpButton(BitmapButton):
15afbcd0 6083 """
41e2b43e
RD
6084 Instances of this class may be used to add a question mark button that
6085 when pressed, puts the application into context-help mode. It does
6086 this by creating a wx.ContextHelp object which itself generates a
6087 ``EVT_HELP`` event when the user clicks on a window.
6088
6089 On Windows, you may add a question-mark icon to a dialog by use of the
6090 ``wx.DIALOG_EX_CONTEXTHELP`` extra style, but on other platforms you
6091 will have to add a button explicitly, usually next to OK, Cancel or
6092 similar buttons.
15afbcd0 6093
41e2b43e 6094 :see: `wx.ContextHelp`, `wx.ContextHelpButton`
15afbcd0
RD
6095
6096 """
e811c8ce
RD
6097 def __repr__(self):
6098 return "<%s.%s; proxy of C++ wxContextHelpButton instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 6099 def __init__(self, *args, **kwargs):
0df68c9f 6100 """
a95a7133 6101 __init__(self, Window parent, int id=ID_CONTEXT_HELP, Point pos=DefaultPosition,
0df68c9f 6102 Size size=DefaultSize, long style=BU_AUTODRAW) -> ContextHelpButton
15afbcd0
RD
6103
6104 Constructor, creating and showing a context help button.
0df68c9f 6105 """
54f9ee45 6106 newobj = _controls_.new_ContextHelpButton(*args, **kwargs)
d14a1e28
RD
6107 self.this = newobj.this
6108 self.thisown = 1
6109 del newobj.thisown
6110 self._setOORInfo(self)
e811c8ce 6111
56f5d962 6112
d14a1e28
RD
6113class ContextHelpButtonPtr(ContextHelpButton):
6114 def __init__(self, this):
6115 self.this = this
6116 if not hasattr(self,"thisown"): self.thisown = 0
6117 self.__class__ = ContextHelpButton
54f9ee45 6118_controls_.ContextHelpButton_swigregister(ContextHelpButtonPtr)
d14a1e28
RD
6119
6120class HelpProvider(object):
15afbcd0
RD
6121 """
6122 wx.HelpProvider is an abstract class used by a program
6123 implementing context-sensitive help to show the help text for the
6124 given window.
6125
6126 The current help provider must be explicitly set by the
6127 application using wx.HelpProvider.Set().
6128 """
d14a1e28
RD
6129 def __init__(self): raise RuntimeError, "No constructor defined"
6130 def __repr__(self):
6131 return "<%s.%s; proxy of C++ wxHelpProvider instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
e811c8ce 6132 def Set(*args, **kwargs):
15afbcd0 6133 """
66c033b4 6134 Set(HelpProvider helpProvider) -> HelpProvider
15afbcd0 6135
41e2b43e
RD
6136 Sset the current, application-wide help provider. Returns the previous
6137 one. Unlike some other classes, the help provider is not created on
6138 demand. This must be explicitly done by the application.
15afbcd0 6139 """
54f9ee45 6140 return _controls_.HelpProvider_Set(*args, **kwargs)
e811c8ce
RD
6141
6142 Set = staticmethod(Set)
6143 def Get(*args, **kwargs):
15afbcd0 6144 """
66c033b4 6145 Get() -> HelpProvider
15afbcd0
RD
6146
6147 Return the current application-wide help provider.
6148 """
54f9ee45 6149 return _controls_.HelpProvider_Get(*args, **kwargs)
e811c8ce
RD
6150
6151 Get = staticmethod(Get)
6152 def GetHelp(*args, **kwargs):
15afbcd0 6153 """
a95a7133 6154 GetHelp(self, Window window) -> String
15afbcd0 6155
41e2b43e
RD
6156 Gets the help string for this window. Its interpretation is dependent
6157 on the help provider except that empty string always means that no
6158 help is associated with the window.
15afbcd0 6159 """
54f9ee45 6160 return _controls_.HelpProvider_GetHelp(*args, **kwargs)
e811c8ce
RD
6161
6162 def ShowHelp(*args, **kwargs):
15afbcd0 6163 """
a95a7133 6164 ShowHelp(self, Window window) -> bool
15afbcd0
RD
6165
6166 Shows help for the given window. Uses GetHelp internally if
41e2b43e
RD
6167 applicable. Returns True if it was done, or False if no help was
6168 available for this window.
15afbcd0 6169 """
54f9ee45 6170 return _controls_.HelpProvider_ShowHelp(*args, **kwargs)
e811c8ce
RD
6171
6172 def AddHelp(*args, **kwargs):
15afbcd0 6173 """
a95a7133 6174 AddHelp(self, Window window, String text)
15afbcd0
RD
6175
6176 Associates the text with the given window.
6177 """
54f9ee45 6178 return _controls_.HelpProvider_AddHelp(*args, **kwargs)
e811c8ce
RD
6179
6180 def AddHelpById(*args, **kwargs):
15afbcd0 6181 """
a95a7133 6182 AddHelpById(self, int id, String text)
15afbcd0
RD
6183
6184 This version associates the given text with all windows with this
41e2b43e
RD
6185 id. May be used to set the same help string for all Cancel buttons in
6186 the application, for example.
15afbcd0 6187 """
54f9ee45 6188 return _controls_.HelpProvider_AddHelpById(*args, **kwargs)
e811c8ce 6189
15afbcd0
RD
6190 def RemoveHelp(*args, **kwargs):
6191 """
a95a7133 6192 RemoveHelp(self, Window window)
15afbcd0
RD
6193
6194 Removes the association between the window pointer and the help
41e2b43e
RD
6195 text. This is called by the wx.Window destructor. Without this, the
6196 table of help strings will fill up and when window pointers are
6197 reused, the wrong help string will be found.
15afbcd0 6198 """
54f9ee45 6199 return _controls_.HelpProvider_RemoveHelp(*args, **kwargs)
15afbcd0 6200
e811c8ce 6201 def Destroy(*args, **kwargs):
a95a7133 6202 """Destroy(self)"""
54f9ee45 6203 return _controls_.HelpProvider_Destroy(*args, **kwargs)
e811c8ce 6204
d14a1e28
RD
6205
6206class HelpProviderPtr(HelpProvider):
6207 def __init__(self, this):
6208 self.this = this
6209 if not hasattr(self,"thisown"): self.thisown = 0
6210 self.__class__ = HelpProvider
54f9ee45 6211_controls_.HelpProvider_swigregister(HelpProviderPtr)
d14a1e28 6212
e811c8ce 6213def HelpProvider_Set(*args, **kwargs):
15afbcd0
RD
6214 """
6215 HelpProvider_Set(HelpProvider helpProvider) -> HelpProvider
6216
41e2b43e
RD
6217 Sset the current, application-wide help provider. Returns the previous
6218 one. Unlike some other classes, the help provider is not created on
6219 demand. This must be explicitly done by the application.
15afbcd0 6220 """
54f9ee45 6221 return _controls_.HelpProvider_Set(*args, **kwargs)
7a9b33db 6222
e811c8ce 6223def HelpProvider_Get(*args, **kwargs):
15afbcd0
RD
6224 """
6225 HelpProvider_Get() -> HelpProvider
6226
6227 Return the current application-wide help provider.
6228 """
54f9ee45 6229 return _controls_.HelpProvider_Get(*args, **kwargs)
d14a1e28
RD
6230
6231class SimpleHelpProvider(HelpProvider):
15afbcd0 6232 """
41e2b43e
RD
6233 wx.SimpleHelpProvider is an implementation of `wx.HelpProvider` which
6234 supports only plain text help strings, and shows the string associated
6235 with the control (if any) in a tooltip.
15afbcd0 6236 """
e811c8ce
RD
6237 def __repr__(self):
6238 return "<%s.%s; proxy of C++ wxSimpleHelpProvider instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 6239 def __init__(self, *args, **kwargs):
15afbcd0 6240 """
a95a7133 6241 __init__(self) -> SimpleHelpProvider
15afbcd0 6242
41e2b43e
RD
6243 wx.SimpleHelpProvider is an implementation of `wx.HelpProvider` which
6244 supports only plain text help strings, and shows the string associated
6245 with the control (if any) in a tooltip.
15afbcd0 6246 """
54f9ee45 6247 newobj = _controls_.new_SimpleHelpProvider(*args, **kwargs)
d14a1e28
RD
6248 self.this = newobj.this
6249 self.thisown = 1
6250 del newobj.thisown
d14a1e28
RD
6251
6252class SimpleHelpProviderPtr(SimpleHelpProvider):
6253 def __init__(self, this):
6254 self.this = this
6255 if not hasattr(self,"thisown"): self.thisown = 0
6256 self.__class__ = SimpleHelpProvider
54f9ee45 6257_controls_.SimpleHelpProvider_swigregister(SimpleHelpProviderPtr)
70551f47 6258
e811c8ce
RD
6259#---------------------------------------------------------------------------
6260
54f9ee45 6261class DragImage(_core.Object):
093d3ff1 6262 """Proxy of C++ DragImage class"""
e811c8ce
RD
6263 def __repr__(self):
6264 return "<%s.%s; proxy of C++ wxGenericDragImage instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
6265 def __init__(self, *args, **kwargs):
a95a7133 6266 """__init__(self, Bitmap image, Cursor cursor=wxNullCursor) -> DragImage"""
54f9ee45 6267 newobj = _controls_.new_DragImage(*args, **kwargs)
e811c8ce
RD
6268 self.this = newobj.this
6269 self.thisown = 1
6270 del newobj.thisown
54f9ee45 6271 def __del__(self, destroy=_controls_.delete_DragImage):
a95a7133 6272 """__del__(self)"""
e811c8ce
RD
6273 try:
6274 if self.thisown: destroy(self)
6275 except: pass
6276
6277 def SetBackingBitmap(*args, **kwargs):
a95a7133 6278 """SetBackingBitmap(self, Bitmap bitmap)"""
54f9ee45 6279 return _controls_.DragImage_SetBackingBitmap(*args, **kwargs)
e811c8ce
RD
6280
6281 def BeginDrag(*args, **kwargs):
0df68c9f 6282 """
a95a7133 6283 BeginDrag(self, Point hotspot, Window window, bool fullScreen=False,
0df68c9f
RD
6284 Rect rect=None) -> bool
6285 """
54f9ee45 6286 return _controls_.DragImage_BeginDrag(*args, **kwargs)
e811c8ce
RD
6287
6288 def BeginDragBounded(*args, **kwargs):
a95a7133 6289 """BeginDragBounded(self, Point hotspot, Window window, Window boundingWindow) -> bool"""
54f9ee45 6290 return _controls_.DragImage_BeginDragBounded(*args, **kwargs)
e811c8ce
RD
6291
6292 def EndDrag(*args, **kwargs):
a95a7133 6293 """EndDrag(self) -> bool"""
54f9ee45 6294 return _controls_.DragImage_EndDrag(*args, **kwargs)
e811c8ce
RD
6295
6296 def Move(*args, **kwargs):
a95a7133 6297 """Move(self, Point pt) -> bool"""
54f9ee45 6298 return _controls_.DragImage_Move(*args, **kwargs)
e811c8ce
RD
6299
6300 def Show(*args, **kwargs):
a95a7133 6301 """Show(self) -> bool"""
54f9ee45 6302 return _controls_.DragImage_Show(*args, **kwargs)
e811c8ce
RD
6303
6304 def Hide(*args, **kwargs):
a95a7133 6305 """Hide(self) -> bool"""
54f9ee45 6306 return _controls_.DragImage_Hide(*args, **kwargs)
e811c8ce
RD
6307
6308 def GetImageRect(*args, **kwargs):
a95a7133 6309 """GetImageRect(self, Point pos) -> Rect"""
54f9ee45 6310 return _controls_.DragImage_GetImageRect(*args, **kwargs)
e811c8ce
RD
6311
6312 def DoDrawImage(*args, **kwargs):
a95a7133 6313 """DoDrawImage(self, DC dc, Point pos) -> bool"""
54f9ee45 6314 return _controls_.DragImage_DoDrawImage(*args, **kwargs)
e811c8ce
RD
6315
6316 def UpdateBackingFromWindow(*args, **kwargs):
a95a7133 6317 """UpdateBackingFromWindow(self, DC windowDC, MemoryDC destDC, Rect sourceRect, Rect destRect) -> bool"""
54f9ee45 6318 return _controls_.DragImage_UpdateBackingFromWindow(*args, **kwargs)
e811c8ce
RD
6319
6320 def RedrawImage(*args, **kwargs):
a95a7133 6321 """RedrawImage(self, Point oldPos, Point newPos, bool eraseOld, bool drawNew) -> bool"""
54f9ee45 6322 return _controls_.DragImage_RedrawImage(*args, **kwargs)
e811c8ce
RD
6323
6324
6325class DragImagePtr(DragImage):
6326 def __init__(self, this):
6327 self.this = this
6328 if not hasattr(self,"thisown"): self.thisown = 0
6329 self.__class__ = DragImage
54f9ee45 6330_controls_.DragImage_swigregister(DragImagePtr)
e811c8ce
RD
6331
6332def DragIcon(*args, **kwargs):
b2dc1044 6333 """DragIcon(Icon image, Cursor cursor=wxNullCursor) -> DragImage"""
54f9ee45 6334 val = _controls_.new_DragIcon(*args, **kwargs)
e811c8ce
RD
6335 val.thisown = 1
6336 return val
6337
6338def DragString(*args, **kwargs):
196addbf 6339 """DragString(String str, Cursor cursor=wxNullCursor) -> DragImage"""
54f9ee45 6340 val = _controls_.new_DragString(*args, **kwargs)
e811c8ce
RD
6341 val.thisown = 1
6342 return val
6343
6344def DragTreeItem(*args, **kwargs):
6345 """DragTreeItem(TreeCtrl treeCtrl, TreeItemId id) -> DragImage"""
54f9ee45 6346 val = _controls_.new_DragTreeItem(*args, **kwargs)
e811c8ce
RD
6347 val.thisown = 1
6348 return val
6349
6350def DragListItem(*args, **kwargs):
6351 """DragListItem(ListCtrl listCtrl, long id) -> DragImage"""
54f9ee45 6352 val = _controls_.new_DragListItem(*args, **kwargs)
e811c8ce
RD
6353 val.thisown = 1
6354 return val
6355
53aa7709
RD
6356#---------------------------------------------------------------------------
6357
6358DP_DEFAULT = _controls_.DP_DEFAULT
6359DP_SPIN = _controls_.DP_SPIN
6360DP_DROPDOWN = _controls_.DP_DROPDOWN
6361DP_SHOWCENTURY = _controls_.DP_SHOWCENTURY
6362DP_ALLOWNONE = _controls_.DP_ALLOWNONE
6363class DatePickerCtrl(_core.Control):
6364 """
6365 This control allows the user to select a date. Unlike
6366 `wx.calendar.CalendarCtrl`, which is a relatively big control,
6367 `wx.DatePickerCtrl` is implemented as a small window showing the
6368 currently selected date. The control can be edited using the keyboard,
6369 and can also display a popup window for more user-friendly date
6370 selection, depending on the styles used and the platform.
6371 """
6372 def __repr__(self):
6373 return "<%s.%s; proxy of C++ wxDatePickerCtrl instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
6374 def __init__(self, *args, **kwargs):
6375 """
6376 __init__(self, Window parent, int id=-1, DateTime dt=wxDefaultDateTime,
6377 Point pos=DefaultPosition, Size size=DefaultSize,
6378 long style=wxDP_DEFAULT|wxDP_SHOWCENTURY,
6379 Validator validator=DefaultValidator,
6380 String name=DatePickerCtrlNameStr) -> DatePickerCtrl
6381
6382 Create a new DatePickerCtrl.
6383 """
6384 newobj = _controls_.new_DatePickerCtrl(*args, **kwargs)
6385 self.this = newobj.this
6386 self.thisown = 1
6387 del newobj.thisown
6388 self._setOORInfo(self)
6389
6390 def Create(*args, **kwargs):
6391 """
6392 Create(self, Window parent, int id=-1, DateTime dt=wxDefaultDateTime,
6393 Point pos=DefaultPosition, Size size=DefaultSize,
6394 long style=wxDP_DEFAULT|wxDP_SHOWCENTURY,
6395 Validator validator=DefaultValidator,
6396 String name=DatePickerCtrlNameStr) -> bool
6397
6398 Create the GUI parts of the DatePickerCtrl, for use in 2-phase
6399 creation.
6400 """
6401 return _controls_.DatePickerCtrl_Create(*args, **kwargs)
6402
6403 def SetValue(*args, **kwargs):
6404 """
6405 SetValue(self, DateTime dt)
6406
6407 Changes the current value of the control. The date should be valid and
6408 included in the currently selected range, if any.
6409
6410 Calling this method does not result in a date change event.
6411 """
6412 return _controls_.DatePickerCtrl_SetValue(*args, **kwargs)
6413
6414 def GetValue(*args, **kwargs):
6415 """
6416 GetValue(self) -> DateTime
6417
6418 Returns the currently selected date. If there is no selection or the
6419 selection is outside of the current range, an invalid `wx.DateTime`
6420 object is returned.
6421 """
6422 return _controls_.DatePickerCtrl_GetValue(*args, **kwargs)
6423
6424 def SetRange(*args, **kwargs):
6425 """
6426 SetRange(self, DateTime dt1, DateTime dt2)
6427
6428 Sets the valid range for the date selection. If dt1 is valid, it
6429 becomes the earliest date (inclusive) accepted by the control. If dt2
6430 is valid, it becomes the latest possible date.
6431
6432 If the current value of the control is outside of the newly set range
6433 bounds, the behaviour is undefined.
6434 """
6435 return _controls_.DatePickerCtrl_SetRange(*args, **kwargs)
6436
6437 def GetLowerLimit(*args, **kwargs):
6438 """
6439 GetLowerLimit(self) -> DateTime
6440
6441 Get the lower limit of the valid range for the date selection, if any.
6442 If there is no range or there is no lower limit, then the
6443 `wx.DateTime` value returned will be invalid.
6444 """
6445 return _controls_.DatePickerCtrl_GetLowerLimit(*args, **kwargs)
6446
6447 def GetUpperLimit(*args, **kwargs):
6448 """
6449 GetUpperLimit(self) -> DateTime
6450
6451 Get the upper limit of the valid range for the date selection, if any.
6452 If there is no range or there is no upper limit, then the
6453 `wx.DateTime` value returned will be invalid.
6454 """
6455 return _controls_.DatePickerCtrl_GetUpperLimit(*args, **kwargs)
6456
6457
6458class DatePickerCtrlPtr(DatePickerCtrl):
6459 def __init__(self, this):
6460 self.this = this
6461 if not hasattr(self,"thisown"): self.thisown = 0
6462 self.__class__ = DatePickerCtrl
6463_controls_.DatePickerCtrl_swigregister(DatePickerCtrlPtr)
6464DatePickerCtrlNameStr = cvar.DatePickerCtrlNameStr
6465
6466def PreDatePickerCtrl(*args, **kwargs):
6467 """
6468 PreDatePickerCtrl() -> DatePickerCtrl
6469
6470 Precreate a DatePickerCtrl for use in 2-phase creation.
6471 """
6472 val = _controls_.new_PreDatePickerCtrl(*args, **kwargs)
6473 val.thisown = 1
6474 return val
6475
70551f47 6476