]>
Commit | Line | Data |
---|---|---|
1 | ///////////////////////////////////////////////////////////////////////////// | |
2 | // Name: wx/generic/statline.h | |
3 | // Purpose: a generic wxStaticLine class | |
4 | // Author: Vadim Zeitlin | |
5 | // Created: 28.06.99 | |
6 | // Version: $Id$ | |
7 | // Copyright: (c) 1998 Vadim Zeitlin | |
8 | // Licence: wxWindows licence | |
9 | ///////////////////////////////////////////////////////////////////////////// | |
10 | ||
11 | #ifndef _WX_GENERIC_STATLINE_H_ | |
12 | #define _WX_GENERIC_STATLINE_H_ | |
13 | ||
14 | class wxStaticBox; | |
15 | ||
16 | // ---------------------------------------------------------------------------- | |
17 | // wxStaticLine | |
18 | // ---------------------------------------------------------------------------- | |
19 | ||
20 | class WXDLLIMPEXP_CORE wxStaticLine : public wxStaticLineBase | |
21 | { | |
22 | DECLARE_DYNAMIC_CLASS(wxStaticLine) | |
23 | ||
24 | public: | |
25 | // constructors and pseudo-constructors | |
26 | wxStaticLine() { m_statbox = NULL; } | |
27 | ||
28 | wxStaticLine( wxWindow *parent, | |
29 | wxWindowID id = wxID_ANY, | |
30 | const wxPoint &pos = wxDefaultPosition, | |
31 | const wxSize &size = wxDefaultSize, | |
32 | long style = wxLI_HORIZONTAL, | |
33 | const wxString &name = wxStaticLineNameStr ) | |
34 | { | |
35 | Create(parent, id, pos, size, style, name); | |
36 | } | |
37 | ||
38 | virtual ~wxStaticLine(); | |
39 | ||
40 | bool Create( wxWindow *parent, | |
41 | wxWindowID id = wxID_ANY, | |
42 | const wxPoint &pos = wxDefaultPosition, | |
43 | const wxSize &size = wxDefaultSize, | |
44 | long style = wxLI_HORIZONTAL, | |
45 | const wxString &name = wxStaticLineNameStr ); | |
46 | ||
47 | // it's necessary to override this wxWindow function because we | |
48 | // will want to return the main widget for m_statbox | |
49 | // | |
50 | WXWidget GetMainWidget() const; | |
51 | ||
52 | // override wxWindow methods to make things work | |
53 | virtual void DoSetSize(int x, int y, int width, int height, | |
54 | int sizeFlags = wxSIZE_AUTO); | |
55 | virtual void DoMoveWindow(int x, int y, int width, int height); | |
56 | protected: | |
57 | // we implement the static line using a static box | |
58 | wxStaticBox *m_statbox; | |
59 | }; | |
60 | ||
61 | #endif // _WX_GENERIC_STATLINE_H_ | |
62 |