Title: [269821] trunk/Source/WebCore
- Revision
- 269821
- Author
- [email protected]
- Date
- 2020-11-14 13:43:44 -0800 (Sat, 14 Nov 2020)
Log Message
[LFC][IFC] Negative margin before (>border box height value) completely pulls the inline level box out of the line box
https://bugs.webkit.org/show_bug.cgi?id=218945
Reviewed by Antti Koivisto.
maximumTopOffsetFromRootInlineBoxBaseline could very well be negative e.g
<div><div style="display: inline-block; height: 10px; margin-top: -20px"></div></div>.
* layout/inlineformatting/InlineFormattingContextGeometry.cpp:
(WebCore::Layout::LineBoxBuilder::computeLineBoxHeightAndalignInlineLevelBoxesVertically):
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (269820 => 269821)
--- trunk/Source/WebCore/ChangeLog 2020-11-14 19:46:16 UTC (rev 269820)
+++ trunk/Source/WebCore/ChangeLog 2020-11-14 21:43:44 UTC (rev 269821)
@@ -1,3 +1,16 @@
+2020-11-14 Zalan Bujtas <[email protected]>
+
+ [LFC][IFC] Negative margin before (>border box height value) completely pulls the inline level box out of the line box
+ https://bugs.webkit.org/show_bug.cgi?id=218945
+
+ Reviewed by Antti Koivisto.
+
+ maximumTopOffsetFromRootInlineBoxBaseline could very well be negative e.g
+ <div><div style="display: inline-block; height: 10px; margin-top: -20px"></div></div>.
+
+ * layout/inlineformatting/InlineFormattingContextGeometry.cpp:
+ (WebCore::Layout::LineBoxBuilder::computeLineBoxHeightAndalignInlineLevelBoxesVertically):
+
2020-11-14 Rob Buis <[email protected]>
Remove -webkit-aspect-ratio support
Modified: trunk/Source/WebCore/layout/inlineformatting/InlineFormattingContextGeometry.cpp (269820 => 269821)
--- trunk/Source/WebCore/layout/inlineformatting/InlineFormattingContextGeometry.cpp 2020-11-14 19:46:16 UTC (rev 269820)
+++ trunk/Source/WebCore/layout/inlineformatting/InlineFormattingContextGeometry.cpp 2020-11-14 21:43:44 UTC (rev 269821)
@@ -404,7 +404,7 @@
HashMap<LineBox::InlineLevelBox*, InlineLayoutUnit> inlineLevelBoxAbsoluteBaselineOffsetMap;
inlineLevelBoxAbsoluteBaselineOffsetMap.add(&rootInlineBox, InlineLayoutUnit { });
- auto maximumTopOffsetFromRootInlineBoxBaseline = rootInlineBox.isEmpty() ? InlineLayoutUnit() : rootInlineBox.layoutBounds().ascent;
+ auto maximumTopOffsetFromRootInlineBoxBaseline = rootInlineBox.isEmpty() ? std::numeric_limits<InlineLayoutUnit>::min() : rootInlineBox.layoutBounds().ascent;
for (auto& inlineLevelBox : lineBox.nonRootInlineLevelBoxes()) {
auto absoluteBaselineOffset = InlineLayoutUnit { };
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes