]> git.saurik.com Git - wxWidgets.git/blame - interface/wx/statbox.h
no real change; just add the standard separator where it's missing
[wxWidgets.git] / interface / wx / statbox.h
CommitLineData
23324ae1
FM
1/////////////////////////////////////////////////////////////////////////////
2// Name: statbox.h
e54c96f1 3// Purpose: interface of wxStaticBox
23324ae1
FM
4// Author: wxWidgets team
5// RCS-ID: $Id$
6// Licence: wxWindows license
7/////////////////////////////////////////////////////////////////////////////
8
9/**
10 @class wxStaticBox
7c913512 11
f3289ffb 12 A static box is a rectangle drawn around other windows to denote
23324ae1 13 a logical grouping of items.
7c913512 14
23324ae1 15 Please note that a static box should @b not be used as the parent for the
f3289ffb
FM
16 controls it contains, instead they should be @b siblings of each other.
17 Although using a static box as a parent might work in some ports of wxWidgets,
18 it would result in a crash under, for example, wxGTK, and thus it's explicitely
19 disallowed (an assertion will fail if you try to add children to a wxStaticBox).
7c913512
FM
20
21 Also, please note that because of this, the order in which you create new
22 controls is important. Create your wxStaticBox control @b before any
23 siblings that are to appear inside the wxStaticBox in order to preserve the
f3289ffb
FM
24 correct Z-order of controls.
25
26 You may want to use wxStaticBoxSizer instead of wxStaticBox to avoid this problem.
7c913512 27
23324ae1
FM
28 @library{wxcore}
29 @category{ctrl}
7e59b885 30 @appearance{staticbox.png}
7c913512 31
f3289ffb 32 @see wxStaticText, wxStaticBoxSizer
23324ae1
FM
33*/
34class wxStaticBox : public wxControl
35{
36public:
671600d8
RR
37 /**
38 Default constructor
39 */
40 wxStaticBox();
4701dc09 41
23324ae1
FM
42 /**
43 Constructor, creating and showing a static box.
3c4f71cc 44
7c913512 45 @param parent
4cc4bfaf 46 Parent window. Must not be @NULL.
7c913512 47 @param id
4cc4bfaf 48 Window identifier. The value wxID_ANY indicates a default value.
7c913512 49 @param label
4cc4bfaf 50 Text to be displayed in the static box, the empty string for no label.
7c913512 51 @param pos
4701dc09 52 Window position.
f3289ffb 53 If ::wxDefaultPosition is specified then a default position is chosen.
7c913512 54 @param size
4701dc09 55 Checkbox size.
f3289ffb 56 If ::wxDefaultSize is specified then a default size is chosen.
7c913512 57 @param style
4cc4bfaf 58 Window style. See wxStaticBox.
7c913512 59 @param name
4cc4bfaf 60 Window name.
3c4f71cc 61
4cc4bfaf 62 @see Create()
23324ae1 63 */
7c913512
FM
64 wxStaticBox(wxWindow* parent, wxWindowID id,
65 const wxString& label,
66 const wxPoint& pos = wxDefaultPosition,
67 const wxSize& size = wxDefaultSize,
68 long style = 0,
11e3af6e 69 const wxString& name = wxStaticBoxNameStr);
23324ae1
FM
70
71 /**
72 Destructor, destroying the group box.
73 */
adaaa686 74 virtual ~wxStaticBox();
23324ae1
FM
75
76 /**
4701dc09
FM
77 Creates the static box for two-step construction.
78 See wxStaticBox() for further details.
23324ae1 79 */
5267aefd 80 bool Create(wxWindow* parent, wxWindowID id, const wxString& label,
23324ae1 81 const wxPoint& pos = wxDefaultPosition,
5267aefd
FM
82 const wxSize& size = wxDefaultSize, long style = 0,
83 const wxString& name = wxStaticBoxNameStr);
23324ae1 84};
e54c96f1 85