]> git.saurik.com Git - wxWidgets.git/blame - include/wx/gtk/menuitem.h
support retina display
[wxWidgets.git] / include / wx / gtk / menuitem.h
CommitLineData
23d1d521 1///////////////////////////////////////////////////////////////////////////////
80fdcdb9 2// Name: wx/gtk/menuitem.h
23d1d521 3// Purpose: wxMenuItem class
6ca41e57 4// Author: Robert Roebling
23d1d521 5// RCS-ID: $Id$
6ca41e57 6// Copyright: (c) 1998 Robert Roebling
65571936 7// Licence: wxWindows licence
23d1d521
JS
8///////////////////////////////////////////////////////////////////////////////
9
aac7dbf3
PC
10#ifndef _WX_GTKMENUITEM_H_
11#define _WX_GTKMENUITEM_H_
23d1d521 12
37d403aa
JS
13#include "wx/bitmap.h"
14
6ca41e57
RR
15//-----------------------------------------------------------------------------
16// wxMenuItem
17//-----------------------------------------------------------------------------
23d1d521 18
20123d49 19class WXDLLIMPEXP_CORE wxMenuItem : public wxMenuItemBase
6ca41e57 20{
6ca41e57 21public:
d3b9f782 22 wxMenuItem(wxMenu *parentMenu = NULL,
974e8d94
VZ
23 int id = wxID_SEPARATOR,
24 const wxString& text = wxEmptyString,
25 const wxString& help = wxEmptyString,
546bfbea 26 wxItemKind kind = wxITEM_NORMAL,
d3b9f782 27 wxMenu *subMenu = NULL);
d3c7fc99 28 virtual ~wxMenuItem();
c626a8b7 29
974e8d94 30 // implement base class virtuals
52af3158 31 virtual void SetItemLabel( const wxString& str );
aac7dbf3
PC
32 virtual void Enable( bool enable = true );
33 virtual void Check( bool check = true );
974e8d94 34 virtual bool IsChecked() const;
1deef997 35 virtual void SetBitmap(const wxBitmap& bitmap);
37d403aa 36 virtual const wxBitmap& GetBitmap() const { return m_bitmap; }
c626a8b7
VZ
37
38 // implementation
40116524 39 void SetMenuItem(GtkWidget *menuItem);
c626a8b7 40 GtkWidget *GetMenuItem() const { return m_menuItem; }
1deef997 41 void SetGtkLabel();
92159e3d 42
efebabb7 43#if WXWIN_COMPATIBILITY_2_8
2368dcda 44 // compatibility only, don't use in new code
bb3a9c6d 45 wxDEPRECATED_CONSTRUCTOR(
2368dcda
VZ
46 wxMenuItem(wxMenu *parentMenu,
47 int id,
48 const wxString& text,
49 const wxString& help,
50 bool isCheckable,
efebabb7
PC
51 wxMenu *subMenu = NULL)
52 );
53#endif
2368dcda 54
c626a8b7 55private:
37d403aa 56 wxBitmap m_bitmap; // Bitmap for menuitem, if any
974e8d94 57 GtkWidget *m_menuItem; // GtkMenuItem
c626a8b7 58
974e8d94 59 DECLARE_DYNAMIC_CLASS(wxMenuItem)
23d1d521
JS
60};
61
aac7dbf3 62#endif // _WX_GTKMENUITEM_H_