Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 12d6cdfb97ad6ac9e5728bda3a456a09de62cae1
https://github.com/WebKit/WebKit/commit/12d6cdfb97ad6ac9e5728bda3a456a09de62cae1
Author: Kiet Ho <[email protected]>
Date: 2025-09-17 (Wed, 17 Sep 2025)
Changed paths:
A
LayoutTests/fast/css/css-anchor-position/position-visibility-add-no-overflow-expected.html
A
LayoutTests/fast/css/css-anchor-position/position-visibility-add-no-overflow.html
M Source/WebCore/rendering/style/RenderStyle.cpp
Log Message:
-----------
[css-anchor-position-1] Change in used visibility should trigger repaint
rdar://160719145
https://bugs.webkit.org/show_bug.cgi?id=298975
Reviewed by Antti Koivisto.
Changes to the visibility of the element should trigger repaint. However,
RenderStyle::changeRequiresRepaint only checks visibility(), which is the
value of the 'visibility' property. Besides setting 'visibility', an element
can also be "force hidden" by calling RenderStyle::setIsForceHidden()
(which sets the isForceHidden bit in RenderStyle::StyleRareInheritedData).
Change it to check usedVisibility() instead, which accounts for 'visibility'
and force hidden.
This was caught by
imported/w3c/web-platform-tests/css/css-anchor-position/position-visibility-add-no-overflow.html,
but only in Safari, not WKTR. WKTR forces a full repaint before taking
screenshot for comparison, hence why this wasn't caught (because this bug
is about a missed repaint). Adds a similar test that calls
testRunner.dontForceRepaint() to disable full repaint before taking screenshot,
which helps reproduce the issue in WKTR.
Test: fast/css/css-anchor-position/position-visibility-add-no-overflow.html
*
LayoutTests/fast/css/css-anchor-position/position-visibility-add-no-overflow-expected.html:
Added.
*
LayoutTests/fast/css/css-anchor-position/position-visibility-add-no-overflow.html:
Added.
* Source/WebCore/rendering/style/RenderStyle.cpp:
(WebCore::RenderStyle::changeRequiresRepaint const):
Canonical link: https://commits.webkit.org/300132@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes