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