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