View | Details | Raw Unified | Return to bug 153029
Collapse All | Expand All

(-)src/kernel/qlayout.cpp.sav (-8 / +9 lines)
Lines 679-685 void QGridLayoutData::addHfwData( QGridB Link Here
679
    if ( box->hasHeightForWidth() ) {
679
    if ( box->hasHeightForWidth() ) {
680
	int hint = box->heightForWidth( width );
680
	int hint = box->heightForWidth( width );
681
	rData[box->row].sizeHint = QMAX( hint, rData[box->row].sizeHint );
681
	rData[box->row].sizeHint = QMAX( hint, rData[box->row].sizeHint );
682
	rData[box->row].minimumSize = QMAX( hint, rData[box->row].minimumSize );
682
	rData[box->row].minimumSize = QMAX( box->minimumSize().height(), rData[box->row].minimumSize );
683
//	rData[box->row].minimumSize = QMAX( hint, rData[box->row].minimumSize );
683
    } else {
684
    } else {
684
	QSize hint = box->sizeHint();
685
	QSize hint = box->sizeHint();
685
	QSize minS = box->minimumSize();
686
	QSize minS = box->minimumSize();
Lines 733-740 void QGridLayoutData::setupHfwLayoutData Link Here
733
		    int hfwh = box->heightForWidth( w );
734
		    int hfwh = box->heightForWidth( w );
734
		    if ( hfwh > hint.height() )
735
		    if ( hfwh > hint.height() )
735
			hint.setHeight( hfwh );
736
			hint.setHeight( hfwh );
736
		    if ( hfwh > min.height() )
737
//		    if ( hfwh > min.height() )
737
			min.setHeight( hfwh );
738
//			min.setHeight( hfwh );
738
		}
739
		}
739
		distributeMultiBox( rData, spacing, r1, r2,
740
		distributeMultiBox( rData, spacing, r1, r2,
740
				    min.height(), hint.height(),
741
				    min.height(), hint.height(),
Lines 1528-1538 struct QBoxLayoutItem Link Here
1528
	}
1529
	}
1529
    }
1530
    }
1530
    int mhfw( int w ) {
1531
    int mhfw( int w ) {
1531
	if ( item->hasHeightForWidth() ) {
1532
//	if ( item->hasHeightForWidth() ) {
1532
	    return item->heightForWidth( w );
1533
//	    return item->heightForWidth( w );
1533
	} else {
1534
//	} else {
1534
	    return item->minimumSize().height();
1535
	    return item->minimumSize().height();
1535
	}
1536
//	}
1536
    }
1537
    }
1537
    int hStretch() {
1538
    int hStretch() {
1538
	if ( stretch == 0 && item->widget() ) {
1539
	if ( stretch == 0 && item->widget() ) {
Lines 1909-1915 void QBoxLayout::setGeometry( const QRec Link Here
1909
	    for ( int i = 0; i < n; i++ ) {
1910
	    for ( int i = 0; i < n; i++ ) {
1910
		QBoxLayoutItem *box = data->list.at( i );
1911
		QBoxLayoutItem *box = data->list.at( i );
1911
		if ( box->item->hasHeightForWidth() )
1912
		if ( box->item->hasHeightForWidth() )
1912
		    a[i].sizeHint = a[i].minimumSize =
1913
		    a[i].sizeHint /*= a[i].minimumSize*/ =
1913
				    box->item->heightForWidth( s.width() );
1914
				    box->item->heightForWidth( s.width() );
1914
	    }
1915
	    }
1915
	}
1916
	}
(-)src/widgets/qlabel.cpp.sav (-15 / +1 lines)
Lines 636-656 QSize QLabel::minimumSizeHint() const Link Here
636
    constPolish();
636
    constPolish();
637
    d->valid_hints = frameWidth();
637
    d->valid_hints = frameWidth();
638
    d->sh = sizeForWidth( -1 );
638
    d->sh = sizeForWidth( -1 );
639
    QSize sz( -1, -1 );
639
    QSize sz = d->sh;
640
641
    if (
642
#ifndef QT_NO_RICHTEXT
643
	 !doc &&
644
#endif
645
	 (align & WordBreak) == 0 ) {
646
	sz = d->sh;
647
    } else {
648
	// think about caching these for performance
649
	sz.rwidth() = sizeForWidth( 0 ).width();
650
	sz.rheight() = sizeForWidth(QWIDGETSIZE_MAX).height();
651
	if ( d->sh.height() < sz.height() )
652
	    sz.rheight() = d->sh.height();
653
    }
654
    if ( sizePolicy().horData() == QSizePolicy::Ignored )
640
    if ( sizePolicy().horData() == QSizePolicy::Ignored )
655
	sz.rwidth() = -1;
641
	sz.rwidth() = -1;
656
    if ( sizePolicy().verData() == QSizePolicy::Ignored )
642
    if ( sizePolicy().verData() == QSizePolicy::Ignored )

Return to bug 153029