Skip to main content

All Questions

Tagged with
3 votes
2 answers
4k views

How to restrict growth (size) of layout in Qt Designer?

When I maximize my window, I want to restrict a vertical layout (and the entire row below it also) so that it has a specific size (lets say a width of 200). How can I achieve this? Below is what I get ...
Bibek's user avatar
  • 3,719
0 votes
1 answer
1k views

Arrange widgets in layout

i want to achieve following layout behavior: | A | B | | A | | 1) |---- -----| 2) |---- D | | C | D | | C | | Align A,B,C,D with each other and allow D to ...
Shf's user avatar
  • 3,493
4 votes
4 answers
4k views

QDockWidget layout with no central widget

I have a problem with QDockWidget. I'm using Qt Designer, and I would like to build an app with only dock-widgets, and have a small bar above for properties. The problem is that I cannot build the app ...
Przemek Lewandowski's user avatar
2 votes
1 answer
3k views

How to keep widget in the center of layout

I'm working on Qt interface now and I have a widget in the center of the window, the widget has fixed size. when I resize the window with mouse the widget stays at the left of the window. I don't want ...
tokafr's user avatar
  • 119
5 votes
3 answers
12k views

How to programmatically change the order of widgets in a layout?

I do have a QVBoxLayout that contains some custom widgets, which themselves mainly consist of a label and two buttons. You can almost speak of some kind of selfmade table in a way. I know that there ...
Rob's user avatar
  • 11.8k
4 votes
1 answer
850 views

How to achieve equal-sized FormLayout across collapsible panels?

I think this might be two separated questions. In Qt4.8, the QFormLayout is The QFormLayout class manages forms of input widgets and their associated labels. QFormLayout is a convenience ...
Drake Guan's user avatar
  • 15.1k
23 votes
2 answers
75k views

About deleting, removing widgets and layouts in Qt 4

(I use Qt 4.7, Windows 7, 64bit). I created a custom table. Each row is a horizontal layout with widgets. The rows are kept in a QList for easy access, and the children too. The rows are also added ...
Darkgaze's user avatar
  • 2,543
2 votes
2 answers
3k views

switching layouts in Qt

I have 2 layouts - layout1 and layout2. Let's say both are entirely different in terms of number of types of widget in them. Now I have 2 buttons but1 and but2. When but1 is cliked layout1 is ...
sudeepdino008's user avatar
1 vote
2 answers
3k views

Qt gridlayout square cells

I have a screen ui file that has a grid layout and 8 buttons laid out something like this --------------------- | | | 1 2 3 4 | | | | ...
Professor Chaos's user avatar
1 vote
2 answers
952 views

Qt layout adds unnecessary space

I'm creating a calender app and I finished the view widget for an appointment, which is basically a collection of QLabels. It works like a charm, but I have a problem with the layout of the last 3 ...
TheDudeAbides's user avatar
2 votes
1 answer
1k views

QBoxLayout screws up QFormLayout?

Following simplified code snippet: #include <QtGui> int main(int argc, char **argv) { QApplication app(argc, argv); QWidget *window = new QWidget(); QFormLayout *form = new QFormLayout(); // ...
Ancurio's user avatar
  • 1,728
7 votes
4 answers
13k views

Expanding a Qt Layout : how to put a widget on the right side and the let the other widget to fully fill the left?

I want to put a widget on the right side of a QHBoxLayout, and the other spaces should expand the left side. I've set the widget's SizePolicy to Expanding, but it's not valid. Anyone could offer some ...
user3294's user avatar
1 vote
1 answer
2k views

Qt QHBoxLayout issue?

I use an extended QGroupBox as the widget for QDockWidget in my QMainWindow. Here is the code snippet: RzPlaneViewerControlPanelWidget::RzPlaneViewerControlPanelWidget(QWidget *parent) : QGroupBox(...
Ashika Umanga Umagiliya's user avatar
1 vote
1 answer
1k views

shrink the parent window instead of having other widgets grow

I have a window, which only contains one groupbox, which contains several more groupboxes in a QVBoxLayout (the content of those doesnt have a fixed size either). Those inner groupboxes are checkable, ...
smerlin's user avatar
  • 6,556
0 votes
1 answer
1k views

Qt layouting problem

Im implementing a Widget which is basically a list of buttons (which represent a file structure). It looks like this: [[recentFolder] // bar [(stretch) [folderA], // foo [folderB], ...
atamanroman's user avatar
  • 11.8k

15 30 50 per page