How to disable snapping/docking of QDockWidget to the centeral widget ?



  • Hi,

    Basically i want all my QDockWidgets to remain floating(unDocked) always and shouldn't snap/dock to the central widget when I try to reposition it dragging using titleBar.
    How to achieve that ?

    Thanks


  • Qt Champions 2017

    Hi
    you can try with Qt::NoDockWidgetArea
    dockWidget->setAllowedAreas( Qt::NoDockWidgetArea );
    but not sure they can be there from start.

    Why use docks when you dont want to dock them?



  • @mrjj Basically I want an option to set the dock widget to behave floating(unDocked) when i force it to remain unDocked irrespective of the position/movement .
    But i need an option for dock widget also if i want it to be.



  • @mrjj Thank you :)


Log in to reply
 

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