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