]>
Commit | Line | Data |
---|---|---|
c801d85f KB |
1 | ///////////////////////////////////////////////////////////////////////////// |
2 | // Name: button.h | |
3 | // Purpose: | |
4 | // Author: Robert Roebling | |
dbf858b5 | 5 | // Id: $Id$ |
01111366 | 6 | // Copyright: (c) 1998 Robert Roebling |
c801d85f KB |
7 | // Licence: wxWindows licence |
8 | ///////////////////////////////////////////////////////////////////////////// | |
9 | ||
10 | ||
11 | #ifndef __GTKBUTTONH__ | |
12 | #define __GTKBUTTONH__ | |
13 | ||
14 | #ifdef __GNUG__ | |
15 | #pragma interface | |
16 | #endif | |
17 | ||
18 | #include "wx/defs.h" | |
19 | #include "wx/object.h" | |
20 | #include "wx/list.h" | |
21 | #include "wx/control.h" | |
22 | ||
23 | //----------------------------------------------------------------------------- | |
24 | // classes | |
25 | //----------------------------------------------------------------------------- | |
26 | ||
27 | class wxButton; | |
28 | ||
29 | //----------------------------------------------------------------------------- | |
30 | // global data | |
31 | //----------------------------------------------------------------------------- | |
32 | ||
33 | extern const char *wxButtonNameStr; | |
34 | ||
35 | //----------------------------------------------------------------------------- | |
36 | // wxButton | |
37 | //----------------------------------------------------------------------------- | |
38 | ||
39 | class wxButton: public wxControl | |
40 | { | |
41 | DECLARE_DYNAMIC_CLASS(wxButton) | |
42 | ||
43 | public: | |
44 | ||
fd0eed64 | 45 | wxButton(); |
6de97a3b RR |
46 | inline wxButton(wxWindow *parent, wxWindowID id, const wxString& label, |
47 | const wxPoint& pos = wxDefaultPosition, | |
48 | const wxSize& size = wxDefaultSize, long style = 0, | |
49 | const wxValidator& validator = wxDefaultValidator, | |
50 | const wxString& name = wxButtonNameStr) | |
51 | { | |
52 | Create(parent, id, label, pos, size, style, validator, name); | |
53 | } | |
fd0eed64 | 54 | ~wxButton(); |
6de97a3b RR |
55 | bool Create(wxWindow *parent, wxWindowID id, const wxString& label, |
56 | const wxPoint& pos = wxDefaultPosition, | |
57 | const wxSize& size = wxDefaultSize, long style = 0, | |
58 | const wxValidator& validator = wxDefaultValidator, | |
59 | const wxString& name = wxButtonNameStr); | |
fd0eed64 | 60 | void SetDefault(); |
c801d85f | 61 | void SetLabel( const wxString &label ); |
f03fc89f | 62 | bool Enable( bool enable ); |
8dbf4589 RR |
63 | |
64 | static wxSize GetDefaultSize(); | |
fd0eed64 | 65 | |
58614078 RR |
66 | // implementation |
67 | ||
68 | void ApplyWidgetStyle(); | |
c801d85f KB |
69 | }; |
70 | ||
71 | #endif // __GTKBUTTONH__ |