name wxStaticBoxSizer; some other minor wording clarifications

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@60245 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Francesco Montorsi
2009-04-19 19:46:36 +00:00
parent ea0022d356
commit f3289ffb1f
2 changed files with 22 additions and 15 deletions

View File

@@ -1636,11 +1636,12 @@ public:
/** /**
@class wxStaticBoxSizer @class wxStaticBoxSizer
wxStaticBoxSizer is a sizer derived from wxBoxSizer but adds a static wxStaticBoxSizer is a sizer derived from wxBoxSizer but adds a static box around
box around the sizer. 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 The static box may be either created independently or the sizer may create it
and will delete it, if it is deleted. itself as a convenience. In any case, the sizer owns the wxStaticBox control
and will delete it in the wxStaticBoxSizer destructor.
@library{wxcore} @library{wxcore}
@category{winlayout} @category{winlayout}
@@ -1653,8 +1654,11 @@ public:
/** /**
This constructor uses an already existing static box. This constructor uses an already existing static box.
It takes the associated static box and the orientation @a orient, which @param box
can be either @c wxVERTICAL or @c wxHORIZONTAL as parameters. 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); wxStaticBoxSizer(wxStaticBox* box, int orient);

View File

@@ -9,24 +9,27 @@
/** /**
@class wxStaticBox @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. a logical grouping of items.
Please note that a static box should @b not be used as the parent for the 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 controls it contains, instead they should be @b siblings of each other.
using a static box as a parent might work in some versions of wxWidgets, it Although using a static box as a parent might work in some ports of wxWidgets,
results in a crash under, for example, wxGTK. 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 Also, please note that because of this, the order in which you create new
controls is important. Create your wxStaticBox control @b before any controls is important. Create your wxStaticBox control @b before any
siblings that are to appear inside the wxStaticBox in order to preserve the 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} @library{wxcore}
@category{ctrl} @category{ctrl}
@appearance{staticbox.png} @appearance{staticbox.png}
@see wxStaticText @see wxStaticText, wxStaticBoxSizer
*/ */
class wxStaticBox : public wxControl class wxStaticBox : public wxControl
{ {
@@ -47,10 +50,10 @@ public:
Text to be displayed in the static box, the empty string for no label. Text to be displayed in the static box, the empty string for no label.
@param pos @param pos
Window position. Window position.
If wxDefaultPosition is specified then a default position is chosen. If ::wxDefaultPosition is specified then a default position is chosen.
@param size @param size
Checkbox 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 @param style
Window style. See wxStaticBox. Window style. See wxStaticBox.
@param name @param name