Do not #include an header where a forward declaration suffixes. Do not
[wxWidgets.git] / include / wx / motif / button.h
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: button.h
3 // Purpose: wxButton class
4 // Author: Julian Smart
5 // Modified by:
6 // Created: 17/09/98
7 // RCS-ID: $Id$
8 // Copyright: (c) Julian Smart
9 // Licence: wxWindows licence
10 /////////////////////////////////////////////////////////////////////////////
11
12 #ifndef _WX_BUTTON_H_
13 #define _WX_BUTTON_H_
14
15 #ifdef __GNUG__
16 #pragma interface "button.h"
17 #endif
18
19 #include "wx/control.h"
20
21 WXDLLEXPORT_DATA(extern const char*) wxButtonNameStr;
22
23 // Pushbutton
24 class WXDLLEXPORT wxButton: public wxControl
25 {
26 DECLARE_DYNAMIC_CLASS(wxButton)
27
28 public:
29 wxButton() { }
30 wxButton(wxWindow *parent,
31 wxWindowID id,
32 const wxString& label,
33 const wxPoint& pos = wxDefaultPosition,
34 const wxSize& size = wxDefaultSize, long style = 0,
35 const wxValidator& validator = wxDefaultValidator,
36 const wxString& name = wxButtonNameStr)
37 {
38 Create(parent, id, label, pos, size, style, validator, name);
39 }
40
41 bool Create(wxWindow *parent, wxWindowID id, const wxString& label,
42 const wxPoint& pos = wxDefaultPosition,
43 const wxSize& size = wxDefaultSize, long style = 0,
44 const wxValidator& validator = wxDefaultValidator,
45 const wxString& name = wxButtonNameStr);
46
47 virtual void SetDefault();
48 virtual void Command(wxCommandEvent& event);
49
50 static wxSize GetDefaultSize();
51
52 // Implementation
53 virtual void ChangeFont(bool keepOriginalSize = TRUE);
54 virtual void ChangeBackgroundColour();
55 virtual void ChangeForegroundColour();
56 };
57
58 #endif
59 // _WX_BUTTON_H_