How to manage QSplitter in Qt Designer

Okay, I know this is ancient, but here's the complete answer.

First, within some sort of widget container, plop your pieces in. For the window I just did, I have a Widget as my window. I put two widgets inside that labeled something like topContainer and bottomContainer. I then put all the widgets they each need into them, and gave them their own layouts.

Then do NOT select the main container. Select the two widgets you want to split. You're in effect putting a splitter on them, not on the main container. So I went to the widget list window and selected both together, then right-click for the dialog window, scroll down to the Layout option, and "Lay Out Vertically in a Splitter" is NOT greyed out. Select it.

You still need a layout on the main container. A splitter is not a layout. So at that point, I just put a vertical layout on the main container.

To repeat: you are NOT setting a layout on the container holding the pieces you're trying to split. You are selecting the two widgets to split and adding a QSplitter around them. That's the trick to get it to work.


You can simply create splitter containing items in Qt Designer :

  1. First place your widgets on your dialog or widget in designer (They should not be in a layout)

  2. Select the widgets that you want to be in a splitter (By holding CTL and clicking on them)

  3. Right click on a selected widget and from Layout menu select Lay Out Horizontally in Splitter or Lay Out Vertically in Splitter.

  4. Now apply a grid layout to the dialog and everything should be OK. You would see something like this in Object Inspector View :

enter image description here