1 /////////////////////////////////////////////////////////////////////////////
3 // Purpose: SWIG interface defs for wxSlider
7 // Created: 10-June-1998
9 // Copyright: (c) 2003 by Total Control Software
10 // Licence: wxWindows license
11 /////////////////////////////////////////////////////////////////////////////
16 //---------------------------------------------------------------------------
19 #include <wx/slider.h>
23 MAKE_CONST_WXSTRING(SliderNameStr);
25 //---------------------------------------------------------------------------
28 class wxSlider : public wxControl {
30 %pythonPrepend wxSlider "if kwargs.has_key('point'): kwargs['pos'] = kwargs['point'];del kwargs['point']"
31 %pythonPrepend wxSlider() ""
32 %pythonAppend wxSlider "self._setOORInfo(self)"
33 %pythonAppend wxSlider() ""
35 wxSlider(wxWindow* parent, wxWindowID id,
36 int value, int minValue, int maxValue,
37 const wxPoint& pos = wxDefaultPosition,
38 const wxSize& size = wxDefaultSize,
39 long style = wxSL_HORIZONTAL,
40 const wxValidator& validator = wxDefaultValidator,
41 const wxString& name = wxPySliderNameStr);
42 %name(PreSlider)wxSlider();
44 bool Create(wxWindow* parent, wxWindowID id,
45 int value, int minValue, int maxValue,
46 const wxPoint& pos = wxDefaultPosition,
47 const wxSize& size = wxDefaultSize,
48 long style = wxSL_HORIZONTAL,
49 const wxValidator& validator = wxDefaultValidator,
50 const wxString& name = wxPySliderNameStr);
52 // get/set the current slider value (should be in range)
53 virtual int GetValue() const;
54 virtual void SetValue(int value);
56 // retrieve/change the range
57 virtual void SetRange(int minValue, int maxValue);
58 virtual int GetMin() const;
59 virtual int GetMax() const;
61 void SetMin( int minValue );
62 void SetMax( int maxValue );
64 // the line/page size is the increment by which the slider moves when
65 // cursor arrow key/page up or down are pressed (clicking the mouse is like
66 // pressing PageUp/Down) and are by default set to 1 and 1/10 of the range
67 virtual void SetLineSize(int lineSize);
68 virtual void SetPageSize(int pageSize);
69 virtual int GetLineSize() const;
70 virtual int GetPageSize() const;
72 // these methods get/set the length of the slider pointer in pixels
73 virtual void SetThumbLength(int lenPixels);
74 virtual int GetThumbLength() const;
76 virtual void SetTickFreq(int n, int pos=1);
77 virtual int GetTickFreq() const;
78 virtual void ClearTicks();
79 virtual void SetTick(int tickPos);
81 virtual void ClearSel();
82 virtual int GetSelEnd() const;
83 virtual int GetSelStart() const;
84 virtual void SetSelection(int min, int max);
88 //---------------------------------------------------------------------------