[prev in list] [next in list] [prev in thread] [next in thread]
List: webkit-changes
Subject: [webkit-changes] [WebKit/WebKit] 9fac64: [LFC][IFC] Fix editing/inserting/inserting-trailin...
From: alan <noreply () github ! com>
Date: 2022-09-28 14:26:26
Message-ID: WebKit/WebKit/push/refs/heads/main/cde78a-9fac64 () github ! com
[Download RAW message or body]
Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 9fac64bb2d1299aa64a395be40149426e7d2a7b7
https://github.com/WebKit/WebKit/commit/9fac64bb2d1299aa64a395be40149426e7d2a7b7
Author: Alan Bujtas <zalan@apple.com>
Date: 2022-09-28 (Wed, 28 Sep 2022)
Changed paths:
M LayoutTests/platform/ios/fast/text/whitespace/nbsp-mode-and-linewraps-expected.txt
M LayoutTests/platform/mac/fast/text/whitespace/nbsp-mode-and-linewraps-expected.txt
M Source/WebCore/layout/formattingContexts/inline/InlineContentBreaker.cpp
M Source/WebCore/layout/formattingContexts/inline/InlineContentBreaker.h
M Source/WebCore/layout/formattingContexts/inline/InlineFormattingQuirks.cpp
M Source/WebCore/layout/formattingContexts/inline/InlineFormattingQuirks.h
M Source/WebCore/layout/formattingContexts/inline/InlineItemsBuilder.cpp
M Source/WebCore/layout/formattingContexts/inline/InlineLine.cpp
M Source/WebCore/layout/formattingContexts/inline/InlineLine.h
M Source/WebCore/layout/formattingContexts/inline/InlineLineBuilder.cpp
M Source/WebCore/layout/formattingContexts/inline/InlineTextItem.cpp
M Source/WebCore/layout/formattingContexts/inline/InlineTextItem.h
Log Message:
-----------
[LFC][IFC] Fix editing/inserting/inserting-trailing-space-and-letter.html
https://bugs.webkit.org/show_bug.cgi?id=245709
Reviewed by Antti Koivisto.
This patch completes (converts really) "-webkit-nbsp-mode: space" quirk \
implementation to support another quirk, "line-break: after-white-space".
 's behavior when "-webkit-nbsp-mode: space" is present as follows:
- intrinsic width computation:   character is included as is
- normal inline line layout:
- no overflow:   character is included as is (no-collapse, no-trim).
- overflow when "line-breaking" is not "after-white-space": no-collapse, remove the \
overflowing part of the &nbps sequence
- overflow when "line-breaking" is "after-white-space": no-collapse, no-trim but \
reset the size of the overflowing part of the &nbps sequence to 0.
- ignore all these "what if overflow" above when "white-space" is "pre" or \
"nowrap".
- oh and slightly overflow/underflow (by one  ) when "white-space" is \
"break-spaces" (not included in this patch).
(remove the old quirk implementation and replace it with to support ^^^)
* Source/WebCore/layout/formattingContexts/inline/InlineContentBreaker.cpp:
(WebCore::Layout::InlineContentBreaker::ContinuousContent::resetTrailingWhitespace): \
leftover rename..
* Source/WebCore/layout/formattingContexts/inline/InlineItemsBuilder.cpp: let's \
construct individual items for each   to make trim/remove simpler
* Source/WebCore/layout/formattingContexts/inline/InlineLine.cpp:
(WebCore::Layout::Line::appendTextContent):
(WebCore::Layout::Line::initialize): remove old quirk
(WebCore::Layout::Line::handleOverflowingNonBreakingSpace): find the first index from \
where we go forward and trim/remove/adjust runs.
*fast/text/whitespace/nbsp-mode-and-linewraps.html: Dedicated runs. No visual change.
Canonical link: https://commits.webkit.org/254955@main
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic