wxsizeritemthe wxsizeritem class is used to track the position, size and other attributes of each item managed by a wxsizer. it is not usually necessary to use this class because the sizer elements can also be identified by their positions or window or sizer pointers but sometimes it may be more convenient to use it directly. derived from include files <wx/sizer.h> members
wxsizeritem::wxsizeritem
wxsizeritem::wxsizeritemwxsizeritem(int width, int height, int proportion, int flag, int border, wxobject* userdata) construct a sizer item for tracking a spacer. wxsizeritem(wxwindow* window, const wxsizerflags& flags) wxsizeritem(wxwindow* window, int proportion, int flag, int border, wxobject* userdata) construct a sizer item for tracking a window. wxsizeritem(wxsizer* window, const wxsizerflags& flags) wxsizeritem(wxsizer* sizer, int proportion, int flag, int border, wxobject* userdata) construct a sizer item for tracking a subsizer.
wxsizeritem::~wxsizeritem~wxsizeritem() deletes the user data and subsizer, if any.
wxsizeritem::calcminwxsize calcmin() calculates the minimum desired size for the item, including any space needed by borders.
wxsizeritem::deletewindowsvoid deletewindows() destroy the window or the windows in a subsizer, depending on the type of item.
wxsizeritem::detachsizervoid detachsizer() enable deleting the sizeritem without destroying the contained sizer.
wxsizeritem::getborderint getborder() const return the border attribute.
wxsizeritem::getflagint getflag() const return the flags attribute.
wxsizeritem::getminsizewxsize getminsize() const get the minimum size needed for the item.
wxsizeritem::getpositionwxpoint getposition() const what is the current position of the item, as set in the last layout.
wxsizeritem::getproportionint getproportion() const get the proportion item attribute.
wxsizeritem::getratiofloat getratio() const get the ration item attribute.
wxsizeritem::getrectwxrect getrect() get the rectangle of the item on the parent window, excluding borders.
wxsizeritem::getsizewxsize getsize() const get the current size of the item, as set in the last layout.
wxsizeritem::getsizerwxsizer* getsizer() const if this item is tracking a sizer, return it. null otherwise.
wxsizeritem::getspacerconst wxsize& getspacer() const if this item is tracking a spacer, return its size.
wxsizeritem::getuserdatawxobject* getuserdata() const get the userdata item attribute.
wxsizeritem::getwindowwxwindow* getwindow() const if this item is tracking a window then return it. null otherwise.
wxsizeritem::issizerbool issizer() const is this item a sizer?
wxsizeritem::isshownbool isshown() const returns true if this item is a window or a spacer and it is shown or if this item is a sizer and not all its elements are hidden. in other words, for sizer items, all of the child elements must be hidden for the sizer itself to be considered hidden.
wxsizeritem::isspacerbool isspacer() const is this item a spacer?
wxsizeritem::iswindowbool iswindow() const is this item a window?
wxsizeritem::setbordervoid setborder(int border) set the border item attribute.
wxsizeritem::setdimensionvoid setdimension(const wxpoint& pos, const wxsize& size) set the position and size of the space allocated to the sizer, and adjust the position and size of the item to be within that space taking alignment and borders into account.
wxsizeritem::setflagvoid setflag(int flag) set the flag item attribute.
wxsizeritem::setinitsizevoid setinitsize(int x, int y)
wxsizeritem::setproportionvoid setproportion(int proportion) set the proportion item attribute.
wxsizeritem::setratiovoid setratio(int width, int height) void setratio(wxsize size) void setratio(float ratio) set the ratio item attribute.
wxsizeritem::setsizervoid setsizer(wxsizer* sizer) set the sizer tracked by this item.
wxsizeritem::setspacervoid setspacer(const wxsize& size) set the size of the spacer tracked by this item.
wxsizeritem::setwindowvoid setwindow(wxwindow* window) set the window to be tracked by thsi item.
wxsizeritem::showvoid show(bool show) set the show item attribute, which sizers use to determine if the item is to be made part of the layout or not. if the item is tracking a window then it is shown or hidden as needed.
|