]> git.saurik.com Git - wxWidgets.git/blame - include/wx/gtk/spinbutt.h
Add lambda-friendly wxDialog::ShowWindowModalThenDo().
[wxWidgets.git] / include / wx / gtk / spinbutt.h
CommitLineData
8e189077 1/////////////////////////////////////////////////////////////////////////////
1e6feb95 2// Name: wx/gtk/spinbutt.h
8e189077
RR
3// Purpose: wxSpinButton class
4// Author: Robert Roebling
5// Modified by:
8e189077 6// Copyright: (c) Robert Roebling
65571936 7// Licence: wxWindows licence
8e189077
RR
8/////////////////////////////////////////////////////////////////////////////
9
1e6feb95
VZ
10#ifndef _WX_GTK_SPINBUTT_H_
11#define _WX_GTK_SPINBUTT_H_
8e189077 12
8e189077
RR
13//-----------------------------------------------------------------------------
14// wxSpinButton
15//-----------------------------------------------------------------------------
16
20123d49 17class WXDLLIMPEXP_CORE wxSpinButton : public wxSpinButtonBase
8e189077 18{
8e189077 19public:
a01ed326 20 wxSpinButton();
1e6feb95
VZ
21 wxSpinButton(wxWindow *parent,
22 wxWindowID id = -1,
23 const wxPoint& pos = wxDefaultPosition,
24 const wxSize& size = wxDefaultSize,
25 long style = wxSP_VERTICAL,
26 const wxString& name = wxSPIN_BUTTON_NAME)
31528cd3
VZ
27 {
28 Create(parent, id, pos, size, style, name);
29 }
31528cd3 30
1e6feb95
VZ
31 bool Create(wxWindow *parent,
32 wxWindowID id = -1,
33 const wxPoint& pos = wxDefaultPosition,
34 const wxSize& size = wxDefaultSize,
35 long style = wxSP_VERTICAL,
36 const wxString& name = wxSPIN_BUTTON_NAME);
31528cd3
VZ
37
38 virtual int GetValue() const;
39 virtual void SetValue( int value );
40 virtual void SetRange( int minVal, int maxVal );
41 virtual int GetMin() const;
42 virtual int GetMax() const;
43
9d522606
RD
44 static wxVisualAttributes
45 GetClassDefaultAttributes(wxWindowVariant variant = wxWINDOW_VARIANT_NORMAL);
03647350 46
ad60f9e7
JS
47 virtual bool Enable( bool enable = true );
48
31528cd3
VZ
49 // implementation
50 void OnSize( wxSizeEvent &event );
51
a01ed326 52 int m_pos;
31528cd3 53
9d9b7755 54protected:
a596eeb9
RR
55 void GtkDisableEvents() const;
56 void GtkEnableEvents() const;
03647350 57
9d9b7755 58 virtual wxSize DoGetBestSize() const;
ef5c70f9 59 virtual GdkWindow *GTKGetWindow(wxArrayGdkWindows& windows) const;
9d9b7755 60
31528cd3 61private:
b545684e
PC
62 typedef wxSpinButtonBase base_type;
63
31528cd3 64 DECLARE_EVENT_TABLE()
738f9e5a 65 DECLARE_DYNAMIC_CLASS(wxSpinButton)
8e189077
RR
66};
67
a075e27b 68#endif
1e6feb95 69 // _WX_GTK_SPINBUTT_H_