Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(963)

Unified Diff: Source/core/layout/MultiColumnFragmentainerGroup.cpp

Issue 1017263004: [New Multicolumn] Give up on stretching columns if they have already reached max height. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « LayoutTests/fast/multicol/unbreakable-content-taller-than-height-crash-expected.txt ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/layout/MultiColumnFragmentainerGroup.cpp
diff --git a/Source/core/layout/MultiColumnFragmentainerGroup.cpp b/Source/core/layout/MultiColumnFragmentainerGroup.cpp
index 54cd8bb2c3f7d110cec522fd9b07de710cf512fc..42182d48114ab066d248a33e1a8fad9a89fe013f 100644
--- a/Source/core/layout/MultiColumnFragmentainerGroup.cpp
+++ b/Source/core/layout/MultiColumnFragmentainerGroup.cpp
@@ -420,6 +420,13 @@ LayoutUnit MultiColumnFragmentainerGroup::calculateColumnHeight(BalancedColumnHe
return m_columnHeight;
}
+ if (m_columnHeight >= m_maxColumnHeight) {
+ // We cannot stretch any further. We'll just have to live with the overflowing columns. This
+ // typically happens if the max column height is less than the height of the tallest piece
+ // of unbreakable content (e.g. lines).
+ return m_columnHeight;
+ }
+
// If the initial guessed column height wasn't enough, stretch it now. Stretch by the lowest
// amount of space shortage found during layout.
« no previous file with comments | « LayoutTests/fast/multicol/unbreakable-content-taller-than-height-crash-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698