X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/6e6b35578d9be94739e1f9ebadcb57d9a483db6a..46ae103b9f08fc4e447d16a6a92b03cf55ee3189:/wxPython/src/_sizers.i diff --git a/wxPython/src/_sizers.i b/wxPython/src/_sizers.i index 6f033ef9c6..1846e410d0 100644 --- a/wxPython/src/_sizers.i +++ b/wxPython/src/_sizers.i @@ -145,7 +145,7 @@ added, if needed.", ""); DocStr(SetRatio, "Set the ratio item attribute.", ""); %Rename(SetRatioWH, void, SetRatio( int width, int height )); - %Rename(SetRatioSize, void, SetRatio( wxSize size )); + %Rename(SetRatioSize, void, SetRatio( const wxSize& size )); void SetRatio( float ratio ); DocDeclStr( @@ -364,6 +364,12 @@ standard font as well as the overall design of Mac widgets requires more space than on Windows, then the initial size of a dialog using a sizer will automatically be bigger on Mac than on Windows.", " +Sizers may also be used to control the layout of custom drawn items on +the window. The `Add`, `Insert`, and `Prepend` functions return a +pointer to the newly added `wx.SizerItem`. Just add empty space of the +desired size and attributes, and then use the `wx.SizerItem.GetRect` +method to determine where the drawing operations should take place. + :note: If you wish to create a custom sizer class in wxPython you should derive the class from `wx.PySizer` in order to get Python-aware capabilities for the various virtual methods. @@ -450,7 +456,7 @@ public: |- wx.ALL | | | | | +----------------------------+------------------------------------------+ - |- wx.EXAPAND |The item will be expanded to fill | + |- wx.EXPAND |The item will be expanded to fill | | |the space allotted to the item. | +----------------------------+------------------------------------------+ |- wx.SHAPED |The item will be expanded as much as | @@ -629,7 +635,7 @@ was found and detached.", ""); "GetItem(self, item) -> wx.SizerItem", "Returns the `wx.SizerItem` which holds the *item* given. The *item* parameter can be either a window, a sizer, or the zero-based index of -the item to be detached.", ""); +the item to be found.", ""); wxSizerItem* GetItem(PyObject* item) { wxPyBlock_t blocked = wxPyBeginBlockThreads(); wxPySizerItemInfo info = wxPySizerItemTypeHelper(item, false, true); @@ -926,7 +932,7 @@ the item.", ""); %pythoncode { def Hide(self, item, recursive=False): """ - A convenience method for Show(item, False, recursive). + A convenience method for `Show` (item, False, recursive). """ return self.Show(item, False, recursive) } @@ -936,6 +942,10 @@ the item.", ""); void , ShowItems(bool show), "Recursively call `wx.SizerItem.Show` on all sizer items.", ""); + // TODO: + // void Show(bool show); + // bool IsShown(); + };