]> git.saurik.com Git - wxWidgets.git/blame - include/wx/gtk1/control.h
corrected wxComboBox::GetBestSize()
[wxWidgets.git] / include / wx / gtk1 / control.h
CommitLineData
c801d85f
KB
1/////////////////////////////////////////////////////////////////////////////
2// Name: control.h
3// Purpose:
4// Author: Robert Roebling
dbf858b5
RR
5// Id: $Id$
6// Copyright: (c) 1998 Robert Roebling, Julian Smart
8d99be5f 7// Licence: wxWindows licence
c801d85f
KB
8/////////////////////////////////////////////////////////////////////////////
9
c801d85f
KB
10#ifndef __GTKCONTROLH__
11#define __GTKCONTROLH__
12
13#ifdef __GNUG__
14#pragma interface
15#endif
16
17#include "wx/defs.h"
18#include "wx/object.h"
19#include "wx/list.h"
20#include "wx/window.h"
21
22//-----------------------------------------------------------------------------
23// classes
24//-----------------------------------------------------------------------------
25
26class wxControl;
27
28//-----------------------------------------------------------------------------
29// wxControl
30//-----------------------------------------------------------------------------
31
8d772832
RD
32extern const wxChar* wxControlNameStr;
33
9abe166a 34class wxControl : public wxControlBase
c801d85f 35{
2a4f4a27 36public:
8d99be5f 37 wxControl();
04165bec
RR
38 wxControl(wxWindow *parent, wxWindowID id,
39 const wxPoint& pos = wxDefaultPosition,
40 const wxSize& size = wxDefaultSize, long style = 0,
41#if wxUSE_VALIDATORS
42 const wxValidator& validator = wxDefaultValidator,
43#endif
44 const wxString& name = wxControlNameStr)
45 {
46 Create(parent, id, pos, size, style,
47#if wxUSE_VALIDATORS
48 validator,
49#endif
50 name);
51 }
8d772832 52
04165bec
RR
53 bool Create(wxWindow *parent, wxWindowID id,
54 const wxPoint& pos = wxDefaultPosition,
55 const wxSize& size = wxDefaultSize, long style = 0,
8d772832 56#if wxUSE_VALIDATORS
04165bec 57 const wxValidator& validator = wxDefaultValidator,
8d772832 58#endif
04165bec 59 const wxString& name = wxControlNameStr);
2a4f4a27 60
2a4f4a27 61 // this function will filter out '&' characters and will put the accelerator
8d99be5f
VZ
62 // char (the one immediately after '&') into m_chAccel (TODO not yet)
63 virtual void SetLabel( const wxString &label );
64 virtual wxString GetLabel() const;
65
2a4f4a27 66protected:
f68586e5
VZ
67 virtual wxSize DoGetBestSize() const;
68
8d99be5f
VZ
69 wxString m_label;
70 char m_chAccel; // enabled to avoid breaking binary compatibility later on
8d772832 71
738f9e5a
RR
72private:
73 DECLARE_DYNAMIC_CLASS(wxControl)
c801d85f
KB
74};
75
76#endif // __GTKCONTROLH__