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