Title: [245810] trunk/Source/WebCore
- Revision
- 245810
- Author
- [email protected]
- Date
- 2019-05-28 07:48:57 -0700 (Tue, 28 May 2019)
Log Message
[LFC[IFC] Ignore the initial strut's height when the line does not have any content.
https://bugs.webkit.org/show_bug.cgi?id=198268
<rdar://problem/51150057>
Reviewed by Antti Koivisto.
The strut (https://www.w3.org/TR/CSS22/visudet.html#leading) defines the initial logical height
for the line. This height should be ignored though when the line does not have any content.
* layout/inlineformatting/InlineFormattingContextLineLayout.cpp:
(WebCore::Layout::InlineFormattingContext::LineLayout::closeLine const):
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (245809 => 245810)
--- trunk/Source/WebCore/ChangeLog 2019-05-28 12:33:11 UTC (rev 245809)
+++ trunk/Source/WebCore/ChangeLog 2019-05-28 14:48:57 UTC (rev 245810)
@@ -1,3 +1,17 @@
+2019-05-28 Zalan Bujtas <[email protected]>
+
+ [LFC[IFC] Ignore the initial strut's height when the line does not have any content.
+ https://bugs.webkit.org/show_bug.cgi?id=198268
+ <rdar://problem/51150057>
+
+ Reviewed by Antti Koivisto.
+
+ The strut (https://www.w3.org/TR/CSS22/visudet.html#leading) defines the initial logical height
+ for the line. This height should be ignored though when the line does not have any content.
+
+ * layout/inlineformatting/InlineFormattingContextLineLayout.cpp:
+ (WebCore::Layout::InlineFormattingContext::LineLayout::closeLine const):
+
2019-05-27 Antoine Quint <[email protected]>
[Pointer Events] Check that capturing data managed by the PointerCaptureController gets cleared upon navigation
Modified: trunk/Source/WebCore/layout/inlineformatting/InlineFormattingContextLineLayout.cpp (245809 => 245810)
--- trunk/Source/WebCore/layout/inlineformatting/InlineFormattingContextLineLayout.cpp 2019-05-28 12:33:11 UTC (rev 245809)
+++ trunk/Source/WebCore/layout/inlineformatting/InlineFormattingContextLineLayout.cpp 2019-05-28 14:48:57 UTC (rev 245810)
@@ -470,7 +470,9 @@
Optional<unsigned> previousLineLastRunIndex = inlineDisplayRuns.isEmpty() ? Optional<unsigned>() : inlineDisplayRuns.size() - 1;
// 9.4.2 Inline formatting contexts
// A line box is always tall enough for all of the boxes it contains.
- auto lineBox = Display::Rect { line.logicalTop(), line.logicalLeft(), 0 , line.logicalHeight() };
+
+ // Ignore the initial strut.
+ auto lineBox = Display::Rect { line.logicalTop(), line.logicalLeft(), 0 , line.hasContent() ? line.logicalHeight() : LayoutUnit { } };
// Create final display runs.
for (unsigned index = 0; index < lineItems.size(); ++index) {
auto& lineItem = lineItems.at(index);
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes