]> git.saurik.com Git - wxWidgets.git/blob - include/wx/os2/gauge.h
Getting rid of odd control characters at EOL in source.
[wxWidgets.git] / include / wx / os2 / gauge.h
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: gauge.h
3 // Purpose: wxGauge class
4 // Author: David Webster
5 // Modified by:
6 // Created: 10/06/99
7 // RCS-ID: $Id$
8 // Copyright: (c) David Webster
9 // Licence: wxWindows licence
10 /////////////////////////////////////////////////////////////////////////////
11
12 #ifndef _WX_GAUGE_H_
13 #define _WX_GAUGE_H_
14
15 #include "wx/control.h"
16
17 WXDLLEXPORT_DATA(extern const char*) wxGaugeNameStr;
18
19 class WXDLLEXPORT wxGauge: public wxControl
20 {
21 public:
22 inline wxGauge() { m_nRangeMax = 0; m_nGaugePos = 0; }
23
24 inline wxGauge( wxWindow* pParent
25 ,wxWindowID vId
26 ,int nRange
27 ,const wxPoint& rPos = wxDefaultPosition
28 ,const wxSize& rSize = wxDefaultSize
29 ,long lStyle = wxGA_HORIZONTAL
30 #if wxUSE_VALIDATORS
31 ,const wxValidator& rValidator = wxDefaultValidator
32 #endif
33 ,const wxString& rsName = wxGaugeNameStr
34 )
35 {
36 Create( pParent
37 ,vId
38 ,nRange
39 ,rPos
40 ,rSize
41 ,lStyle
42 #if wxUSE_VALIDATORS
43 ,rValidator
44 #endif
45 ,rsName
46 );
47 }
48
49 bool Create( wxWindow* pParent
50 ,wxWindowID vId
51 ,int nRange
52 ,const wxPoint& rPos = wxDefaultPosition
53 ,const wxSize& rSize = wxDefaultSize
54 ,long lStyle = wxGA_HORIZONTAL
55 #if wxUSE_VALIDATORS
56 ,const wxValidator& rValidator = wxDefaultValidator
57 #endif
58 ,const wxString& rsName = wxGaugeNameStr
59 );
60
61 int GetShadowWidth(void) const;
62 int GetBezelFace(void) const;
63 int GetRange(void) const;
64 int GetValue(void) const;
65
66 bool SetBackgroundColour(const wxColour& rColour);
67 void SetBezelFace(int nWidth);
68 bool SetForegroundColour(const wxColour& rColour);
69 void SetRange(int nRange);
70 void SetShadowWidth(int nWidth);
71 void SetValue(int nPos);
72
73 inline virtual bool AcceptsFocus(void) const { return FALSE; }
74 inline virtual void Command(wxCommandEvent& WXUNUSED(rEvent)) {};
75
76 protected:
77 int m_nRangeMax;
78 int m_nGaugePos;
79
80 private:
81 DECLARE_DYNAMIC_CLASS(wxGauge)
82 }; // end of CLASS wxGauge
83
84 #endif // _WX_GAUGE_H_
85