]> git.saurik.com Git - wxWidgets.git/blame_incremental - include/wx/motif/gauge.h
Blind bug fix to bug reported by Angel Kry.
[wxWidgets.git] / include / wx / motif / gauge.h
... / ...
CommitLineData
1/////////////////////////////////////////////////////////////////////////////
2// Name: gauge.h
3// Purpose: wxGauge class
4// Author: Julian Smart
5// Modified by:
6// Created: 17/09/98
7// RCS-ID: $Id$
8// Copyright: (c) Julian Smart
9// Licence: wxWindows licence
10/////////////////////////////////////////////////////////////////////////////
11
12#ifndef _WX_GAUGE_H_
13#define _WX_GAUGE_H_
14
15#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA)
16#pragma interface "gauge.h"
17#endif
18
19// Group box
20class WXDLLEXPORT wxGauge : public wxGaugeBase
21{
22 DECLARE_DYNAMIC_CLASS(wxGauge)
23
24public:
25 inline wxGauge() { m_rangeMax = 0; m_gaugePos = 0; }
26
27 inline wxGauge(wxWindow *parent, wxWindowID id,
28 int range,
29 const wxPoint& pos = wxDefaultPosition,
30 const wxSize& size = wxDefaultSize,
31 long style = wxGA_HORIZONTAL,
32 const wxValidator& validator = wxDefaultValidator,
33 const wxString& name = wxGaugeNameStr)
34 {
35 Create(parent, id, range, pos, size, style, validator, name);
36 }
37
38 bool Create(wxWindow *parent, wxWindowID id,
39 int range,
40 const wxPoint& pos = wxDefaultPosition,
41 const wxSize& size = wxDefaultSize,
42 long style = wxGA_HORIZONTAL,
43 const wxValidator& validator = wxDefaultValidator,
44 const wxString& name = wxGaugeNameStr);
45
46 void SetShadowWidth(int w);
47 void SetRange(int r);
48 void SetValue(int pos);
49
50 int GetShadowWidth() const ;
51 int GetRange() const ;
52 int GetValue() const ;
53
54 virtual void Command(wxCommandEvent& WXUNUSED(event)) {} ;
55
56private:
57 virtual wxSize DoGetBestSize() const;
58 virtual void DoMoveWindow(int x, int y, int width, int height);
59};
60
61#endif
62// _WX_GAUGE_H_