]>
git.saurik.com Git - wxWidgets.git/blob - include/wx/mac/slider.h
1 /////////////////////////////////////////////////////////////////////////////
3 // Purpose: wxSlider class
8 // Copyright: (c) AUTHOR
9 // Licence: wxWindows licence
10 /////////////////////////////////////////////////////////////////////////////
16 #pragma interface "slider.h"
19 #include "wx/control.h"
20 #include "wx/slider.h"
21 #include "wx/stattext.h"
23 WXDLLEXPORT_DATA(extern const char*) wxSliderNameStr
;
26 class WXDLLEXPORT wxSlider
: public wxControl
28 DECLARE_DYNAMIC_CLASS(wxSlider
)
33 inline wxSlider(wxWindow
*parent
, wxWindowID id
,
34 int value
, int minValue
, int maxValue
,
35 const wxPoint
& pos
= wxDefaultPosition
,
36 const wxSize
& size
= wxDefaultSize
,
37 long style
= wxSL_HORIZONTAL
,
38 const wxValidator
& validator
= wxDefaultValidator
,
39 const wxString
& name
= wxSliderNameStr
)
41 Create(parent
, id
, value
, minValue
, maxValue
, pos
, size
, style
, validator
, name
);
46 bool Create(wxWindow
*parent
, wxWindowID id
,
47 int value
, int minValue
, int maxValue
,
48 const wxPoint
& pos
= wxDefaultPosition
,
49 const wxSize
& size
= wxDefaultSize
,
50 long style
= wxSL_HORIZONTAL
,
51 const wxValidator
& validator
= wxDefaultValidator
,
52 const wxString
& name
= wxSliderNameStr
);
54 virtual int GetValue() const ;
55 virtual void SetValue(int);
58 void SetRange(int minValue
, int maxValue
);
60 inline int GetMin() const { return m_rangeMin
; }
61 inline int GetMax() const { return m_rangeMax
; }
64 void SetTickFreq(int n
, int pos
);
65 inline int GetTickFreq() const { return m_tickFreq
; }
66 void SetPageSize(int pageSize
);
67 int GetPageSize() const ;
70 void SetLineSize(int lineSize
);
71 int GetLineSize() const ;
72 int GetSelEnd() const ;
73 int GetSelStart() const ;
74 void SetSelection(int minPos
, int maxPos
);
75 void SetThumbLength(int len
) ;
76 int GetThumbLength() const ;
77 void SetTick(int tickPos
) ;
79 void Command(wxCommandEvent
& event
);
80 void MacHandleControlClick( ControlHandle control
, SInt16 controlpart
) ;
82 wxStaticText
* m_macMinimumStatic
;
83 wxStaticText
* m_macMaximumStatic
;
84 wxStaticText
* m_macValueStatic
;