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