On 7/22/12 6:30 AM, Bo Thorsen wrote:
> Den 21-07-2012 18:27, Stephen Chu skrev:
>> I am working on a dynamically generated form. One thing I'd like to do
>> is to reflow the layout into multi-column when the widgets fill the
>> preset window height.
>>
>> I need to find out what the current layout height is before I add the
>> new widget. The problem is, layout geometry is always 0x0 before the
>> window is shown. And if I show the window before adding the widgets, not
>> only does the window flickers badly, it also doesn't auto-position
>> correctly. What's worse, the geometry reported is still 0x0.
>>
>> So how do I get the correct layout or parent widget size before showing
>> the widget/window? Thanks.
>
> You can't use size or geometry because they are properties of what is
> actually shown.
>
> For your case, you should use the minimum sizes instead. Those should be
> available to you.
>

Thanks. That works. Do you happen to know how I can get the size of a 
window maximized without first maximize it?

Thanks.


_______________________________________________
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest

Reply via email to