]> git.saurik.com Git - wxWidgets.git/blob - include/wx/univ/statbox.h
Add lambda-friendly wxDialog::ShowWindowModalThenDo().
[wxWidgets.git] / include / wx / univ / statbox.h
1 //////////////////////////////////////////////////////////////////////////////
2 // Name: wx/univ/statbox.h
3 // Purpose: wxStaticBox declaration
4 // Author: Vadim Zeitlin
5 // Modified by:
6 // Created: 15.08.00
7 // Copyright: (c) 2000 SciTech Software, Inc. (www.scitechsoft.com)
8 // Licence: wxWindows licence
9 ///////////////////////////////////////////////////////////////////////////////
10
11 #ifndef _WX_UNIV_STATBOX_H_
12 #define _WX_UNIV_STATBOX_H_
13
14 class WXDLLIMPEXP_CORE wxStaticBox : public wxStaticBoxBase
15 {
16 public:
17 wxStaticBox() { }
18
19 wxStaticBox(wxWindow *parent,
20 const wxString& label,
21 const wxPoint& pos = wxDefaultPosition,
22 const wxSize& size = wxDefaultSize)
23 {
24 Create(parent, wxID_ANY, label, pos, size);
25 }
26
27 wxStaticBox(wxWindow *parent, wxWindowID id,
28 const wxString& label,
29 const wxPoint& pos = wxDefaultPosition,
30 const wxSize& size = wxDefaultSize,
31 long style = 0,
32 const wxString& name = wxStaticBoxNameStr)
33 {
34 Create(parent, id, label, pos, size, style, name);
35 }
36
37 bool Create(wxWindow *parent,
38 wxWindowID id,
39 const wxString& label,
40 const wxPoint& pos = wxDefaultPosition,
41 const wxSize& size = wxDefaultSize,
42 long style = 0,
43 const wxString& name = wxStaticBoxNameStr);
44
45 // the origin of the static box is inside the border and under the label:
46 // take account of this
47 virtual wxPoint GetBoxAreaOrigin() const;
48
49 // returning true from here ensures that we act as a container window for
50 // our children
51 virtual bool IsStaticBox() const { return true; }
52
53 protected:
54 // draw the control
55 virtual void DoDraw(wxControlRenderer *renderer);
56
57 // get the size of the border
58 wxRect GetBorderGeometry() const;
59
60 private:
61 DECLARE_DYNAMIC_CLASS(wxStaticBox)
62 };
63
64 #endif // _WX_UNIV_STATBOX_H_