[SOLVED] QToolBar custom position



  • Hello. I need to configure two toolbars in such way as on photoshoped picture below:
    !http://pastexen.com/i/2UfuvWQz6U.png!
    but I can't set position right, because toolbars always run away to their areas. How can I configure them?


  • Moderators

    QToolBar's can only be moved around by the user inside the QMainWindow they belong to.
    If you need to position them anywhere inside you layout you need to add a QMainWindow as a child to your layout.



  • You can also just add a QToolBar widget directly on your widget. Just not from Designer. QToolBar is just a widget, and it can be placed in a layout like any other widget*.

    *) Well, mac... I don't know.



  • [quote author="Andre" date="1421412821"]You can also just add a QToolBar widget directly on your widget. Just not from Designer. QToolBar is just a widget, and it can be placed in a layout like any other widget*.

    *) Well, mac... I don't know.[/quote]
    Yep, you are right, I did it as I want, thank you.


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.