]>
git.saurik.com Git - wxWidgets.git/blob - include/wx/gtk1/gauge.h
1 /////////////////////////////////////////////////////////////////////////////
4 // Author: Robert Roebling
6 // Copyright: (c) 1998 Robert Roebling
7 // Licence: wxWindows licence
8 /////////////////////////////////////////////////////////////////////////////
19 #include "wx/object.h"
21 #include "wx/control.h"
23 //-----------------------------------------------------------------------------
25 //-----------------------------------------------------------------------------
29 //-----------------------------------------------------------------------------
31 //-----------------------------------------------------------------------------
33 extern const char* wxGaugeNameStr
;
35 //-----------------------------------------------------------------------------
37 //-----------------------------------------------------------------------------
39 class wxGauge
: public wxControl
41 DECLARE_DYNAMIC_CLASS(wxGauge
)
44 inline wxGauge(void) { m_rangeMax
= 0; m_gaugePos
= 0; m_useProgressBar
= TRUE
; }
46 inline wxGauge( wxWindow
*parent
, wxWindowID id
,
48 const wxPoint
& pos
= wxDefaultPosition
,
49 const wxSize
& size
= wxDefaultSize
,
50 long style
= wxGA_HORIZONTAL
,
51 const wxValidator
& validator
= wxDefaultValidator
,
52 const wxString
& name
= wxGaugeNameStr
)
54 Create(parent
, id
, range
, pos
, size
, style
, validator
, name
);
56 bool Create( wxWindow
*parent
, wxWindowID id
,
58 const wxPoint
& pos
= wxDefaultPosition
,
59 const wxSize
& size
= wxDefaultSize
,
60 long style
= wxGA_HORIZONTAL
,
61 const wxValidator
& validator
= wxDefaultValidator
,
62 const wxString
& name
= wxGaugeNameStr
);
63 void SetShadowWidth( int WXUNUSED(w
) ) {};
64 void SetBezelFace( int WXUNUSED(w
) ) {};
65 void SetRange( int r
);
66 void SetValue( int pos
);
67 int GetShadowWidth(void) const { return 0; };
68 int GetBezelFace(void) const { return 0; };
69 int GetRange(void) const;
70 int GetValue(void) const;
72 // Are we a Win95/GTK progress bar, or a normal gauge?
73 inline bool GetProgressBar(void) const { return m_useProgressBar
; }
77 void ApplyWidgetStyle();
81 bool m_useProgressBar
;
84 #endif // __GTKGAUGEH__