X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/cf8ccdb270af889f19ae7a57d77b721e250b2ad4..9e9574fe45b176ee74bba8fad7574cf9906145d1:/interface/wx/aui/auibar.h diff --git a/interface/wx/aui/auibar.h b/interface/wx/aui/auibar.h index 303a14ba0f..e65fa1c216 100644 --- a/interface/wx/aui/auibar.h +++ b/interface/wx/aui/auibar.h @@ -2,7 +2,6 @@ // Name: wx/aui/toolbar.h // Purpose: Documentation of wxAuiToolBar and related classes. // Created: 2011-01-17 -// RCS-ID: $Id$ // Copyright: (c) 2011 wxWidgets development team // Licence: wxWindows licence /////////////////////////////////////////////////////////////////////////////// @@ -57,6 +56,14 @@ enum wxAuiToolBarStyle */ wxAUI_TB_HORIZONTAL = 1 << 7, + + /** + Draw a plain background (based on parent) instead of the default gradient background. + + @since 2.9.5 + */ + wxAUI_TB_PLAIN_BACKGROUND = 1 << 8, + /** Shows the text alongside the icons, not vertically stacked. */ @@ -341,11 +348,13 @@ public: bool IsActive() const; /** + Set whether this tool has a drop down button. + This is only valid for wxITEM_NORMAL tools. */ void SetHasDropDown(bool b); /** - + Returns whether the toolbar item has an associated drop down button. */ bool HasDropDown() const; @@ -404,6 +413,11 @@ public: wxWindow* wnd, const wxRect& rect) = 0; + virtual void DrawPlainBackground( + wxDC& dc, + wxWindow* wnd, + const wxRect& rect) = 0; + virtual void DrawLabel( wxDC& dc, wxWindow* wnd, @@ -491,6 +505,10 @@ public: wxWindow* wnd, const wxRect& rect); + virtual void DrawPlainBackground(wxDC& dc, + wxWindow* wnd, + const wxRect& rect); + virtual void DrawLabel( wxDC& dc, wxWindow* wnd, @@ -571,6 +589,9 @@ public: @style{wxAUI_TB_HORIZONTAL} analogous to wxAUI_TB_VERTICAL, but forces the toolbar to be horizontal + @style{wxAUI_TB_PLAIN_BACKGROUND} + Draw a plain background (based on parent) instead of the + default gradient background. @style{wxAUI_TB_HORZ_TEXT} Equivalent to wxAUI_TB_HORZ_LAYOUT | wxAUI_TB_TEXT @style{wxAUI_TB_DEFAULT_STYLE} @@ -579,15 +600,15 @@ public: @beginEventEmissionTable{wxAuiToolBarEvent} @event{EVT_AUITOOLBAR_TOOL_DROPDOWN(id, func)} - Process a wxEVT_COMMAND_AUITOOLBAR_TOOL_DROPDOWN event + Process a wxEVT_AUITOOLBAR_TOOL_DROPDOWN event @event{EVT_AUITOOLBAR_OVERFLOW_CLICK(id, func)} - Process a wxEVT_COMMAND_AUITOOLBAR_OVERFLOW_CLICK event + Process a wxEVT_AUITOOLBAR_OVERFLOW_CLICK event @event{EVT_AUITOOLBAR_RIGHT_CLICK(id, func)} - Process a wxEVT_COMMAND_AUITOOLBAR_RIGHT_CLICK event + Process a wxEVT_AUITOOLBAR_RIGHT_CLICK event @event{EVT_AUITOOLBAR_MIDDLE_CLICK(id, func)} - Process a wxEVT_COMMAND_AUITOOLBAR_MIDDLE_CLICK event + Process a wxEVT_AUITOOLBAR_MIDDLE_CLICK event @event{EVT_AUITOOLBAR_BEGIN_DRAG(id, func)} - Process a wxEVT_COMMAND_AUITOOLBAR_BEGIN_DRAG event + Process a wxEVT_AUITOOLBAR_BEGIN_DRAG event @endEventTable @library{wxaui} @@ -596,11 +617,32 @@ public: class wxAuiToolBar : public wxControl { public: + /** + Default constructor, use Create() later. + + @since 2.9.5 + */ + wxAuiToolBar(); + + /** + Constructor creating and initializing the object. + */ wxAuiToolBar(wxWindow* parent, - wxWindowID id = -1, + wxWindowID id = wxID_ANY, const wxPoint& position = wxDefaultPosition, const wxSize& size = wxDefaultSize, long style = wxAUI_TB_DEFAULT_STYLE); + + /** + Really create wxAuiToolBar created using default constructor. + + @since 2.9.5 + */ + bool Create(wxWindow* parent, + wxWindowID id = wxID_ANY, + const wxPoint& pos = wxDefaultPosition, + const wxSize& size = wxDefaultSize, + long style = wxAUI_TB_DEFAULT_STYLE); virtual ~wxAuiToolBar(); void SetWindowStyleFlag(long style); @@ -683,7 +725,21 @@ public: void EnableTool(int tool_id, bool state); bool GetToolEnabled(int tool_id) const; + /** + Set whether the specified toolbar item has a drop down button. + + This is only valid for wxITEM_NORMAL tools. + + @see wxAuiToolBarItem::SetHasDropDown() + */ void SetToolDropDown(int tool_id, bool dropdown); + + /** + Returns whether the specified toolbar item has an associated drop down + button. + + @see wxAuiToolBarItem::HasDropDown() + */ bool GetToolDropDown(int tool_id) const; void SetToolBorderPadding(int padding);