[Qt-interest] adapt the size of a QLabel inside a QVBoxLayout
Tony Rietwyk
tony.rietwyk at rightsoft.com.au
Tue Feb 24 09:07:25 CET 2009
Hi Markus,
Try label->updateGeometry()
Tony
> -----Original Message-----
> From: qt-interest-bounces at trolltech.com
> [mailto:qt-interest-bounces at trolltech.com] On Behalf Of Markus Franke
> Sent: Tuesday, 24 February 2009 19:00
> To: qt-interest at trolltech.com
> Subject: [Qt-interest] adapt the size of a QLabel inside a QVBoxLayout
>
>
> Dear Qt Developers/Users,
>
> I have a QLabel inside a QVBoxLayout. The text of the QLabel is
> dynamic, word wrapping is enabled for the QLabel and I am calling
> QWidget::adjustSize() on the QLabel.
>
> However, if the text inside the QLabel is too long the QVBoxLayout
> doen't adapt it's size according to the contents of the
> QLabel. After
> 3 lines of text the rest is simply cut off.
>
> How can I achieve the wanted behaviour?
>
> Thanks for any comments on this,
>
> Markus Franke
>
> _______________________________________________
> Qt-interest mailing list
> Qt-interest at trolltech.com
> http://lists.trolltech.com/mailman/listinfo/qt-interest
>
>
> __________ NOD32 3881 (20090223) Information __________
>
> This message was checked by NOD32 antivirus system.
> http://www.eset.com
>
>
More information about the Qt-interest-old
mailing list