|
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 |
} |