Title: [272472] trunk/Source/WebCore
- Revision
- 272472
- Author
- [email protected]
- Date
- 2021-02-07 07:33:34 -0800 (Sun, 07 Feb 2021)
Log Message
[LFC][IFC] A line with no content should always take the fast vertical alignment path
https://bugs.webkit.org/show_bug.cgi?id=221524
Reviewed by Antti Koivisto.
* layout/inlineformatting/InlineFormattingContextGeometry.cpp:
(WebCore::Layout::LineBoxBuilder::constructInlineLevelBoxes):
(WebCore::Layout::LineBoxBuilder::computeLineBoxHeightAndAlignInlineLevelBoxesVertically):
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (272471 => 272472)
--- trunk/Source/WebCore/ChangeLog 2021-02-07 11:13:28 UTC (rev 272471)
+++ trunk/Source/WebCore/ChangeLog 2021-02-07 15:33:34 UTC (rev 272472)
@@ -1,3 +1,14 @@
+2021-02-07 Zalan Bujtas <[email protected]>
+
+ [LFC][IFC] A line with no content should always take the fast vertical alignment path
+ https://bugs.webkit.org/show_bug.cgi?id=221524
+
+ Reviewed by Antti Koivisto.
+
+ * layout/inlineformatting/InlineFormattingContextGeometry.cpp:
+ (WebCore::Layout::LineBoxBuilder::constructInlineLevelBoxes):
+ (WebCore::Layout::LineBoxBuilder::computeLineBoxHeightAndAlignInlineLevelBoxesVertically):
+
2021-02-06 Alex Christensen <[email protected]>
Non-special URLs should have an opaque origin
Modified: trunk/Source/WebCore/layout/inlineformatting/InlineFormattingContextGeometry.cpp (272471 => 272472)
--- trunk/Source/WebCore/layout/inlineformatting/InlineFormattingContextGeometry.cpp 2021-02-07 11:13:28 UTC (rev 272471)
+++ trunk/Source/WebCore/layout/inlineformatting/InlineFormattingContextGeometry.cpp 2021-02-07 15:33:34 UTC (rev 272472)
@@ -369,7 +369,10 @@
}
lineBox.setHasContent(lineHasContent);
- if (lineHasContent && !m_inlineLevelBoxesNeedVerticalAlignment) {
+ if (!lineHasContent) {
+ // We should always be able to exercise the fast path when the line has no content at all.
+ m_inlineLevelBoxesNeedVerticalAlignment = false;
+ } else if (!m_inlineLevelBoxesNeedVerticalAlignment) {
// FIXME: Add fast path support for line-height content.
m_inlineLevelBoxesNeedVerticalAlignment = !rootBox().style().lineHeight().isNegative();
}
@@ -387,6 +390,7 @@
void LineBoxBuilder::computeLineBoxHeightAndAlignInlineLevelBoxesVertically(LineBox& lineBox)
{
+ ASSERT(lineBox.hasContent());
// This function (partially) implements:
// 2.2. Layout Within Line Boxes
// https://www.w3.org/TR/css-inline-3/#line-layout
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes