]> git.saurik.com Git - wxWidgets.git/blob - wxPython/src/_scrolbar.i
wx.App
[wxWidgets.git] / wxPython / src / _scrolbar.i
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: _scrolbar.i
3 // Purpose: SWIG interface defs for wxScrollBar
4 //
5 // Author: Robin Dunn
6 //
7 // Created: 10-June-1998
8 // RCS-ID: $Id$
9 // Copyright: (c) 2003 by Total Control Software
10 // Licence: wxWindows license
11 /////////////////////////////////////////////////////////////////////////////
12
13 // Not a %module
14
15
16 //---------------------------------------------------------------------------
17
18 MAKE_CONST_WXSTRING(ScrollBarNameStr);
19
20 //---------------------------------------------------------------------------
21 %newgroup
22
23 class wxScrollBar : public wxControl {
24 public:
25 %addtofunc wxScrollBar "self._setOORInfo(self)"
26 %addtofunc wxScrollBar() ""
27
28 wxScrollBar(wxWindow* parent, wxWindowID id = -1,
29 const wxPoint& pos = wxDefaultPosition,
30 const wxSize& size = wxDefaultSize,
31 long style = wxSB_HORIZONTAL,
32 const wxValidator& validator = wxDefaultValidator,
33 const wxString& name = wxPyScrollBarNameStr);
34 %name(PreScrollBar)wxScrollBar();
35
36 bool Create(wxWindow* parent, wxWindowID id = -1,
37 const wxPoint& pos = wxDefaultPosition,
38 const wxSize& size = wxDefaultSize,
39 long style = wxSB_HORIZONTAL,
40 const wxValidator& validator = wxDefaultValidator,
41 const wxString& name = wxPyScrollBarNameStr);
42
43 virtual int GetThumbPosition() const;
44 virtual int GetThumbSize() const;
45 %pythoncode { GetThumbLength = GetThumbSize };
46 virtual int GetPageSize() const;
47 virtual int GetRange() const;
48
49 bool IsVertical() const { return (m_windowStyle & wxVERTICAL) != 0; }
50
51 virtual void SetThumbPosition(int viewStart);
52 virtual void SetScrollbar(int position, int thumbSize,
53 int range, int pageSize,
54 bool refresh = True);
55 };
56
57 //---------------------------------------------------------------------------