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