[Qt-interest] How to fix the size of a LineEditor in a Layout

Pierre-Luc Loyer ployer at gmail.com
Tue Jun 23 18:38:05 CEST 2009


Hi,
I am new to Qt, but i'll try anyway.
Have you tried to set : QWidget -> maximumSize -> Width = 40.

On Tue, Jun 23, 2009 at 2:16 AM, Joe Liu <passer.by007gg at gmail.com> wrote:

> Hi,
>
> I use Qt designer to generate the layout of all widgets in my dialog.
>
> I now have two widgets, a LineEditor and a Slider. I grouped them in an
> HBoxLayout, however, every time I attempt to do so, the lineeditor is
> automatically resized to 133 pixel width, while I actually want one in 40
> pixel width.
>
> I tried to assign the lineeditor different size policies, but they seems do
> not work at all. I can not change the lineeditor's size in whatever way.
>
> Do you have any idea on how to force a lineeditor to a customized size by
> using the Qt Designer?
>
> Thank you.
>
> Joe
>
> _______________________________________________
> Qt-interest mailing list
> Qt-interest at trolltech.com
> http://lists.trolltech.com/mailman/listinfo/qt-interest
>
>


-- 
Pierre-Luc Loyer
Tél. : (514) 519-1220
Programmeur de jeux Wii
A2M
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20090623/2e140da7/attachment.html 


More information about the Qt-interest-old mailing list