]> git.saurik.com Git - wxWidgets.git/blame - include/wx/motif/toolbar.h
Add missing wxUSE_OLE checks to safearray.cpp.
[wxWidgets.git] / include / wx / motif / toolbar.h
CommitLineData
9b6dbb09 1/////////////////////////////////////////////////////////////////////////////
8a0681f9 2// Name: wx/motif/toolbar.h
9b6dbb09
JS
3// Purpose: wxToolBar class
4// Author: Julian Smart
8a0681f9 5// Modified by: 13.12.99 by VZ during toolbar classes reorganization
9b6dbb09
JS
6// Created: 17/09/98
7// RCS-ID: $Id$
8// Copyright: (c) Julian Smart
1b88201f 9// Licence: wxWindows licence
9b6dbb09
JS
10/////////////////////////////////////////////////////////////////////////////
11
12#ifndef _WX_TOOLBAR_H_
13#define _WX_TOOLBAR_H_
14
53a2db12 15class WXDLLIMPEXP_CORE wxToolBar : public wxToolBarBase
8a0681f9
VZ
16{
17public:
18 // ctors and dtor
19 wxToolBar() { Init(); }
1b88201f 20
8a0681f9 21 wxToolBar(wxWindow *parent,
83df96d6
JS
22 wxWindowID id,
23 const wxPoint& pos = wxDefaultPosition,
24 const wxSize& size = wxDefaultSize,
25 long style = wxNO_BORDER | wxTB_HORIZONTAL,
26 const wxString& name = wxToolBarNameStr)
8a0681f9
VZ
27 {
28 Init();
1b88201f 29
8a0681f9
VZ
30 Create(parent, id, pos, size, style, name);
31 }
1b88201f 32
8a0681f9 33 bool Create(wxWindow *parent,
83df96d6
JS
34 wxWindowID id,
35 const wxPoint& pos = wxDefaultPosition,
36 const wxSize& size = wxDefaultSize,
37 long style = wxNO_BORDER | wxTB_HORIZONTAL,
38 const wxString& name = wxToolBarNameStr);
1b88201f 39
8a0681f9 40 virtual ~wxToolBar();
1b88201f 41
8a0681f9 42 // override/implement base class virtuals
982b2cfc 43 virtual wxToolBarToolBase *FindToolForPosition(wxCoord x, wxCoord y) const;
1b88201f 44
8a0681f9 45 virtual bool Realize();
1b88201f 46
8a0681f9 47 // implementation from now on
1b88201f 48
8a0681f9 49 // find tool by widget
982b2cfc 50 wxToolBarToolBase *FindToolByWidget(WXWidget w) const;
1b88201f 51
46675b46 52private:
8a0681f9
VZ
53 // common part of all ctors
54 void Init();
1b88201f 55
8a0681f9 56 // implement base class pure virtuals
982b2cfc
VZ
57 virtual bool DoInsertTool(size_t pos, wxToolBarToolBase *tool);
58 virtual bool DoDeleteTool(size_t pos, wxToolBarToolBase *tool);
1b88201f 59
982b2cfc
VZ
60 virtual void DoEnableTool(wxToolBarToolBase *tool, bool enable);
61 virtual void DoToggleTool(wxToolBarToolBase *tool, bool toggle);
62 virtual void DoSetToggle(wxToolBarToolBase *tool, bool toggle);
1b88201f 63
982b2cfc 64 virtual wxToolBarToolBase *CreateTool(int id,
fcb35b5f
VZ
65 const wxString& label,
66 const wxBitmap& bmpNormal,
67 const wxBitmap& bmpDisabled,
68 wxItemKind kind,
69 wxObject *clientData,
70 const wxString& shortHelp,
71 const wxString& longHelp);
07d02e9e
VZ
72 virtual wxToolBarToolBase *CreateTool(wxControl *control,
73 const wxString& label);
46675b46
MB
74
75 virtual void DoSetSize(int x, int y,
76 int width, int height,
77 int sizeFlags = wxSIZE_AUTO);
8a0681f9
VZ
78private:
79 DECLARE_DYNAMIC_CLASS(wxToolBar)
9b6dbb09
JS
80};
81
82#endif
1b88201f 83 // _WX_TOOLBAR_H_