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