]> git.saurik.com Git - wxWidgets.git/blame - include/wx/gtk/button.h
Minor corrections to make dist after reports
[wxWidgets.git] / include / wx / gtk / button.h
CommitLineData
c801d85f 1/////////////////////////////////////////////////////////////////////////////
6b0d8a01 2// Name: wx/gtk/button.h
c801d85f
KB
3// Purpose:
4// Author: Robert Roebling
dbf858b5 5// Id: $Id$
01111366 6// Copyright: (c) 1998 Robert Roebling
65571936 7// Licence: wxWindows licence
c801d85f
KB
8/////////////////////////////////////////////////////////////////////////////
9
0416c418
PC
10#ifndef _WX_GTK_BUTTON_H_
11#define _WX_GTK_BUTTON_H_
c801d85f
KB
12
13//-----------------------------------------------------------------------------
14// wxButton
15//-----------------------------------------------------------------------------
16
20123d49 17class WXDLLIMPEXP_CORE wxButton: public wxButtonBase
c801d85f 18{
738f9e5a 19public:
fd0eed64 20 wxButton();
5f7bcb48
VS
21 wxButton(wxWindow *parent, wxWindowID id,
22 const wxString& label = wxEmptyString,
6de97a3b
RR
23 const wxPoint& pos = wxDefaultPosition,
24 const wxSize& size = wxDefaultSize, long style = 0,
25 const wxValidator& validator = wxDefaultValidator,
26 const wxString& name = wxButtonNameStr)
27 {
401e3b6e 28 Create(parent, id, label, pos, size, style, validator, name);
6de97a3b 29 }
401e3b6e 30
6b0d8a01
VZ
31 virtual ~wxButton();
32
5f7bcb48
VS
33 bool Create(wxWindow *parent, wxWindowID id,
34 const wxString& label = wxEmptyString,
6de97a3b
RR
35 const wxPoint& pos = wxDefaultPosition,
36 const wxSize& size = wxDefaultSize, long style = 0,
37 const wxValidator& validator = wxDefaultValidator,
38 const wxString& name = wxButtonNameStr);
6b0d8a01 39
94aff5ff 40 virtual wxWindow *SetDefault();
6b0d8a01
VZ
41 virtual void SetLabel( const wxString &label );
42 virtual bool Enable( bool enable = TRUE );
8dbf4589 43
20e05ffb
RR
44 // implementation
45 // --------------
6b0d8a01 46
9d522606
RD
47 static wxVisualAttributes
48 GetClassDefaultAttributes(wxWindowVariant variant = wxWINDOW_VARIANT_NORMAL);
49
6f02a879
VZ
50 // helper to allow access to protected member from GTK callback
51 void MoveWindow(int x, int y, int width, int height) { DoMoveWindow(x, y, width, height); }
52
db434467
RR
53protected:
54 virtual wxSize DoGetBestSize() const;
ef5c70f9
VZ
55 virtual void DoApplyWidgetStyle(GtkRcStyle *style);
56
57 virtual GdkWindow *GTKGetWindow(wxArrayGdkWindows& windows) const;
db434467 58
738f9e5a
RR
59private:
60 DECLARE_DYNAMIC_CLASS(wxButton)
c801d85f
KB
61};
62
0416c418 63#endif // _WX_GTK_BUTTON_H_