QGridLayout span problems
-
Hey,
I've got a problem with spanned items in grid layout.I want to have a layout as seen on this picture:
"Aaaa..." -
QLabel, addWidget(..., 0, 0, 1, 5), QSizePolicy::Preferred
Line edit -QLineEdit, addWidget(..., 0, 5, 1, 1), QSizePolicy::Preferred
"Bbb" -QLabel, addWidget(..., 1, 0, 1, 1), QSizePolicy::Preferred
Line edit (short) -QLineEdit, addWidget(..., 1, 1, 1, 1), QSizePolicy::Fixed
Line edit (long) -QLineEdit, addWidget(..., 1, 3, 1, 2), QSizePolicy::Ignored
But what I get is this:
As one can see the "Aaaa..." label space is divided equally between the cell 0...4 (see the second row). But what I need is to divide "spanned" space non-lineary between widgets base on size of the widget.
Could this be somehow done with QGridLayout or do I need to implement my own layout manager?
Thank you