[webkit-changes] [WebKit/WebKit] bbbde6: text-box-trim accumulation fails when updating the...
Alan Baradlay
noreply at github.com
Mon Jan 6 11:57:28 PST 2025
Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: bbbde60e23e97720b206965523240fe819172957
https://github.com/WebKit/WebKit/commit/bbbde60e23e97720b206965523240fe819172957
Author: Alan Baradlay <zalan at apple.com>
Date: 2025-01-06 (Mon, 06 Jan 2025)
Changed paths:
A LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-set-dynamically-expected.html
A LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-set-dynamically-ref.html
A LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-set-dynamically.html
M Source/WebCore/layout/integration/inline/LayoutIntegrationLineLayout.cpp
M Source/WebCore/page/LocalFrameViewLayoutContext.cpp
M Source/WebCore/page/LocalFrameViewLayoutContext.h
M Source/WebCore/rendering/RenderLayoutState.cpp
M Source/WebCore/rendering/RenderLayoutState.h
M Source/WebCore/rendering/TextBoxTrimmer.cpp
M Source/WebCore/rendering/TextBoxTrimmer.h
Log Message:
-----------
text-box-trim accumulation fails when updating the CSS dynamically
https://bugs.webkit.org/show_bug.cgi?id=285257
<rdar://problem/142386761>
Reviewed by Antti Koivisto.
Confusing RenderLayoutState handling is confusing. Let's move text-box-trim state over to LayoutContext.
RenderLayoutState gets pushed and popped through state maintainers and text-box-trim state setting missed one of these push-pops. However since text-box-trim should always carry over its state, there's no real reason to make it complicated by using RenderLayoutState.
* LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-set-dynamically-expected.html: Added.
* LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-set-dynamically-ref.html: Added.
* LayoutTests/imported/w3c/web-platform-tests/css/css-inline/text-box-trim/text-box-trim-set-dynamically.html: Added.
* Source/WebCore/layout/integration/inline/LayoutIntegrationLineLayout.cpp:
(WebCore::LayoutIntegration::textBoxTrim):
* Source/WebCore/page/LocalFrameViewLayoutContext.cpp:
(WebCore::LocalFrameViewLayoutContext::pushLayoutState):
* Source/WebCore/page/LocalFrameViewLayoutContext.h:
* Source/WebCore/rendering/RenderLayoutState.cpp:
(WebCore::RenderLayoutState::RenderLayoutState):
* Source/WebCore/rendering/RenderLayoutState.h:
(WebCore::RenderLayoutState::textBoxTrim): Deleted.
(WebCore::RenderLayoutState::setTextBoxTrim): Deleted.
(WebCore::RenderLayoutState::hasTextBoxTrimStart const): Deleted.
(WebCore::RenderLayoutState::hasTextBoxTrimEnd const): Deleted.
(WebCore::RenderLayoutState::removeTextBoxTrimStart): Deleted.
* Source/WebCore/rendering/TextBoxTrimmer.cpp:
(WebCore::removeTextBoxTrimStart):
(WebCore::TextBoxTrimmer::TextBoxTrimmer):
(WebCore::TextBoxTrimmer::~TextBoxTrimmer):
(WebCore::TextBoxTrimmer::adjustTextBoxTrimStatusBeforeLayout):
(WebCore::TextBoxTrimmer::adjustTextBoxTrimStatusAfterLayout):
(WebCore::TextBoxTrimmer::handleTextBoxTrimNoneBeforeLayout):
* Source/WebCore/rendering/TextBoxTrimmer.h:
Canonical link: https://commits.webkit.org/288480@main
To unsubscribe from these emails, change your notification settings at https://github.com/WebKit/WebKit/settings/notifications
More information about the webkit-changes
mailing list