]> git.saurik.com Git - wxWidgets.git/blob - include/wx/msw/button.h
function HasValue() added
[wxWidgets.git] / include / wx / msw / button.h
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: button.h
3 // Purpose: wxButton class
4 // Author: Julian Smart
5 // Modified by:
6 // Created: 01/02/97
7 // RCS-ID: $Id$
8 // Copyright: (c) Julian Smart and Markus Holzem
9 // Licence: wxWindows license
10 /////////////////////////////////////////////////////////////////////////////
11
12 #ifndef __BUTTONH__
13 #define __BUTTONH__
14
15 #ifdef __GNUG__
16 #pragma interface "button.h"
17 #endif
18
19 #include "wx/control.h"
20 #include "wx/gdicmn.h"
21
22 WXDLLEXPORT_DATA(extern const char*) wxButtonNameStr;
23
24 // Pushbutton
25 class WXDLLEXPORT wxButton: public wxControl
26 {
27 DECLARE_DYNAMIC_CLASS(wxButton)
28 public:
29 inline wxButton(void) {}
30 inline wxButton(wxWindow *parent, const wxWindowID id, const wxString& label,
31 const wxPoint& pos = wxDefaultPosition,
32 const wxSize& size = wxDefaultSize, const long style = 0,
33 const wxValidator& validator = wxDefaultValidator,
34 const wxString& name = wxButtonNameStr)
35 {
36 Create(parent, id, label, pos, size, style, validator, name);
37 }
38
39 bool Create(wxWindow *parent, const wxWindowID id, const wxString& label,
40 const wxPoint& pos = wxDefaultPosition,
41 const wxSize& size = wxDefaultSize, const long style = 0,
42 const wxValidator& validator = wxDefaultValidator,
43 const wxString& name = wxButtonNameStr);
44
45 virtual void SetSize(const int x, const int y, const int width, const int height, const int sizeFlags = wxSIZE_AUTO);
46 virtual void SetDefault(void);
47 virtual void SetLabel(const wxString& label);
48 virtual wxString GetLabel(void) const ;
49 virtual void Command(wxCommandEvent& event);
50 virtual bool MSWCommand(const WXUINT param, const WXWORD id);
51 virtual WXHBRUSH OnCtlColor(const WXHDC pDC, const WXHWND pWnd, const WXUINT nCtlColor,
52 WXUINT message, WXWPARAM wParam, WXLPARAM lParam);
53 };
54
55 #endif
56 // __BUTTONH__