diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/widgets/graphicsview/qgridlayoutengine.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/widgets/graphicsview/qgridlayoutengine.cpp b/src/widgets/graphicsview/qgridlayoutengine.cpp index b80612bc47..adb13687db 100644 --- a/src/widgets/graphicsview/qgridlayoutengine.cpp +++ b/src/widgets/graphicsview/qgridlayoutengine.cpp @@ -1713,7 +1713,8 @@ void QGridLayoutEngine::ensureGeometries(const QLayoutStyleInfo &styleInfo, q_descents.resize(rowCount()); if (constraintOrientation() != Qt::Horizontal) { - //We might have items whose width depends on their height + // We might have items whose height depends on their width, + // or none of the items has a dynamic constraint. ensureColumnAndRowData(&q_columnData, &q_totalBoxes[Hor], styleInfo, NULL, NULL, Qt::Horizontal); //Calculate column widths and positions, and put results in q_xx.data() and q_widths.data() so that we can use this information as //constraints to find the row heights @@ -1724,7 +1725,7 @@ void QGridLayoutEngine::ensureGeometries(const QLayoutStyleInfo &styleInfo, q_rowData.calculateGeometries(0, rowCount(), size.height(), q_yy.data(), q_heights.data(), q_descents.data(), q_totalBoxes[Ver], q_infos[Ver]); } else { - //We have items whose height depends on their width + // We have items whose width depends on their height ensureColumnAndRowData(&q_rowData, &q_totalBoxes[Ver], styleInfo, NULL, NULL, Qt::Vertical); //Calculate row heights and positions, and put results in q_yy.data() and q_heights.data() so that we can use this information as //constraints to find the column widths |