/**
@class wxStaticBoxSizer
- wxStaticBoxSizer is a sizer derived from wxBoxSizer but adds a static
- box around the sizer.
- This static box may be either created independently or the sizer may create
- it itself as a convenience. In any case, the sizer owns the wxStaticBox control
- and will delete it, if it is deleted.
+ wxStaticBoxSizer is a sizer derived from wxBoxSizer but adds a static box around
+ the sizer.
+
+ The static box may be either created independently or the sizer may create it
+ itself as a convenience. In any case, the sizer owns the wxStaticBox control
+ and will delete it in the wxStaticBoxSizer destructor.
@library{wxcore}
@category{winlayout}
/**
This constructor uses an already existing static box.
- It takes the associated static box and the orientation @a orient, which
- can be either @c wxVERTICAL or @c wxHORIZONTAL as parameters.
+ @param box
+ The static box to associate with the sizer (which will take its
+ ownership).
+ @param orient
+ Can be either @c wxVERTICAL or @c wxHORIZONTAL.
*/
wxStaticBoxSizer(wxStaticBox* box, int orient);
/**
@class wxStaticBox
- A static box is a rectangle drawn around other panel items to denote
+ A static box is a rectangle drawn around other windows to denote
a logical grouping of items.
Please note that a static box should @b not be used as the parent for the
- controls it contains, instead they should be siblings of each other. Although
- using a static box as a parent might work in some versions of wxWidgets, it
- results in a crash under, for example, wxGTK.
+ controls it contains, instead they should be @b siblings of each other.
+ Although using a static box as a parent might work in some ports of wxWidgets,
+ it would result in a crash under, for example, wxGTK, and thus it's explicitely
+ disallowed (an assertion will fail if you try to add children to a wxStaticBox).
Also, please note that because of this, the order in which you create new
controls is important. Create your wxStaticBox control @b before any
siblings that are to appear inside the wxStaticBox in order to preserve the
- correct Z-Order of controls.
+ correct Z-order of controls.
+
+ You may want to use wxStaticBoxSizer instead of wxStaticBox to avoid this problem.
@library{wxcore}
@category{ctrl}
@appearance{staticbox.png}
- @see wxStaticText
+ @see wxStaticText, wxStaticBoxSizer
*/
class wxStaticBox : public wxControl
{
Text to be displayed in the static box, the empty string for no label.
@param pos
Window position.
- If wxDefaultPosition is specified then a default position is chosen.
+ If ::wxDefaultPosition is specified then a default position is chosen.
@param size
Checkbox size.
- If wxDefaultSize is specified then a default size is chosen.
+ If ::wxDefaultSize is specified then a default size is chosen.
@param style
Window style. See wxStaticBox.
@param name