Qt World Summit: Register Today!

How to move/drag widgets between multiple Dockwidgets?

  • I have created a container from this link https://wiki.qt.io/Widget-moveable-and-resizeable
    Below is the code where I'm setting this container object to Dockwidget.

    QDockWidget *dock = new QDockWidget(tr("D1"), this);
    QLabel *GUI_qlabel1 = new QLabel ("Zone 1");
    TContainer *container1 = new TContainer (this, QPoint (10, 10), GUI_qlabel1);

    I want to create multiple QDockwidgets which should support below requirements
    1.The container should be restricted within a dockwidget window.
    2.The container should be able to move from one dockwidget window to another(only for a special case).

    Please suggest If QDockwidget is the right class for this requirement or should I use any other class.

  • Lifetime Qt Champion

    Duplicates this thread.

    Closing this one.

Log in to reply