3

With Qt 5.7 Designer, is it possible to have dock widget as child of another widget, e.g. within tab widget (which is within stacked widget)?

ekhumoro
  • 115,249
  • 20
  • 229
  • 336
vorlket
  • 131
  • 10

1 Answers1

2

It is not possible to do this because a QDockWidget must be docked inside a QMainWindow, and Qt Designer does not allow a QMainWindow to be added as a child widget.

However, in hand-written code, QMainWindow can be treated just like any other widget and so, as per your example, it could be set as a page inside a QTabWidget. Any dock-widgets added to that page would then behave just the same as they would in a top-level main-window.

ekhumoro
  • 115,249
  • 20
  • 229
  • 336