X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/196addbfe0f00b96fdeff1f6f29dae33cf95d071..52f52ebc4e0be6a9899d328b08db9eb14629d219:/wxPython/src/gtk/controls.py?ds=inline diff --git a/wxPython/src/gtk/controls.py b/wxPython/src/gtk/controls.py index 22b6c09959..29c0cf8748 100644 --- a/wxPython/src/gtk/controls.py +++ b/wxPython/src/gtk/controls.py @@ -25,7 +25,7 @@ class Button(core.Control): """ __init__(Window parent, int id, String label, Point pos=DefaultPosition, Size size=DefaultSize, long style=0, - Validator validator=DefaultValidator, String name=wxPyButtonNameStr) -> Button + Validator validator=DefaultValidator, String name=ButtonNameStr) -> Button Create and show a button. """ @@ -39,7 +39,7 @@ class Button(core.Control): """ Create(Window parent, int id, String label, Point pos=DefaultPosition, Size size=DefaultSize, long style=0, - Validator validator=DefaultValidator, String name=wxPyButtonNameStr) -> bool + Validator validator=DefaultValidator, String name=ButtonNameStr) -> bool Acutally create the GUI Button for 2-phase creation. """ @@ -54,7 +54,7 @@ class Button(core.Control): return _controls.Button_SetDefault(*args, **kwargs) def GetDefaultSize(*args, **kwargs): - """Button.GetDefaultSize() -> Size""" + """GetDefaultSize() -> Size""" return _controls.Button_GetDefaultSize(*args, **kwargs) GetDefaultSize = staticmethod(GetDefaultSize) @@ -65,6 +65,8 @@ class ButtonPtr(Button): if not hasattr(self,"thisown"): self.thisown = 0 self.__class__ = Button _controls.Button_swigregister(ButtonPtr) +cvar = _controls.cvar +ButtonNameStr = cvar.ButtonNameStr def PreButton(*args, **kwargs): """ @@ -81,7 +83,13 @@ def Button_GetDefaultSize(*args, **kwargs): return _controls.Button_GetDefaultSize(*args, **kwargs) class BitmapButton(Button): - """A Buttont that contains a bitmap.""" + """ + A Button that contains a bitmap. A bitmap button can be supplied with a + single bitmap, and wxWindows will draw all button states using this bitmap. If + the application needs more control, additional bitmaps for the selected state, + unpressed focused state, and greyed-out state may be supplied. + + """ def __repr__(self): return "<%s.%s; proxy of C++ wxBitmapButton instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,) def __init__(self, *args, **kwargs): @@ -89,9 +97,9 @@ class BitmapButton(Button): __init__(Window parent, int id, Bitmap bitmap, Point pos=DefaultPosition, Size size=DefaultSize, long style=BU_AUTODRAW, Validator validator=DefaultValidator, - String name=wxPyButtonNameStr) -> BitmapButton + String name=ButtonNameStr) -> BitmapButton - Create and show a button. + Create and show a button with a bitmap for the label. """ newobj = _controls.new_BitmapButton(*args, **kwargs) self.this = newobj.this @@ -104,7 +112,7 @@ class BitmapButton(Button): Create(Window parent, int id, Bitmap bitmap, Point pos=DefaultPosition, Size size=DefaultSize, long style=BU_AUTODRAW, Validator validator=DefaultValidator, - String name=wxPyButtonNameStr) -> bool + String name=ButtonNameStr) -> bool Acutally create the GUI BitmapButton for 2-phase creation. """ @@ -214,13 +222,21 @@ CHK_UNCHECKED = _controls.CHK_UNCHECKED CHK_CHECKED = _controls.CHK_CHECKED CHK_UNDETERMINED = _controls.CHK_UNDETERMINED class CheckBox(core.Control): + """ + A checkbox is a labelled box which by default is either on (checkmark is + visible) or off (no checkmark). Optionally (When the wxCHK_3STATE style flag + is set) it can have a third state, called the mixed or undetermined + state. Often this is used as a "Does Not Apply" state. + """ def __repr__(self): return "<%s.%s; proxy of C++ wxCheckBox instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,) def __init__(self, *args, **kwargs): """ __init__(Window parent, int id, String label, Point pos=DefaultPosition, Size size=DefaultSize, long style=0, - Validator validator=DefaultValidator, String name=wxPyCheckBoxNameStr) -> CheckBox + Validator validator=DefaultValidator, String name=CheckBoxNameStr) -> CheckBox + + Creates and shows a CheckBox control """ newobj = _controls.new_CheckBox(*args, **kwargs) self.this = newobj.this @@ -232,36 +248,74 @@ class CheckBox(core.Control): """ Create(Window parent, int id, String label, Point pos=DefaultPosition, Size size=DefaultSize, long style=0, - Validator validator=DefaultValidator, String name=wxPyCheckBoxNameStr) -> bool + Validator validator=DefaultValidator, String name=CheckBoxNameStr) -> bool + + Actually create the GUI CheckBox for 2-phase creation. """ return _controls.CheckBox_Create(*args, **kwargs) def GetValue(*args, **kwargs): - """GetValue() -> bool""" + """ + GetValue() -> bool + + Gets the state of a 2-state CheckBox. Returns True if it is checked, + False otherwise. + """ return _controls.CheckBox_GetValue(*args, **kwargs) def IsChecked(*args, **kwargs): - """IsChecked() -> bool""" + """ + IsChecked() -> bool + + Similar to GetValue, but raises an exception if it is not a 2-state CheckBox. + """ return _controls.CheckBox_IsChecked(*args, **kwargs) def SetValue(*args, **kwargs): - """SetValue(bool state)""" + """ + SetValue(bool state) + + Set the state of a 2-state CheckBox. Pass True for checked, + False for unchecked. + """ return _controls.CheckBox_SetValue(*args, **kwargs) def Get3StateValue(*args, **kwargs): - """Get3StateValue() -> int""" + """ + Get3StateValue() -> int + + Returns wx.CHK_UNCHECKED when the CheckBox is unchecked, wx.CHK_CHECKED when + it is checked and wx.CHK_UNDETERMINED when it's in the undetermined state. + Raises an exceptiion when the function is used with a 2-state CheckBox. + """ return _controls.CheckBox_Get3StateValue(*args, **kwargs) def Set3StateValue(*args, **kwargs): - """Set3StateValue(int state)""" + """ + Set3StateValue(int state) + + Sets the CheckBox to the given state. The state parameter can be + one of the following: wx.CHK_UNCHECKED (Check is off), wx.CHK_CHECKED + (Check is on) or wx.CHK_UNDETERMINED (Check is mixed). Raises an + exception when the CheckBox is a 2-state checkbox and setting the state + to wx.CHK_UNDETERMINED. + """ return _controls.CheckBox_Set3StateValue(*args, **kwargs) def Is3State(*args, **kwargs): - """Is3State() -> bool""" + """ + Is3State() -> bool + + Returns whether or not the CheckBox is a 3-state CheckBox. + """ return _controls.CheckBox_Is3State(*args, **kwargs) def Is3rdStateAllowedForUser(*args, **kwargs): - """Is3rdStateAllowedForUser() -> bool""" + """ + Is3rdStateAllowedForUser() -> bool + + Returns whether or not the user can set the CheckBox to the third state. + """ return _controls.CheckBox_Is3rdStateAllowedForUser(*args, **kwargs) @@ -271,9 +325,14 @@ class CheckBoxPtr(CheckBox): if not hasattr(self,"thisown"): self.thisown = 0 self.__class__ = CheckBox _controls.CheckBox_swigregister(CheckBoxPtr) +CheckBoxNameStr = cvar.CheckBoxNameStr def PreCheckBox(*args, **kwargs): - """PreCheckBox() -> CheckBox""" + """ + PreCheckBox() -> CheckBox + + Precreate a CheckBox for 2-phase creation. + """ val = _controls.new_PreCheckBox(*args, **kwargs) val.thisown = 1 return val @@ -281,14 +340,19 @@ def PreCheckBox(*args, **kwargs): #--------------------------------------------------------------------------- class Choice(core.ControlWithItems): + """ + A Choice control is used to select one of a list of strings. Unlike a ListBox, + only the selection is visible until the user pulls down the menu of choices. + """ def __repr__(self): return "<%s.%s; proxy of C++ wxChoice instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,) def __init__(self, *args, **kwargs): """ - __init__(Window parent, int id, Point pos=DefaultPosition, Size size=DefaultSize, - int choices=0, String choices_array=None, - long style=0, Validator validator=DefaultValidator, - String name=wxPyChoiceNameStr) -> Choice + __init__(Window parent, int id, Point pos=DefaultPosition, Size size=DefaultSize, + List choices=[], long style=0, Validator validator=DefaultValidator, + String name=ChoiceNameStr) -> Choice + + Create and show a Choice control """ newobj = _controls.new_Choice(*args, **kwargs) self.this = newobj.this @@ -298,33 +362,39 @@ class Choice(core.ControlWithItems): def Create(*args, **kwargs): """ - Create(Window parent, int id, Point pos=DefaultPosition, Size size=DefaultSize, - int choices=0, String choices_array=None, - long style=0, Validator validator=DefaultValidator, - String name=wxPyChoiceNameStr) -> bool + Create(Window parent, int id, Point pos=DefaultPosition, Size size=DefaultSize, + List choices=[], long style=0, Validator validator=DefaultValidator, + String name=ChoiceNameStr) -> bool + + Actually create the GUI Choice control for 2-phase creation """ return _controls.Choice_Create(*args, **kwargs) - def GetColumns(*args, **kwargs): - """GetColumns() -> int""" - return _controls.Choice_GetColumns(*args, **kwargs) - - def SetColumns(*args, **kwargs): - """SetColumns(int n=1)""" - return _controls.Choice_SetColumns(*args, **kwargs) - def SetSelection(*args, **kwargs): - """SetSelection(int n)""" + """ + SetSelection(int n) + + Select the n'th item (zero based) in the list. + """ return _controls.Choice_SetSelection(*args, **kwargs) def SetStringSelection(*args, **kwargs): - """SetStringSelection(String string)""" + """ + SetStringSelection(String string) + + Select the item with the specifed string + """ return _controls.Choice_SetStringSelection(*args, **kwargs) def SetString(*args, **kwargs): - """SetString(int n, String s)""" + """ + SetString(int n, String string) + + Set the label for the n'th item (zero based) in the list. + """ return _controls.Choice_SetString(*args, **kwargs) + Select = SetSelection class ChoicePtr(Choice): def __init__(self, this): @@ -332,9 +402,14 @@ class ChoicePtr(Choice): if not hasattr(self,"thisown"): self.thisown = 0 self.__class__ = Choice _controls.Choice_swigregister(ChoicePtr) +ChoiceNameStr = cvar.ChoiceNameStr def PreChoice(*args, **kwargs): - """PreChoice() -> Choice""" + """ + PreChoice() -> Choice + + Precreate a Choice control for 2-phase creation. + """ val = _controls.new_PreChoice(*args, **kwargs) val.thisown = 1 return val @@ -342,15 +417,21 @@ def PreChoice(*args, **kwargs): #--------------------------------------------------------------------------- class ComboBox(core.Control,core.ItemContainer): + """ + A combobox is like a combination of an edit control and a listbox. It can be + displayed as static list with editable or read-only text field; or a drop-down + list with text field. + """ def __repr__(self): return "<%s.%s; proxy of C++ wxComboBox instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,) def __init__(self, *args, **kwargs): """ - __init__(Window parent, int id, String value=EmptyString, Point pos=DefaultPosition, - Size size=DefaultSize, - int choices=0, String choices_array=None, - long style=0, Validator validator=DefaultValidator, - String name=wxPyComboBoxNameStr) -> ComboBox + __init__(Window parent, int id, String value=EmptyString, + Point pos=DefaultPosition, Size size=DefaultSize, + List choices=[], long style=0, Validator validator=DefaultValidator, + String name=ComboBoxNameStr) -> ComboBox + + Constructor, creates and shows a ComboBox control. """ newobj = _controls.new_ComboBox(*args, **kwargs) self.this = newobj.this @@ -360,16 +441,21 @@ class ComboBox(core.Control,core.ItemContainer): def Create(*args, **kwargs): """ - Create(Window parent, int id, String value=EmptyString, Point pos=DefaultPosition, - Size size=DefaultSize, - int choices=0, String choices_array=None, - long style=0, Validator validator=DefaultValidator, - String name=wxPyComboBoxNameStr) -> bool + Create(Window parent, int id, String value=EmptyString, + Point pos=DefaultPosition, Size size=DefaultSize, + List choices=[], long style=0, Validator validator=DefaultValidator, + String name=ChoiceNameStr) -> bool + + Actually create the GUI Choice control for 2-phase creation """ return _controls.ComboBox_Create(*args, **kwargs) def GetValue(*args, **kwargs): - """GetValue() -> String""" + """ + GetValue() -> String + + Returns the current value in the combobox text field. + """ return _controls.ComboBox_GetValue(*args, **kwargs) def SetValue(*args, **kwargs): @@ -377,35 +463,68 @@ class ComboBox(core.Control,core.ItemContainer): return _controls.ComboBox_SetValue(*args, **kwargs) def Copy(*args, **kwargs): - """Copy()""" + """ + Copy() + + Copies the selected text to the clipboard. + """ return _controls.ComboBox_Copy(*args, **kwargs) def Cut(*args, **kwargs): - """Cut()""" + """ + Cut() + + Copies the selected text to the clipboard and removes the selection. + """ return _controls.ComboBox_Cut(*args, **kwargs) def Paste(*args, **kwargs): - """Paste()""" + """ + Paste() + + Pastes text from the clipboard to the text field. + """ return _controls.ComboBox_Paste(*args, **kwargs) def SetInsertionPoint(*args, **kwargs): - """SetInsertionPoint(long pos)""" + """ + SetInsertionPoint(long pos) + + Sets the insertion point in the combobox text field. + """ return _controls.ComboBox_SetInsertionPoint(*args, **kwargs) def GetInsertionPoint(*args, **kwargs): - """GetInsertionPoint() -> long""" + """ + GetInsertionPoint() -> long + + Returns the insertion point for the combobox's text field. + """ return _controls.ComboBox_GetInsertionPoint(*args, **kwargs) def GetLastPosition(*args, **kwargs): - """GetLastPosition() -> long""" + """ + GetLastPosition() -> long + + Returns the last position in the combobox text field. + """ return _controls.ComboBox_GetLastPosition(*args, **kwargs) def Replace(*args, **kwargs): - """Replace(long from, long to, String value)""" + """ + Replace(long from, long to, String value) + + Replaces the text between two positions with the given text, in the + combobox text field. + """ return _controls.ComboBox_Replace(*args, **kwargs) def SetSelection(*args, **kwargs): - """SetSelection(int n)""" + """ + SetSelection(int n) + + Selects the text between the two positions, in the combobox text field. + """ return _controls.ComboBox_SetSelection(*args, **kwargs) def SetMark(*args, **kwargs): @@ -417,11 +536,19 @@ class ComboBox(core.Control,core.ItemContainer): return _controls.ComboBox_SetEditable(*args, **kwargs) def SetInsertionPointEnd(*args, **kwargs): - """SetInsertionPointEnd()""" + """ + SetInsertionPointEnd() + + Sets the insertion point at the end of the combobox text field. + """ return _controls.ComboBox_SetInsertionPointEnd(*args, **kwargs) def Remove(*args, **kwargs): - """Remove(long from, long to)""" + """ + Remove(long from, long to) + + Removes the text between the two positions in the combobox text field. + """ return _controls.ComboBox_Remove(*args, **kwargs) @@ -431,9 +558,14 @@ class ComboBoxPtr(ComboBox): if not hasattr(self,"thisown"): self.thisown = 0 self.__class__ = ComboBox _controls.ComboBox_swigregister(ComboBoxPtr) +ComboBoxNameStr = cvar.ComboBoxNameStr def PreComboBox(*args, **kwargs): - """PreComboBox() -> ComboBox""" + """ + PreComboBox() -> ComboBox + + Precreate a ComboBox control for 2-phase creation. + """ val = _controls.new_PreComboBox(*args, **kwargs) val.thisown = 1 return val @@ -452,7 +584,7 @@ class Gauge(core.Control): __init__(Window parent, int id, int range, Point pos=DefaultPosition, Size size=DefaultSize, long style=GA_HORIZONTAL, Validator validator=DefaultValidator, - String name=wxPyGaugeNameStr) -> Gauge + String name=GaugeNameStr) -> Gauge """ newobj = _controls.new_Gauge(*args, **kwargs) self.this = newobj.this @@ -465,7 +597,7 @@ class Gauge(core.Control): Create(Window parent, int id, int range, Point pos=DefaultPosition, Size size=DefaultSize, long style=GA_HORIZONTAL, Validator validator=DefaultValidator, - String name=wxPyGaugeNameStr) -> bool + String name=GaugeNameStr) -> bool """ return _controls.Gauge_Create(*args, **kwargs) @@ -512,6 +644,7 @@ class GaugePtr(Gauge): if not hasattr(self,"thisown"): self.thisown = 0 self.__class__ = Gauge _controls.Gauge_swigregister(GaugePtr) +GaugeNameStr = cvar.GaugeNameStr def PreGauge(*args, **kwargs): """PreGauge() -> Gauge""" @@ -528,7 +661,7 @@ class StaticBox(core.Control): """ __init__(Window parent, int id, String label, Point pos=DefaultPosition, Size size=DefaultSize, long style=0, - String name=wxPyStaticBoxNameStr) -> StaticBox + String name=StaticBoxNameStr) -> StaticBox """ newobj = _controls.new_StaticBox(*args, **kwargs) self.this = newobj.this @@ -540,7 +673,7 @@ class StaticBox(core.Control): """ Create(Window parent, int id, String label, Point pos=DefaultPosition, Size size=DefaultSize, long style=0, - String name=wxPyStaticBoxNameStr) -> bool + String name=StaticBoxNameStr) -> bool """ return _controls.StaticBox_Create(*args, **kwargs) @@ -551,6 +684,9 @@ class StaticBoxPtr(StaticBox): if not hasattr(self,"thisown"): self.thisown = 0 self.__class__ = StaticBox _controls.StaticBox_swigregister(StaticBoxPtr) +StaticBitmapNameStr = cvar.StaticBitmapNameStr +StaticBoxNameStr = cvar.StaticBoxNameStr +StaticTextNameStr = cvar.StaticTextNameStr def PreStaticBox(*args, **kwargs): """PreStaticBox() -> StaticBox""" @@ -567,7 +703,7 @@ class StaticLine(core.Control): """ __init__(Window parent, int id, Point pos=DefaultPosition, Size size=DefaultSize, long style=LI_HORIZONTAL, - String name=wxPyStaticTextNameStr) -> StaticLine + String name=StaticTextNameStr) -> StaticLine """ newobj = _controls.new_StaticLine(*args, **kwargs) self.this = newobj.this @@ -579,7 +715,7 @@ class StaticLine(core.Control): """ Create(Window parent, int id, Point pos=DefaultPosition, Size size=DefaultSize, long style=LI_HORIZONTAL, - String name=wxPyStaticTextNameStr) -> bool + String name=StaticTextNameStr) -> bool """ return _controls.StaticLine_Create(*args, **kwargs) @@ -588,7 +724,7 @@ class StaticLine(core.Control): return _controls.StaticLine_IsVertical(*args, **kwargs) def GetDefaultSize(*args, **kwargs): - """StaticLine.GetDefaultSize() -> int""" + """GetDefaultSize() -> int""" return _controls.StaticLine_GetDefaultSize(*args, **kwargs) GetDefaultSize = staticmethod(GetDefaultSize) @@ -619,7 +755,7 @@ class StaticText(core.Control): """ __init__(Window parent, int id, String label, Point pos=DefaultPosition, Size size=DefaultSize, long style=0, - String name=wxPyStaticTextNameStr) -> StaticText + String name=StaticTextNameStr) -> StaticText """ newobj = _controls.new_StaticText(*args, **kwargs) self.this = newobj.this @@ -631,7 +767,7 @@ class StaticText(core.Control): """ Create(Window parent, int id, String label, Point pos=DefaultPosition, Size size=DefaultSize, long style=0, - String name=wxPyStaticTextNameStr) -> bool + String name=StaticTextNameStr) -> bool """ return _controls.StaticText_Create(*args, **kwargs) @@ -658,7 +794,7 @@ class StaticBitmap(core.Control): """ __init__(Window parent, int id, Bitmap bitmap, Point pos=DefaultPosition, Size size=DefaultSize, long style=0, - String name=wxPyStaticBitmapNameStr) -> StaticBitmap + String name=StaticBitmapNameStr) -> StaticBitmap """ newobj = _controls.new_StaticBitmap(*args, **kwargs) self.this = newobj.this @@ -668,7 +804,7 @@ class StaticBitmap(core.Control): """ Create(Window parent, int id, Bitmap bitmap, Point pos=DefaultPosition, Size size=DefaultSize, long style=0, - String name=wxPyStaticBitmapNameStr) -> bool + String name=StaticBitmapNameStr) -> bool """ return _controls.StaticBitmap_Create(*args, **kwargs) @@ -681,7 +817,7 @@ class StaticBitmap(core.Control): return _controls.StaticBitmap_SetBitmap(*args, **kwargs) def SetIcon(*args, **kwargs): - """SetIcon(wxIcon icon)""" + """SetIcon(Icon icon)""" return _controls.StaticBitmap_SetIcon(*args, **kwargs) @@ -706,9 +842,9 @@ class ListBox(core.ControlWithItems): def __init__(self, *args, **kwargs): """ __init__(Window parent, int id, Point pos=DefaultPosition, Size size=DefaultSize, - int choices=0, String choices_array=None, + wxArrayString choices=wxPyEmptyStringArray, long style=0, Validator validator=DefaultValidator, - String name=wxPyListBoxNameStr) -> ListBox + String name=ListBoxNameStr) -> ListBox """ newobj = _controls.new_ListBox(*args, **kwargs) self.this = newobj.this @@ -719,9 +855,9 @@ class ListBox(core.ControlWithItems): def Create(*args, **kwargs): """ Create(Window parent, int id, Point pos=DefaultPosition, Size size=DefaultSize, - int choices=0, String choices_array=None, + wxArrayString choices=wxPyEmptyStringArray, long style=0, Validator validator=DefaultValidator, - String name=wxPyListBoxNameStr) -> bool + String name=ListBoxNameStr) -> bool """ return _controls.ListBox_Create(*args, **kwargs) @@ -785,6 +921,18 @@ class ListBox(core.ControlWithItems): """IsSorted() -> bool""" return _controls.ListBox_IsSorted(*args, **kwargs) + def SetItemForegroundColour(*args, **kwargs): + """SetItemForegroundColour(int item, Colour c)""" + return _controls.ListBox_SetItemForegroundColour(*args, **kwargs) + + def SetItemBackgroundColour(*args, **kwargs): + """SetItemBackgroundColour(int item, Colour c)""" + return _controls.ListBox_SetItemBackgroundColour(*args, **kwargs) + + def SetItemFont(*args, **kwargs): + """SetItemFont(int item, Font f)""" + return _controls.ListBox_SetItemFont(*args, **kwargs) + class ListBoxPtr(ListBox): def __init__(self, this): @@ -792,6 +940,7 @@ class ListBoxPtr(ListBox): if not hasattr(self,"thisown"): self.thisown = 0 self.__class__ = ListBox _controls.ListBox_swigregister(ListBoxPtr) +ListBoxNameStr = cvar.ListBoxNameStr def PreListBox(*args, **kwargs): """PreListBox() -> ListBox""" @@ -807,20 +956,22 @@ class CheckListBox(ListBox): def __init__(self, *args, **kwargs): """ __init__(Window parent, int id, Point pos=DefaultPosition, Size size=DefaultSize, - int choices=0, String choices_array=None, + wxArrayString choices=wxPyEmptyStringArray, long style=0, Validator validator=DefaultValidator, - String name=wxPyListBoxNameStr) -> CheckListBox + String name=ListBoxNameStr) -> CheckListBox """ newobj = _controls.new_CheckListBox(*args, **kwargs) self.this = newobj.this self.thisown = 1 del newobj.thisown + self._setOORInfo(self) + def Create(*args, **kwargs): """ Create(Window parent, int id, Point pos=DefaultPosition, Size size=DefaultSize, - int choices=0, String choices_array=None, + wxArrayString choices=wxPyEmptyStringArray, long style=0, Validator validator=DefaultValidator, - String name=wxPyListBoxNameStr) -> bool + String name=ListBoxNameStr) -> bool """ return _controls.CheckListBox_Create(*args, **kwargs) @@ -896,6 +1047,11 @@ TEXT_ATTR_ALIGNMENT = _controls.TEXT_ATTR_ALIGNMENT TEXT_ATTR_LEFT_INDENT = _controls.TEXT_ATTR_LEFT_INDENT TEXT_ATTR_RIGHT_INDENT = _controls.TEXT_ATTR_RIGHT_INDENT TEXT_ATTR_TABS = _controls.TEXT_ATTR_TABS +TE_HT_UNKNOWN = _controls.TE_HT_UNKNOWN +TE_HT_BEFORE = _controls.TE_HT_BEFORE +TE_HT_ON_TEXT = _controls.TE_HT_ON_TEXT +TE_HT_BELOW = _controls.TE_HT_BELOW +TE_HT_BEYOND = _controls.TE_HT_BEYOND class TextAttr(object): def __repr__(self): return "<%s.%s; proxy of C++ wxTextAttr instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,) @@ -909,6 +1065,12 @@ class TextAttr(object): self.this = newobj.this self.thisown = 1 del newobj.thisown + def __del__(self, destroy=_controls.delete_TextAttr): + """__del__()""" + try: + if self.thisown: destroy(self) + except: pass + def Init(*args, **kwargs): """Init()""" return _controls.TextAttr_Init(*args, **kwargs) @@ -1014,7 +1176,7 @@ class TextAttr(object): return _controls.TextAttr_IsDefault(*args, **kwargs) def Combine(*args, **kwargs): - """TextAttr.Combine(TextAttr attr, TextAttr attrDef, TextCtrl text) -> TextAttr""" + """Combine(TextAttr attr, TextAttr attrDef, TextCtrl text) -> TextAttr""" return _controls.TextAttr_Combine(*args, **kwargs) Combine = staticmethod(Combine) @@ -1025,6 +1187,7 @@ class TextAttrPtr(TextAttr): if not hasattr(self,"thisown"): self.thisown = 0 self.__class__ = TextAttr _controls.TextAttr_swigregister(TextAttrPtr) +TextCtrlNameStr = cvar.TextCtrlNameStr def TextAttr_Combine(*args, **kwargs): """TextAttr_Combine(TextAttr attr, TextAttr attrDef, TextCtrl text) -> TextAttr""" @@ -1038,7 +1201,7 @@ class TextCtrl(core.Control): __init__(Window parent, int id, String value=EmptyString, Point pos=DefaultPosition, Size size=DefaultSize, long style=0, Validator validator=DefaultValidator, - String name=wxPyTextCtrlNameStr) -> TextCtrl + String name=TextCtrlNameStr) -> TextCtrl """ newobj = _controls.new_TextCtrl(*args, **kwargs) self.this = newobj.this @@ -1051,7 +1214,7 @@ class TextCtrl(core.Control): Create(Window parent, int id, String value=EmptyString, Point pos=DefaultPosition, Size size=DefaultSize, long style=0, Validator validator=DefaultValidator, - String name=wxPyTextCtrlNameStr) -> bool + String name=TextCtrlNameStr) -> bool """ return _controls.TextCtrl_Create(*args, **kwargs) @@ -1179,6 +1342,16 @@ class TextCtrl(core.Control): """ShowPosition(long pos)""" return _controls.TextCtrl_ShowPosition(*args, **kwargs) + def HitTest(*args, **kwargs): + """ + HitTest(Point pt) -> (result, row, col) + + Find the character at position given in pixels. + NB: pt is in device coords (not adjusted for the client area + origin nor scrolling) + """ + return _controls.TextCtrl_HitTest(*args, **kwargs) + def Copy(*args, **kwargs): """Copy()""" return _controls.TextCtrl_Copy(*args, **kwargs) @@ -1316,7 +1489,7 @@ class ScrollBar(core.Control): """ __init__(Window parent, int id=-1, Point pos=DefaultPosition, Size size=DefaultSize, long style=SB_HORIZONTAL, - Validator validator=DefaultValidator, String name=wxPyScrollBarNameStr) -> ScrollBar + Validator validator=DefaultValidator, String name=ScrollBarNameStr) -> ScrollBar """ newobj = _controls.new_ScrollBar(*args, **kwargs) self.this = newobj.this @@ -1328,7 +1501,7 @@ class ScrollBar(core.Control): """ Create(Window parent, int id=-1, Point pos=DefaultPosition, Size size=DefaultSize, long style=SB_HORIZONTAL, - Validator validator=DefaultValidator, String name=wxPyScrollBarNameStr) -> bool + Validator validator=DefaultValidator, String name=ScrollBarNameStr) -> bool """ return _controls.ScrollBar_Create(*args, **kwargs) @@ -1371,6 +1544,7 @@ class ScrollBarPtr(ScrollBar): if not hasattr(self,"thisown"): self.thisown = 0 self.__class__ = ScrollBar _controls.ScrollBar_swigregister(ScrollBarPtr) +ScrollBarNameStr = cvar.ScrollBarNameStr def PreScrollBar(*args, **kwargs): """PreScrollBar() -> ScrollBar""" @@ -1391,7 +1565,7 @@ class SpinButton(core.Control): """ __init__(Window parent, int id=-1, Point pos=DefaultPosition, Size size=DefaultSize, long style=SP_HORIZONTAL, - String name=wxPySPIN_BUTTON_NAME) -> SpinButton + String name=SPIN_BUTTON_NAME) -> SpinButton """ newobj = _controls.new_SpinButton(*args, **kwargs) self.this = newobj.this @@ -1403,7 +1577,7 @@ class SpinButton(core.Control): """ Create(Window parent, int id=-1, Point pos=DefaultPosition, Size size=DefaultSize, long style=SP_HORIZONTAL, - String name=wxPySPIN_BUTTON_NAME) -> bool + String name=SPIN_BUTTON_NAME) -> bool """ return _controls.SpinButton_Create(*args, **kwargs) @@ -1446,6 +1620,8 @@ class SpinButtonPtr(SpinButton): if not hasattr(self,"thisown"): self.thisown = 0 self.__class__ = SpinButton _controls.SpinButton_swigregister(SpinButtonPtr) +SPIN_BUTTON_NAME = cvar.SPIN_BUTTON_NAME +SpinCtrlNameStr = cvar.SpinCtrlNameStr def PreSpinButton(*args, **kwargs): """PreSpinButton() -> SpinButton""" @@ -1461,7 +1637,7 @@ class SpinCtrl(core.Control): __init__(Window parent, int id=-1, String value=EmptyString, Point pos=DefaultPosition, Size size=DefaultSize, long style=SP_ARROW_KEYS, int min=0, int max=100, - int initial=0, String name=wxPySpinCtrlNameStr) -> SpinCtrl + int initial=0, String name=SpinCtrlNameStr) -> SpinCtrl """ newobj = _controls.new_SpinCtrl(*args, **kwargs) self.this = newobj.this @@ -1474,7 +1650,7 @@ class SpinCtrl(core.Control): Create(Window parent, int id=-1, String value=EmptyString, Point pos=DefaultPosition, Size size=DefaultSize, long style=SP_ARROW_KEYS, int min=0, int max=100, - int initial=0, String name=wxPySpinCtrlNameStr) -> bool + int initial=0, String name=SpinCtrlNameStr) -> bool """ return _controls.SpinCtrl_Create(*args, **kwargs) @@ -1520,8 +1696,36 @@ def PreSpinCtrl(*args, **kwargs): val.thisown = 1 return val +class SpinEvent(core.NotifyEvent): + def __repr__(self): + return "<%s.%s; proxy of C++ wxSpinEvent instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,) + def __init__(self, *args, **kwargs): + """__init__(wxEventType commandType=wxEVT_NULL, int winid=0) -> SpinEvent""" + newobj = _controls.new_SpinEvent(*args, **kwargs) + self.this = newobj.this + self.thisown = 1 + del newobj.thisown + def GetPosition(*args, **kwargs): + """GetPosition() -> int""" + return _controls.SpinEvent_GetPosition(*args, **kwargs) + + def SetPosition(*args, **kwargs): + """SetPosition(int pos)""" + return _controls.SpinEvent_SetPosition(*args, **kwargs) + + +class SpinEventPtr(SpinEvent): + def __init__(self, this): + self.this = this + if not hasattr(self,"thisown"): self.thisown = 0 + self.__class__ = SpinEvent +_controls.SpinEvent_swigregister(SpinEventPtr) + wxEVT_COMMAND_SPINCTRL_UPDATED = _controls.wxEVT_COMMAND_SPINCTRL_UPDATED -EVT_SPINCTRL = wx.PyEventBinder( wxEVT_COMMAND_SPINCTRL_UPDATED, 1) +EVT_SPIN_UP = wx.PyEventBinder( wx.wxEVT_SCROLL_LINEUP, 1) +EVT_SPIN_DOWN = wx.PyEventBinder( wx.wxEVT_SCROLL_LINEDOWN, 1) +EVT_SPIN = wx.PyEventBinder( wx.wxEVT_SCROLL_THUMBTRACK, 1) +EVT_SPINCTRL = wx.PyEventBinder( wxEVT_COMMAND_SPINCTRL_UPDATED, 1) #--------------------------------------------------------------------------- @@ -1530,12 +1734,13 @@ class RadioBox(core.Control): return "<%s.%s; proxy of C++ wxRadioBox instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,) def __init__(self, *args, **kwargs): """ - __init__(Window parent, int id, String label, Point point=DefaultPosition, - Size size=DefaultSize, int choices=0, - String choices_array=None, int majorDimension=0, + __init__(Window parent, int id, String label, Point pos=DefaultPosition, + Size size=DefaultSize, wxArrayString choices=wxPyEmptyStringArray, + int majorDimension=0, long style=RA_HORIZONTAL, Validator validator=DefaultValidator, - String name=wxPyRadioBoxNameStr) -> RadioBox + String name=RadioBoxNameStr) -> RadioBox """ + if kwargs.has_key('point'): kwargs['pos'] = kwargs['point'] newobj = _controls.new_RadioBox(*args, **kwargs) self.this = newobj.this self.thisown = 1 @@ -1544,11 +1749,11 @@ class RadioBox(core.Control): def Create(*args, **kwargs): """ - Create(Window parent, int id, String label, Point point=DefaultPosition, - Size size=DefaultSize, int choices=0, - String choices_array=None, int majorDimension=0, + Create(Window parent, int id, String label, Point pos=DefaultPosition, + Size size=DefaultSize, wxArrayString choices=wxPyEmptyStringArray, + int majorDimension=0, long style=RA_HORIZONTAL, Validator validator=DefaultValidator, - String name=wxPyRadioBoxNameStr) -> bool + String name=RadioBoxNameStr) -> bool """ return _controls.RadioBox_Create(*args, **kwargs) @@ -1613,6 +1818,8 @@ class RadioBoxPtr(RadioBox): if not hasattr(self,"thisown"): self.thisown = 0 self.__class__ = RadioBox _controls.RadioBox_swigregister(RadioBoxPtr) +RadioBoxNameStr = cvar.RadioBoxNameStr +RadioButtonNameStr = cvar.RadioButtonNameStr def PreRadioBox(*args, **kwargs): """PreRadioBox() -> RadioBox""" @@ -1629,7 +1836,7 @@ class RadioButton(core.Control): """ __init__(Window parent, int id, String label, Point pos=DefaultPosition, Size size=DefaultSize, long style=0, - Validator validator=DefaultValidator, String name=wxPyRadioButtonNameStr) -> RadioButton + Validator validator=DefaultValidator, String name=RadioButtonNameStr) -> RadioButton """ newobj = _controls.new_RadioButton(*args, **kwargs) self.this = newobj.this @@ -1641,7 +1848,7 @@ class RadioButton(core.Control): """ Create(Window parent, int id, String label, Point pos=DefaultPosition, Size size=DefaultSize, long style=0, - Validator validator=DefaultValidator, String name=wxPyRadioButtonNameStr) -> bool + Validator validator=DefaultValidator, String name=RadioButtonNameStr) -> bool """ return _controls.RadioButton_Create(*args, **kwargs) @@ -1675,10 +1882,11 @@ class Slider(core.Control): def __init__(self, *args, **kwargs): """ __init__(Window parent, int id, int value, int minValue, int maxValue, - Point point=DefaultPosition, Size size=DefaultSize, + Point pos=DefaultPosition, Size size=DefaultSize, long style=SL_HORIZONTAL, Validator validator=DefaultValidator, - String name=wxPySliderNameStr) -> Slider + String name=SliderNameStr) -> Slider """ + if kwargs.has_key('point'): kwargs['pos'] = kwargs['point'] newobj = _controls.new_Slider(*args, **kwargs) self.this = newobj.this self.thisown = 1 @@ -1688,9 +1896,9 @@ class Slider(core.Control): def Create(*args, **kwargs): """ Create(Window parent, int id, int value, int minValue, int maxValue, - Point point=DefaultPosition, Size size=DefaultSize, + Point pos=DefaultPosition, Size size=DefaultSize, long style=SL_HORIZONTAL, Validator validator=DefaultValidator, - String name=wxPySliderNameStr) -> bool + String name=SliderNameStr) -> bool """ return _controls.Slider_Create(*args, **kwargs) @@ -1747,7 +1955,7 @@ class Slider(core.Control): return _controls.Slider_GetThumbLength(*args, **kwargs) def SetTickFreq(*args, **kwargs): - """SetTickFreq(int n, int pos)""" + """SetTickFreq(int n, int pos=1)""" return _controls.Slider_SetTickFreq(*args, **kwargs) def GetTickFreq(*args, **kwargs): @@ -1785,6 +1993,7 @@ class SliderPtr(Slider): if not hasattr(self,"thisown"): self.thisown = 0 self.__class__ = Slider _controls.Slider_swigregister(SliderPtr) +SliderNameStr = cvar.SliderNameStr def PreSlider(*args, **kwargs): """PreSlider() -> Slider""" @@ -1804,7 +2013,7 @@ class ToggleButton(core.Control): """ __init__(Window parent, int id, String label, Point pos=DefaultPosition, Size size=DefaultSize, long style=0, - Validator validator=DefaultValidator, String name=wxPyToggleButtonNameStr) -> ToggleButton + Validator validator=DefaultValidator, String name=ToggleButtonNameStr) -> ToggleButton """ newobj = _controls.new_ToggleButton(*args, **kwargs) self.this = newobj.this @@ -1816,7 +2025,7 @@ class ToggleButton(core.Control): """ Create(Window parent, int id, String label, Point pos=DefaultPosition, Size size=DefaultSize, long style=0, - Validator validator=DefaultValidator, String name=wxPyToggleButtonNameStr) -> bool + Validator validator=DefaultValidator, String name=ToggleButtonNameStr) -> bool """ return _controls.ToggleButton_Create(*args, **kwargs) @@ -1839,6 +2048,7 @@ class ToggleButtonPtr(ToggleButton): if not hasattr(self,"thisown"): self.thisown = 0 self.__class__ = ToggleButton _controls.ToggleButton_swigregister(ToggleButtonPtr) +ToggleButtonNameStr = cvar.ToggleButtonNameStr def PreToggleButton(*args, **kwargs): """PreToggleButton() -> ToggleButton""" @@ -1873,17 +2083,15 @@ class BookCtrl(core.Control): return _controls.BookCtrl_GetPageText(*args, **kwargs) def SetImageList(*args, **kwargs): - """SetImageList(wxImageList imageList)""" + """SetImageList(ImageList imageList)""" return _controls.BookCtrl_SetImageList(*args, **kwargs) def AssignImageList(*args, **kwargs): - """AssignImageList(wxImageList imageList)""" - val = _controls.BookCtrl_AssignImageList(*args, **kwargs) - args[1].thisown = 0 - return val + """AssignImageList(ImageList imageList)""" + return _controls.BookCtrl_AssignImageList(*args, **kwargs) def GetImageList(*args, **kwargs): - """GetImageList() -> wxImageList""" + """GetImageList() -> ImageList""" return _controls.BookCtrl_GetImageList(*args, **kwargs) def GetPageImage(*args, **kwargs): @@ -1940,6 +2148,7 @@ class BookCtrlPtr(BookCtrl): if not hasattr(self,"thisown"): self.thisown = 0 self.__class__ = BookCtrl _controls.BookCtrl_swigregister(BookCtrlPtr) +NOTEBOOK_NAME = cvar.NOTEBOOK_NAME class BookCtrlEvent(core.NotifyEvent): def __repr__(self): @@ -1995,7 +2204,7 @@ class Notebook(BookCtrl): def __init__(self, *args, **kwargs): """ __init__(Window parent, int id, Point pos=DefaultPosition, Size size=DefaultSize, - long style=0, String name=wxPyNOTEBOOK_NAME) -> Notebook + long style=0, String name=NOTEBOOK_NAME) -> Notebook """ newobj = _controls.new_Notebook(*args, **kwargs) self.this = newobj.this @@ -2006,7 +2215,7 @@ class Notebook(BookCtrl): def Create(*args, **kwargs): """ Create(Window parent, int id, Point pos=DefaultPosition, Size size=DefaultSize, - long style=0, String name=wxPyNOTEBOOK_NAME) -> bool + long style=0, String name=NOTEBOOK_NAME) -> bool """ return _controls.Notebook_Create(*args, **kwargs) @@ -2026,7 +2235,7 @@ class Notebook(BookCtrl): """ HitTest(Point pt) -> (tab, where) - Returns the tab which is hit, and flags indicating where using wxNB_HITTEST_ flags. + Returns the tab which is hit, and flags indicating where using wx.NB_HITTEST_ flags. """ return _controls.Notebook_HitTest(*args, **kwargs) @@ -2882,6 +3091,7 @@ class ListItemAttrPtr(ListItemAttr): if not hasattr(self,"thisown"): self.thisown = 0 self.__class__ = ListItemAttr _controls.ListItemAttr_swigregister(ListItemAttrPtr) +ListCtrlNameStr = cvar.ListCtrlNameStr #--------------------------------------------------------------------------- @@ -3171,7 +3381,7 @@ class ListCtrl(core.Control): """ __init__(Window parent, int id=-1, Point pos=DefaultPosition, Size size=DefaultSize, long style=LC_ICON, - Validator validator=DefaultValidator, String name=wxPyListCtrlNameStr) -> ListCtrl + Validator validator=DefaultValidator, String name=ListCtrlNameStr) -> ListCtrl """ newobj = _controls.new_ListCtrl(*args, **kwargs) self.this = newobj.this @@ -3183,7 +3393,7 @@ class ListCtrl(core.Control): """ Create(Window parent, int id=-1, Point pos=DefaultPosition, Size size=DefaultSize, long style=LC_ICON, - Validator validator=DefaultValidator, String name=wxPyListCtrlNameStr) -> bool + Validator validator=DefaultValidator, String name=ListCtrlNameStr) -> bool """ return _controls.ListCtrl_Create(*args, **kwargs) @@ -3324,18 +3534,16 @@ class ListCtrl(core.Control): return _controls.ListCtrl_GetNextItem(*args, **kwargs) def GetImageList(*args, **kwargs): - """GetImageList(int which) -> wxImageList""" + """GetImageList(int which) -> ImageList""" return _controls.ListCtrl_GetImageList(*args, **kwargs) def SetImageList(*args, **kwargs): - """SetImageList(wxImageList imageList, int which)""" + """SetImageList(ImageList imageList, int which)""" return _controls.ListCtrl_SetImageList(*args, **kwargs) def AssignImageList(*args, **kwargs): - """AssignImageList(wxImageList imageList, int which)""" - val = _controls.ListCtrl_AssignImageList(*args, **kwargs) - args[1].thisown = 0 - return val + """AssignImageList(ImageList imageList, int which)""" + return _controls.ListCtrl_AssignImageList(*args, **kwargs) def IsVirtual(*args, **kwargs): """IsVirtual() -> bool""" @@ -3543,7 +3751,7 @@ class ListView(ListCtrl): """ __init__(Window parent, int id=-1, Point pos=DefaultPosition, Size size=DefaultSize, long style=LC_REPORT, - Validator validator=DefaultValidator, String name=wxPyListCtrlNameStr) -> ListView + Validator validator=DefaultValidator, String name=ListCtrlNameStr) -> ListView """ newobj = _controls.new_ListView(*args, **kwargs) self.this = newobj.this @@ -3555,7 +3763,7 @@ class ListView(ListCtrl): """ Create(Window parent, int id=-1, Point pos=DefaultPosition, Size size=DefaultSize, long style=LC_REPORT, - Validator validator=DefaultValidator, String name=wxPyListCtrlNameStr) -> bool + Validator validator=DefaultValidator, String name=ListCtrlNameStr) -> bool """ return _controls.ListView_Create(*args, **kwargs) @@ -3681,6 +3889,7 @@ class TreeItemIdPtr(TreeItemId): if not hasattr(self,"thisown"): self.thisown = 0 self.__class__ = TreeItemId _controls.TreeItemId_swigregister(TreeItemIdPtr) +TreeCtrlNameStr = cvar.TreeCtrlNameStr class TreeItemData(object): def __repr__(self): @@ -3845,7 +4054,7 @@ class TreeCtrl(core.Control): __init__(Window parent, int id=-1, Point pos=DefaultPosition, Size size=DefaultSize, long style=TR_DEFAULT_STYLE, Validator validator=DefaultValidator, - String name=wxPy_TreeCtrlNameStr) -> TreeCtrl + String name=TreeCtrlNameStr) -> TreeCtrl """ newobj = _controls.new_TreeCtrl(*args, **kwargs) self.this = newobj.this @@ -3858,7 +4067,7 @@ class TreeCtrl(core.Control): Create(Window parent, int id=-1, Point pos=DefaultPosition, Size size=DefaultSize, long style=TR_DEFAULT_STYLE, Validator validator=DefaultValidator, - String name=wxPy_TreeCtrlNameStr) -> bool + String name=TreeCtrlNameStr) -> bool """ return _controls.TreeCtrl_Create(*args, **kwargs) @@ -3887,32 +4096,28 @@ class TreeCtrl(core.Control): return _controls.TreeCtrl_SetSpacing(*args, **kwargs) def GetImageList(*args, **kwargs): - """GetImageList() -> wxImageList""" + """GetImageList() -> ImageList""" return _controls.TreeCtrl_GetImageList(*args, **kwargs) def GetStateImageList(*args, **kwargs): - """GetStateImageList() -> wxImageList""" + """GetStateImageList() -> ImageList""" return _controls.TreeCtrl_GetStateImageList(*args, **kwargs) def SetImageList(*args, **kwargs): - """SetImageList(wxImageList imageList)""" + """SetImageList(ImageList imageList)""" return _controls.TreeCtrl_SetImageList(*args, **kwargs) def SetStateImageList(*args, **kwargs): - """SetStateImageList(wxImageList imageList)""" + """SetStateImageList(ImageList imageList)""" return _controls.TreeCtrl_SetStateImageList(*args, **kwargs) def AssignImageList(*args, **kwargs): - """AssignImageList(wxImageList imageList)""" - val = _controls.TreeCtrl_AssignImageList(*args, **kwargs) - args[1].thisown = 0 - return val + """AssignImageList(ImageList imageList)""" + return _controls.TreeCtrl_AssignImageList(*args, **kwargs) def AssignStateImageList(*args, **kwargs): - """AssignStateImageList(wxImageList imageList)""" - val = _controls.TreeCtrl_AssignStateImageList(*args, **kwargs) - args[1].thisown = 0 - return val + """AssignStateImageList(ImageList imageList)""" + return _controls.TreeCtrl_AssignStateImageList(*args, **kwargs) def GetItemText(*args, **kwargs): """GetItemText(TreeItemId item) -> String""" @@ -4025,7 +4230,7 @@ class TreeCtrl(core.Control): return _controls.TreeCtrl_GetFirstChild(*args, **kwargs) def GetNextChild(*args, **kwargs): - """GetNextChild(TreeItemId item, wxTreeItemIdValue cookie) -> PyObject""" + """GetNextChild(TreeItemId item, void cookie) -> PyObject""" return _controls.TreeCtrl_GetNextChild(*args, **kwargs) def GetLastChild(*args, **kwargs): @@ -4116,14 +4321,22 @@ class TreeCtrl(core.Control): """Unselect()""" return _controls.TreeCtrl_Unselect(*args, **kwargs) + def UnselectItem(*args, **kwargs): + """UnselectItem(TreeItemId item)""" + return _controls.TreeCtrl_UnselectItem(*args, **kwargs) + def UnselectAll(*args, **kwargs): """UnselectAll()""" return _controls.TreeCtrl_UnselectAll(*args, **kwargs) def SelectItem(*args, **kwargs): - """SelectItem(TreeItemId item)""" + """SelectItem(TreeItemId item, bool select=True)""" return _controls.TreeCtrl_SelectItem(*args, **kwargs) + def ToggleItemSelection(*args, **kwargs): + """ToggleItemSelection(TreeItemId item)""" + return _controls.TreeCtrl_ToggleItemSelection(*args, **kwargs) + def EnsureVisible(*args, **kwargs): """EnsureVisible(TreeItemId item)""" return _controls.TreeCtrl_EnsureVisible(*args, **kwargs) @@ -4186,11 +4399,11 @@ class GenericDirCtrl(core.Control): return "<%s.%s; proxy of C++ wxGenericDirCtrl instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,) def __init__(self, *args, **kwargs): """ - __init__(Window parent, int id=-1, String dir=wxPyDirDialogDefaultFolderStr, + __init__(Window parent, int id=-1, String dir=DirDialogDefaultFolderStr, Point pos=DefaultPosition, Size size=DefaultSize, long style=wxDIRCTRL_3D_INTERNAL|wxSUNKEN_BORDER, String filter=EmptyString, - int defaultFilter=0, String name=wxPy_TreeCtrlNameStr) -> GenericDirCtrl + int defaultFilter=0, String name=TreeCtrlNameStr) -> GenericDirCtrl """ newobj = _controls.new_GenericDirCtrl(*args, **kwargs) self.this = newobj.this @@ -4200,11 +4413,11 @@ class GenericDirCtrl(core.Control): def Create(*args, **kwargs): """ - Create(Window parent, int id=-1, String dir=wxPyDirDialogDefaultFolderStr, + Create(Window parent, int id=-1, String dir=DirDialogDefaultFolderStr, Point pos=DefaultPosition, Size size=DefaultSize, long style=wxDIRCTRL_3D_INTERNAL|wxSUNKEN_BORDER, String filter=EmptyString, - int defaultFilter=0, String name=wxPy_TreeCtrlNameStr) -> bool + int defaultFilter=0, String name=TreeCtrlNameStr) -> bool """ return _controls.GenericDirCtrl_Create(*args, **kwargs) @@ -4261,7 +4474,7 @@ class GenericDirCtrl(core.Control): return _controls.GenericDirCtrl_GetRootId(*args, **kwargs) def GetTreeCtrl(*args, **kwargs): - """GetTreeCtrl() -> wxTreeCtrl""" + """GetTreeCtrl() -> TreeCtrl""" return _controls.GenericDirCtrl_GetTreeCtrl(*args, **kwargs) def GetFilterListCtrl(*args, **kwargs): @@ -4294,6 +4507,7 @@ class GenericDirCtrlPtr(GenericDirCtrl): if not hasattr(self,"thisown"): self.thisown = 0 self.__class__ = GenericDirCtrl _controls.GenericDirCtrl_swigregister(GenericDirCtrlPtr) +DirDialogDefaultFolderStr = cvar.DirDialogDefaultFolderStr def PreGenericDirCtrl(*args, **kwargs): """PreGenericDirCtrl() -> GenericDirCtrl""" @@ -4349,7 +4563,7 @@ class PyControl(core.Control): """ __init__(Window parent, int id, Point pos=DefaultPosition, Size size=DefaultSize, long style=0, Validator validator=DefaultValidator, - String name=wxPyControlNameStr) -> PyControl + String name=ControlNameStr) -> PyControl """ newobj = _controls.new_PyControl(*args, **kwargs) self.this = newobj.this @@ -4551,12 +4765,12 @@ class HelpProvider(object): def __repr__(self): return "<%s.%s; proxy of C++ wxHelpProvider instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,) def Set(*args, **kwargs): - """HelpProvider.Set(HelpProvider helpProvider) -> HelpProvider""" + """Set(HelpProvider helpProvider) -> HelpProvider""" return _controls.HelpProvider_Set(*args, **kwargs) Set = staticmethod(Set) def Get(*args, **kwargs): - """HelpProvider.Get() -> HelpProvider""" + """Get() -> HelpProvider""" return _controls.HelpProvider_Get(*args, **kwargs) Get = staticmethod(Get) @@ -4670,7 +4884,7 @@ class DragImage(core.Object): return _controls.DragImage_DoDrawImage(*args, **kwargs) def UpdateBackingFromWindow(*args, **kwargs): - """UpdateBackingFromWindow(DC windowDC, wxMemoryDC destDC, Rect sourceRect, Rect destRect) -> bool""" + """UpdateBackingFromWindow(DC windowDC, MemoryDC destDC, Rect sourceRect, Rect destRect) -> bool""" return _controls.DragImage_UpdateBackingFromWindow(*args, **kwargs) def RedrawImage(*args, **kwargs): @@ -4686,7 +4900,7 @@ class DragImagePtr(DragImage): _controls.DragImage_swigregister(DragImagePtr) def DragIcon(*args, **kwargs): - """DragIcon(wxIcon image, Cursor cursor=wxNullCursor) -> DragImage""" + """DragIcon(Icon image, Cursor cursor=wxNullCursor) -> DragImage""" val = _controls.new_DragIcon(*args, **kwargs) val.thisown = 1 return val