I have a QMainWindow with a QGridLayout of various widgets that looks like the attached png.

layout.jpg

I will have various little input dialogs that come up at different times, and I want them to appear in certain cell of the layout (bright cyan area below purple tab widget in picture). They would show up in this cell by default but should be detachable and able to be moved around as desired (just like a regular, stray QDialog).

What would be the best way to go about this?

I tried using a QDockWidget and just adding it right into the grid layout, but it seems I cannot un-dock it and move it around, even with a call to setFeatures that should allow this freedom.

The addDockWidget function allows the desired movement, but this won't let me incorporate the dock area within the grid; it just puts the dock widget on, e.g., one side of the entire main window.