Title: [253322] trunk/Source/WebCore
Revision
253322
Author
[email protected]
Date
2019-12-10 06:34:42 -0800 (Tue, 10 Dec 2019)

Log Message

[LFC][IFC] Fix fast/text/basic/005.html
https://bugs.webkit.org/show_bug.cgi?id=205047
<rdar://problem/57780017>

Reviewed by Antti Koivisto.

Remove the code that triggers the assert on negative word-spacing.
Trimming is safe with negative values (and any negative trimmed width special handing should be in LineBreaker).

* layout/inlineformatting/InlineLineBuilder.cpp:
(WebCore::Layout::LineBuilder::TrimmableContent::append):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (253321 => 253322)


--- trunk/Source/WebCore/ChangeLog	2019-12-10 09:41:35 UTC (rev 253321)
+++ trunk/Source/WebCore/ChangeLog	2019-12-10 14:34:42 UTC (rev 253322)
@@ -1,3 +1,17 @@
+2019-12-10  Zalan Bujtas  <[email protected]>
+
+        [LFC][IFC] Fix fast/text/basic/005.html
+        https://bugs.webkit.org/show_bug.cgi?id=205047
+        <rdar://problem/57780017>
+
+        Reviewed by Antti Koivisto.
+
+        Remove the code that triggers the assert on negative word-spacing.
+        Trimming is safe with negative values (and any negative trimmed width special handing should be in LineBreaker).
+
+        * layout/inlineformatting/InlineLineBuilder.cpp:
+        (WebCore::Layout::LineBuilder::TrimmableContent::append):
+
 2019-12-10  Yusuke Suzuki  <[email protected]>
 
         [JSC] Put JSArray in IsoSubspace

Modified: trunk/Source/WebCore/layout/inlineformatting/InlineLineBuilder.cpp (253321 => 253322)


--- trunk/Source/WebCore/layout/inlineformatting/InlineLineBuilder.cpp	2019-12-10 09:41:35 UTC (rev 253321)
+++ trunk/Source/WebCore/layout/inlineformatting/InlineLineBuilder.cpp	2019-12-10 14:34:42 UTC (rev 253322)
@@ -715,10 +715,6 @@
         ASSERT(trimmableRun.hasTrailingLetterSpacing());
         trimmableWidth = trimmableRun.trailingLetterSpacing();
     }
-    // word-spacing could very well be negative, but it does not mean that the line gains that much extra space when the content is trimmed.
-    trimmableWidth = std::max<InlineLayoutUnit>(0, trimmableWidth);
-
-    ASSERT(trimmableWidth >= 0);
     m_width += trimmableWidth;
     m_lastRunIsFullyTrimmable = isFullyTrimmable;
     m_firstRunIndex = m_firstRunIndex.valueOr(runIndex);
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to