#include </home/zeitlin/src/wx/github/interface/wx/gbsizer.h>
The wxGBSizerItem class is used by the wxGridBagSizer for tracking the items in the sizer.
It adds grid position and spanning information to the normal wxSizerItem by adding wxGBPosition and wxGBSpan attributes. Most of the time you will not need to use a wxGBSizerItem directly in your code, but there are a couple of cases where it is handy.
Public Member Functions | |
wxGBSizerItem (int width, int height, const wxGBPosition &pos, const wxGBSpan &span=wxDefaultSpan, int flag=0, int border=0, wxObject *userData=NULL) | |
Construct a sizer item for tracking a spacer. | |
wxGBSizerItem (wxWindow *window, const wxGBPosition &pos, const wxGBSpan &span=wxDefaultSpan, int flag=0, int border=0, wxObject *userData=NULL) | |
Construct a sizer item for tracking a window. | |
wxGBSizerItem (wxSizer *sizer, const wxGBPosition &pos, const wxGBSpan &span=wxDefaultSpan, int flag=0, int border=0, wxObject *userData=NULL) | |
Construct a sizer item for tracking a subsizer. | |
void | GetEndPos (int &row, int &col) |
Get the row and column of the endpoint of this item. | |
bool | Intersects (const wxGBSizerItem &other) |
Returns true if this item and the other item intersect. | |
bool | Intersects (const wxGBPosition &pos, const wxGBSpan &span) |
Returns true if the given pos/span would intersect with this item. | |
bool | SetPos (const wxGBPosition &pos) |
If the item is already a member of a sizer then first ensure that there is no other item that would intersect with this one at the new position, then set the new position. | |
bool | SetSpan (const wxGBSpan &span) |
If the item is already a member of a sizer then first ensure that there is no other item that would intersect with this one with its new spanning size, then set the new spanning. | |
wxGridBagSizer * | GetGBSizer () const |
void | SetGBSizer (wxGridBagSizer *sizer) |
wxGBPosition | GetPos () const |
Get the grid position of the item. | |
void | GetPos (int &row, int &col) const |
Get the grid position of the item. | |
wxGBSpan | GetSpan () const |
Get the row and column spanning of the item. | |
void | GetSpan (int &rowspan, int &colspan) const |
Get the row and column spanning of the item. |
wxGBSizerItem::wxGBSizerItem | ( | int | width, |
int | height, | ||
const wxGBPosition & | pos, | ||
const wxGBSpan & | span = wxDefaultSpan , |
||
int | flag = 0 , |
||
int | border = 0 , |
||
wxObject * | userData = NULL |
||
) |
Construct a sizer item for tracking a spacer.
wxGBSizerItem::wxGBSizerItem | ( | wxWindow * | window, |
const wxGBPosition & | pos, | ||
const wxGBSpan & | span = wxDefaultSpan , |
||
int | flag = 0 , |
||
int | border = 0 , |
||
wxObject * | userData = NULL |
||
) |
Construct a sizer item for tracking a window.
wxGBSizerItem::wxGBSizerItem | ( | wxSizer * | sizer, |
const wxGBPosition & | pos, | ||
const wxGBSpan & | span = wxDefaultSpan , |
||
int | flag = 0 , |
||
int | border = 0 , |
||
wxObject * | userData = NULL |
||
) |
Construct a sizer item for tracking a subsizer.
void wxGBSizerItem::GetEndPos | ( | int & | row, |
int & | col | ||
) |
Get the row and column of the endpoint of this item.
wxGridBagSizer* wxGBSizerItem::GetGBSizer | ( | ) | const |
wxGBPosition wxGBSizerItem::GetPos | ( | ) | const |
Get the grid position of the item.
void wxGBSizerItem::GetPos | ( | int & | row, |
int & | col | ||
) | const |
Get the grid position of the item.
wxGBSpan wxGBSizerItem::GetSpan | ( | ) | const |
Get the row and column spanning of the item.
void wxGBSizerItem::GetSpan | ( | int & | rowspan, |
int & | colspan | ||
) | const |
Get the row and column spanning of the item.
bool wxGBSizerItem::Intersects | ( | const wxGBPosition & | pos, |
const wxGBSpan & | span | ||
) |
Returns true if the given pos/span would intersect with this item.
bool wxGBSizerItem::Intersects | ( | const wxGBSizerItem & | other | ) |
Returns true if this item and the other item intersect.
void wxGBSizerItem::SetGBSizer | ( | wxGridBagSizer * | sizer | ) |
bool wxGBSizerItem::SetPos | ( | const wxGBPosition & | pos | ) |
If the item is already a member of a sizer then first ensure that there is no other item that would intersect with this one at the new position, then set the new position.
Returns true if the change is successful and after the next Layout the item will be moved.
bool wxGBSizerItem::SetSpan | ( | const wxGBSpan & | span | ) |
If the item is already a member of a sizer then first ensure that there is no other item that would intersect with this one with its new spanning size, then set the new spanning.
Returns true if the change is successful and after the next Layout the item will be resized.