Opened 11 years ago

Last modified 11 years ago

#11478 new defect

wxAuiToolbar not displaying properly in wxMDIChildFrame with Gtk2

Reported by: klamerus Owned by:
Priority: normal Milestone:
Component: wxAui Version: 2.9.0
Keywords: wxAuiToolbar Cc:
Blocked By: Blocking:
Patch: no

Description

This worked properly with release 2.8.10, and does not with downloaded 2.9.0.
I am trying to add a wxAuiToolbar to a derived wxMDIChildFrame class using:

m_Mgr.AddPane(m_pStdToolbar, wxAuiPaneInfo().

Name(wxT("tb1")).Caption(wxT("Chart Toolbar")).
ToolbarPane().Bottom().Row(1).
LeftDockable(false).RightDockable(false));

where m_Mgr is a created wxAuiManager and m_pStdToolbar is a created and populated wxAuiToolbar:

m_pStdToolbar = new wxAuiToolBar(this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxAUI_TB_DEFAULT_STYLE);
m_pStdToolbar->SetToolBitmapSize(wxSize(16,16));
... add buttons, separators, etc.
m_pStdToolbar->Realize();

What gets displayed is a properly sized and positioned bar window, but with a single, indistinguishable, grayed out toolbar icon. I am doing the identical code with a derived wxFrame and wxMDIParentFrame and it appears and functions properly with those window types. Note that this also works properly with the msw build - I am only seeing this with a Gtk2 build.

Also, if I eliminate the ToolbarPane()options from the AddPane call, the toolbar works properly (just with the Aui border and titlebar).

Change History (1)

comment:1 Changed 11 years ago by klamerus

Interestingly, the opposite is true with 2.8.10 - the toolbar in Gtk2 DOES display properly with wxMDIChildFrame but not with wxFrame.

Note: See TracTickets for help on using tickets.