Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Disabled splitter in qt designer

Tags:

I'm using qt 4.8.0 on windows 7. When I open qt designer and create widget in it, I cannot set 'Lay Out in a vertical/horizontal in Splitter'. Also there is no Splitter in a Layouts widget box. All other layouts are working well.

Have anyone run into same or similar problem?

like image 663
Mujo Osmanovic Avatar asked May 08 '12 13:05

Mujo Osmanovic


People also ask

How do you use a QT splitter?

Select the widgets that you want to be in a splitter (By holding CTL and clicking on them) Right click on a selected widget and from Layout menu select Lay Out Horizontally in Splitter or Lay Out Vertically in Splitter. Now apply a grid layout to the dialog and everything should be OK.

What is QSplitter?

Detailed Description. A splitter lets the user control the size of child widgets by dragging the boundary between them. Any number of widgets may be controlled by a single splitter. The typical use of a QSplitter is to create several widgets and add them using insertWidget() or addWidget().

How do I enable design in Qt?

To switch between forms (Design mode) and code (Edit mode), press Shift+F4. You can use Qt Creator to create stub implementations of slot functions.


1 Answers

You need to select two or more widgets and then use the layout -> vertical/horizontal splitter option. This will give designer enough context to be able to perform the operation.

Also note that the selected widgets cannot be part of a layout already. If they are, you need to break the layout first (layout->Break Layout in context menu).

like image 165
Chris Avatar answered Sep 24 '22 00:09

Chris