PDA

View Full Version : Stack two QMenuBars instead of side by side?



killerwookie99
15th August 2008, 23:10
I am trying to figure this out, but have not reached a solution thus far.

Problem:


QMenuBar *menubar1 = addToolBar(tr("blah"));
QMenuBar *menubar2 = addToolBar(tr("blah2"));


When it launches in a mainwindow it's like this:

[menubar1] | [menubar2]

I would like it to appear like this:

[menubar1]
[menubar2]

How is this accomplished?

aamer4yu
16th August 2008, 06:27
By the way, you are using QMenuBar *, while addToolBar() returns QToolBar* ;)

As for the answer, use QMainWindow::addToolBarBreak between addToolBar functions :)