RA_VERTICAL = _core_.RA_VERTICAL
RA_SPECIFY_ROWS = _core_.RA_SPECIFY_ROWS
RA_SPECIFY_COLS = _core_.RA_SPECIFY_COLS
+RA_USE_CHECKBOX = _core_.RA_USE_CHECKBOX
RB_GROUP = _core_.RB_GROUP
RB_SINGLE = _core_.RB_SINGLE
-SL_HORIZONTAL = _core_.SL_HORIZONTAL
-SL_VERTICAL = _core_.SL_VERTICAL
-SL_AUTOTICKS = _core_.SL_AUTOTICKS
-SL_LABELS = _core_.SL_LABELS
-SL_LEFT = _core_.SL_LEFT
-SL_TOP = _core_.SL_TOP
-SL_RIGHT = _core_.SL_RIGHT
-SL_BOTTOM = _core_.SL_BOTTOM
-SL_BOTH = _core_.SL_BOTH
-SL_SELRANGE = _core_.SL_SELRANGE
SB_HORIZONTAL = _core_.SB_HORIZONTAL
SB_VERTICAL = _core_.SB_VERTICAL
+RB_USE_CHECKBOX = _core_.RB_USE_CHECKBOX
ST_SIZEGRIP = _core_.ST_SIZEGRIP
ST_NO_AUTORESIZE = _core_.ST_NO_AUTORESIZE
FLOOD_SURFACE = _core_.FLOOD_SURFACE
"""
Inflate(self, int dx, int dy) -> Rect
- Increase the rectangle size by dx in x direction and dy in y
- direction. Both (or one of) parameters may be negative to decrease the
- rectangle size.
+ Increases the size of the rectangle.
+
+ The left border is moved farther left and the right border is moved
+ farther right by ``dx``. The upper border is moved farther up and the
+ bottom border is moved farther down by ``dy``. (Note the the width and
+ height of the rectangle thus change by ``2*dx`` and ``2*dy``,
+ respectively.) If one or both of ``dx`` and ``dy`` are negative, the
+ opposite happens: the rectangle size decreases in the respective
+ direction.
+
+ The change is made to the rectangle inplace, if instead you need a
+ copy that is inflated, preserving the original then make the copy
+ first::
+
+ copy = wx.Rect(*original)
+ copy.Inflate(10,15)
+
+
"""
return _core_.Rect_Inflate(*args, **kwargs)
"""
Deflate(self, int dx, int dy) -> Rect
- Decrease the rectangle size by dx in x direction and dy in y
- direction. Both (or one of) parameters may be negative to increase the
- rectngle size. This method is the opposite of Inflate.
+ Decrease the rectangle size. This method is the opposite of `Inflate`
+ in that Deflate(a,b) is equivalent to Inflate(-a,-b). Please refer to
+ `Inflate` for a full description.
"""
return _core_.Rect_Deflate(*args, **kwargs)
return _core_.Event_IsCommandEvent(*args, **kwargs)
def Skip(*args, **kwargs):
- """Skip(self, bool skip=True)"""
+ """
+ Skip(self, bool skip=True)
+
+ Called by an event handler, it controls whether additional event
+ handlers bound to this event will be called after the current event
+ handler returns. Skip(false) (the default setting) will prevent
+ additional event handlers from being called and control will be
+ returned to the sender of the event immediately after the current
+ handler has finished. Skip(True) will cause the event processing
+ system to continue searching for a handler function for this event.
+
+ """
return _core_.Event_Skip(*args, **kwargs)
def GetSkipped(*args, **kwargs):
"""SetPosition(self, Point pos)"""
return _core_.MoveEvent_SetPosition(*args, **kwargs)
- m_pos = property(_core_.MoveEvent_m_pos_get, _core_.MoveEvent_m_pos_set)
- m_rect = property(_core_.MoveEvent_m_rect_get, _core_.MoveEvent_m_rect_set)
+ m_pos = property(GetPosition, SetPosition)
+ m_rect = property(GetRect, SetRect)
+
class MoveEventPtr(MoveEvent):
def __init__(self, this):
self.__class__ = PyCommandEvent
_core_.PyCommandEvent_swigregister(PyCommandEventPtr)
+class DateEvent(CommandEvent):
+ """Proxy of C++ DateEvent class"""
+ def __repr__(self):
+ return "<%s.%s; proxy of C++ wxDateEvent instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
+ def __init__(self, *args, **kwargs):
+ """__init__(self, Window win, DateTime dt, wxEventType type) -> DateEvent"""
+ newobj = _core_.new_DateEvent(*args, **kwargs)
+ self.this = newobj.this
+ self.thisown = 1
+ del newobj.thisown
+ def GetDate(*args, **kwargs):
+ """GetDate(self) -> DateTime"""
+ return _core_.DateEvent_GetDate(*args, **kwargs)
+
+ def SetDate(*args, **kwargs):
+ """SetDate(self, DateTime date)"""
+ return _core_.DateEvent_SetDate(*args, **kwargs)
+
+
+class DateEventPtr(DateEvent):
+ def __init__(self, this):
+ self.this = this
+ if not hasattr(self,"thisown"): self.thisown = 0
+ self.__class__ = DateEvent
+_core_.DateEvent_swigregister(DateEventPtr)
+
+wxEVT_DATE_CHANGED = _core_.wxEVT_DATE_CHANGED
+EVT_DATE_CHANGED = wx.PyEventBinder( wxEVT_DATE_CHANGED, 1 )
+
#---------------------------------------------------------------------------
PYAPP_ASSERT_SUPPRESS = _core_.PYAPP_ASSERT_SUPPRESS
def RefreshRect(*args, **kwargs):
"""
- RefreshRect(self, Rect rect)
+ RefreshRect(self, Rect rect, bool eraseBackground=True)
Redraws the contents of the given rectangle: the area inside it will
be repainted. This is the same as Refresh but has a nicer syntax.
"""
return _core_.Window_GetBackgroundStyle(*args, **kwargs)
+ def HasTransparentBackground(*args, **kwargs):
+ """
+ HasTransparentBackground(self) -> bool
+
+ Returns True if this window's background is transparent (as, for
+ example, for `wx.StaticText`) and should show the parent window's
+ background.
+
+ This method is mostly used internally by the library itself and you
+ normally shouldn't have to call it. You may, however, have to override
+ it in your custom control classes to ensure that background is painted
+ correctly.
+ """
+ return _core_.Window_HasTransparentBackground(*args, **kwargs)
+
def SetCursor(*args, **kwargs):
"""
SetCursor(self, Cursor cursor) -> bool
class ItemContainer(object):
"""
- wx.ItemContainer defines an interface which is implemented by all
- controls which have string subitems, each of which may be selected,
- such as `wx.ListBox`, `wx.CheckListBox`, `wx.Choice` as well as
- `wx.ComboBox` which implements an extended interface deriving from
+ The wx.ItemContainer class defines an interface which is implemented
+ by all controls which have string subitems, each of which may be
+ selected, such as `wx.ListBox`, `wx.CheckListBox`, `wx.Choice` as well
+ as `wx.ComboBox` which implements an extended interface deriving from
this one.
It defines the methods for accessing the control's items and although
"""
return _core_.ItemContainer_Delete(*args, **kwargs)
+ def GetClientData(*args, **kwargs):
+ """
+ GetClientData(self, int n) -> PyObject
+
+ Returns the client data associated with the given item, (if any.)
+ """
+ return _core_.ItemContainer_GetClientData(*args, **kwargs)
+
+ def SetClientData(*args, **kwargs):
+ """
+ SetClientData(self, int n, PyObject clientData)
+
+ Associate the given client data with the item at position n.
+ """
+ return _core_.ItemContainer_SetClientData(*args, **kwargs)
+
def GetCount(*args, **kwargs):
"""
GetCount(self) -> int
"""
return _core_.ItemContainer_FindString(*args, **kwargs)
- def Select(*args, **kwargs):
+ def SetSelection(*args, **kwargs):
"""
- Select(self, int n)
+ SetSelection(self, int n)
Sets the item at index 'n' to be the selected item.
"""
- return _core_.ItemContainer_Select(*args, **kwargs)
+ return _core_.ItemContainer_SetSelection(*args, **kwargs)
- SetSelection = Select
def GetSelection(*args, **kwargs):
"""
GetSelection(self) -> int
"""
return _core_.ItemContainer_GetSelection(*args, **kwargs)
+ def SetStringSelection(*args, **kwargs):
+ """SetStringSelection(self, String s) -> bool"""
+ return _core_.ItemContainer_SetStringSelection(*args, **kwargs)
+
def GetStringSelection(*args, **kwargs):
"""
GetStringSelection(self) -> String
"""
return _core_.ItemContainer_GetStringSelection(*args, **kwargs)
- def GetClientData(*args, **kwargs):
- """
- GetClientData(self, int n) -> PyObject
-
- Returns the client data associated with the given item, (if any.)
- """
- return _core_.ItemContainer_GetClientData(*args, **kwargs)
-
- def SetClientData(*args, **kwargs):
+ def Select(*args, **kwargs):
"""
- SetClientData(self, int n, PyObject clientData)
+ Select(self, int n)
- Associate the given client data with the item at position n.
+ This is the same as `SetSelection` and exists only because it is
+ slightly more natural for controls which support multiple selection.
"""
- return _core_.ItemContainer_SetClientData(*args, **kwargs)
+ return _core_.ItemContainer_Select(*args, **kwargs)
class ItemContainerPtr(ItemContainer):
def GetChildren(*args, **kwargs):
"""
- GetChildren(sefl) -> list
+ GetChildren(self) -> list
Returns a list of all the `wx.SizerItem` objects managed by the sizer.
"""
A special sizer that knows how to order and position standard buttons
in order to conform to the current platform's standards. You simply
need to add each `wx.Button` to the sizer, and be sure to create the
- buttons using the standard ID's. Then call `Finalize` and the sizer
+ buttons using the standard ID's. Then call `Realize` and the sizer
will take care of the rest.
"""
"""
return _core_.StdDialogButtonSizer_AddButton(*args, **kwargs)
- def Finalise(*args, **kwargs):
+ def Realize(*args, **kwargs):
"""
- Finalise(self)
+ Realize(self)
This funciton needs to be called after all the buttons have been added
to the sizer. It will reorder them and position them in a platform
specifc manner.
"""
- return _core_.StdDialogButtonSizer_Finalise(*args, **kwargs)
+ return _core_.StdDialogButtonSizer_Realize(*args, **kwargs)
+
+ def SetAffirmativeButton(*args, **kwargs):
+ """SetAffirmativeButton(self, wxButton button)"""
+ return _core_.StdDialogButtonSizer_SetAffirmativeButton(*args, **kwargs)
+
+ def SetNegativeButton(*args, **kwargs):
+ """SetNegativeButton(self, wxButton button)"""
+ return _core_.StdDialogButtonSizer_SetNegativeButton(*args, **kwargs)
+
+ def SetCancelButton(*args, **kwargs):
+ """SetCancelButton(self, wxButton button)"""
+ return _core_.StdDialogButtonSizer_SetCancelButton(*args, **kwargs)
def GetAffirmativeButton(*args, **kwargs):
"""GetAffirmativeButton(self) -> wxButton"""