Thanks Christoph, Is there any way to do this with a QToolBar? I cannot add a QToolButton to the toolbar (unless I missed something), as you add the menu directly using addAction (qMenu->menuAction()), and the QToolBar seems to miss this setting
On the other hand, QToolBar is quite useful for me (auto display of a popup button if the toolbar is not large enough for all buttons, etc...) Thanks, Etienne 2013/8/20 Christoph Feck <christ...@maxiom.de> > On Tuesday 20 August 2013 19:27:03 Etienne Sandré-Chardonnal wrote: > > Dear all, > > > > I inserted a QMenu to a QToolBar. This displays the menu icon, > > together with a drop-down arrow for opening the menu. > > > > Clicking the menu icon in the toolbar does nothing, as the menu > > action is connected to nothing. > > Is it possible to either: > > - Set the default child action that will be triggered when the > > main menu icon is clicked (setDefaultAction doesn't do the job) > > - Popup the menu when the main menu icon is clicked (as when > > clicking the dropdown arrow) > > > > Thanks, > > > > Etienne > > http://qt-project.org/doc/qt-4.8/qtoolbutton.html#ToolButtonPopupMode-enum >
_______________________________________________ Interest mailing list Interest@qt-project.org http://lists.qt-project.org/mailman/listinfo/interest