]>
git.saurik.com Git - wxWidgets.git/blob - include/wx/msw/statbox.h
836de6c3bf35165150e69a4bcdc098880516170d
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: wx/msw/statbox.h
3 // Purpose: wxStaticBox class
4 // Author: Julian Smart
8 // Copyright: (c) Julian Smart
9 // Licence: wxWindows licence
10 /////////////////////////////////////////////////////////////////////////////
12 #ifndef _WX_MSW_STATBOX_H_
13 #define _WX_MSW_STATBOX_H_
15 #if defined(__GNUG__) && !defined(NO_GCC_PRAGMA)
16 #pragma interface "statbox.h"
20 class WXDLLEXPORT wxStaticBox
: public wxStaticBoxBase
25 wxStaticBox(wxWindow
*parent
, wxWindowID id
,
26 const wxString
& label
,
27 const wxPoint
& pos
= wxDefaultPosition
,
28 const wxSize
& size
= wxDefaultSize
,
30 const wxString
& name
= wxStaticBoxNameStr
)
32 Create(parent
, id
, label
, pos
, size
, style
, name
);
35 bool Create(wxWindow
*parent
, wxWindowID id
,
36 const wxString
& label
,
37 const wxPoint
& pos
= wxDefaultPosition
,
38 const wxSize
& size
= wxDefaultSize
,
40 const wxString
& name
= wxStaticBoxNameStr
);
42 /// Implementation only
43 virtual void GetBordersForSizer(int *borderTop
, int *borderOther
) const;
46 virtual wxSize
DoGetBestSize() const;
48 // choose the default border for this window
49 virtual wxBorder
GetDefaultBorder() const;
51 virtual WXDWORD
MSWGetStyle(long style
, WXDWORD
*exstyle
) const;
54 virtual WXLRESULT
MSWWindowProc(WXUINT nMsg
, WXWPARAM wParam
, WXLPARAM lParam
);
56 // return the region with all the windows inside this static box excluded
57 virtual WXHRGN
MSWGetRegionWithoutChildren();
59 // remove the parts which are painted by static box itself from the given
60 // region which is embedded in a rectangle (0, 0)-(w, h)
61 virtual void MSWGetRegionWithoutSelf(WXHRGN hrgn
, int w
, int h
);
63 // paint the given rectangle with our background brush/colour
64 void PaintBackground(wxDC
& dc
, const struct tagRECT
& rc
);
65 // paint the foreground of the static box
66 virtual void PaintForeground(wxDC
& dc
, const struct tagRECT
& rc
);
68 void OnPaint(wxPaintEvent
& event
);
69 #endif // !__WXWINCE__
71 DECLARE_DYNAMIC_CLASS_NO_COPY(wxStaticBox
)
74 #endif // _WX_MSW_STATBOX_H_