Skip to content

Account for perspective of the scroller when determining a transformed child's contribution to layout overflow #47032

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conversation

Ahmad-S792
Copy link
Contributor

@Ahmad-S792 Ahmad-S792 commented Jun 22, 2025

7005f16

Account for perspective of the scroller when determining a transformed child's contribution to layout overflow

https://bugs.webkit.org/show_bug.cgi?id=285282
rdar://142573993

Reviewed by Simon Fraser.

This patch aligns WebKit with Gecko / Firefox and Blink / Chromium.

Merge: https://chromium.googlesource.com/chromium/src.git/+/602f4cdf9e0944a68fe91d12ead5b2ece186b8e3

This patch fixes the case, where WebKit was failing to account for perspective
of the scroller when determining a transformed child's contribution to layout
overflow and was not drawing any scrollbar at all.

* Source/WebCore/rendering/RenderBox.cpp:
(WebCore::RenderBox::layoutOverflowRectForPropagation const):
* LayoutTests/overflow/overflow-transform-perspective.html:
* LayoutTests/overflow/overflow-transform-perspective-expected.txt:
* LayoutTests/platform/ios/overflow/overflow-transform-perspective-expected.txt:
* LayoutTests/platform/glib/overflow/overflow-transform-perspective-expected.txt:
* LayoutTests/platform/visionos/TestExpectations: Skip `overflow` directory

> Progression (No Horizontal Scrollbar - matching Chrome):
* LayoutTests/platform/glib/imported/w3c/web-platform-tests/css/css-transforms/text-perspective-001-expected.txt:
* LayoutTests/platform/ios/imported/w3c/web-platform-tests/css/css-transforms/text-perspective-001-expected.txt:
* LayoutTests/imported/w3c/web-platform-tests/css/css-transforms/text-perspective-001-expected.txt:

> Rebaseline:
* LayoutTests/compositing/tiling/perspective-on-scroller-tile-coverage-expected.txt:
* LayoutTests/platform/ios/compositing/tiling/perspective-on-scroller-tile-coverage-expected.txt:
* LayoutTests/svg/compositing/svg-poster-circle.html: Scrollbar Placement change (no rendering difference)

Canonical link: https://commits.webkit.org/296652@main

24fffdd

Misc iOS, visionOS, tvOS & watchOS macOS Linux Windows
✅ 🧪 style ✅ 🛠 ios ✅ 🛠 mac ✅ 🛠 wpe ✅ 🛠 win
✅ 🧪 bindings ✅ 🛠 ios-sim ✅ 🛠 mac-AS-debug ✅ 🧪 wpe-wk2 ⏳ 🧪 win-tests
✅ 🧪 webkitperl ✅ 🧪 ios-wk2 ✅ 🧪 api-mac ✅ 🧪 api-wpe
✅ 🧪 ios-wk2-wpt ✅ 🧪 mac-wk1 🛠 wpe-cairo
✅ 🧪 api-ios ✅ 🧪 mac-wk2 ✅ 🛠 gtk
✅ 🛠 vision 🧪 mac-AS-debug-wk2 ✅ 🧪 gtk-wk2
✅ 🛠 vision-sim ✅ 🧪 mac-wk2-stress ✅ 🧪 api-gtk
✅ 🛠 🧪 merge ✅ 🧪 vision-wk2 ✅ 🧪 mac-intel-wk2 ✅ 🛠 playstation
✅ 🛠 tv ✅ 🛠 mac-safer-cpp
✅ 🛠 tv-sim
✅ 🛠 watch
✅ 🛠 watch-sim

@Ahmad-S792 Ahmad-S792 self-assigned this Jun 22, 2025
@Ahmad-S792 Ahmad-S792 added the Layout and Rendering For bugs with layout and rendering of Web pages. label Jun 22, 2025
@webkit-ews-buildbot webkit-ews-buildbot added the merging-blocked Applied to prevent a change from being merged label Jun 22, 2025
@Ahmad-S792 Ahmad-S792 removed the merging-blocked Applied to prevent a change from being merged label Jun 24, 2025
@Ahmad-S792 Ahmad-S792 force-pushed the eng/Account-for-perspective-of-the-scroller-when-determining-a-transformed-child-s-contribution-to-layout-overflow branch from b66055b to 065506d Compare June 24, 2025 01:13
@webkit-ews-buildbot webkit-ews-buildbot added the merging-blocked Applied to prevent a change from being merged label Jun 24, 2025
@Ahmad-S792 Ahmad-S792 removed the merging-blocked Applied to prevent a change from being merged label Jun 24, 2025
@Ahmad-S792 Ahmad-S792 force-pushed the eng/Account-for-perspective-of-the-scroller-when-determining-a-transformed-child-s-contribution-to-layout-overflow branch from 065506d to d55276e Compare June 24, 2025 16:19
@webkit-ews-buildbot webkit-ews-buildbot added the merging-blocked Applied to prevent a change from being merged label Jun 24, 2025
@Ahmad-S792 Ahmad-S792 removed the merging-blocked Applied to prevent a change from being merged label Jun 26, 2025
@Ahmad-S792 Ahmad-S792 force-pushed the eng/Account-for-perspective-of-the-scroller-when-determining-a-transformed-child-s-contribution-to-layout-overflow branch from d55276e to 24fffdd Compare June 26, 2025 01:02
@Ahmad-S792 Ahmad-S792 added merge-queue Applied to send a pull request to merge-queue labels Jun 26, 2025
…d child's contribution to layout overflow

https://bugs.webkit.org/show_bug.cgi?id=285282
rdar://142573993

Reviewed by Simon Fraser.

This patch aligns WebKit with Gecko / Firefox and Blink / Chromium.

Merge: https://chromium.googlesource.com/chromium/src.git/+/602f4cdf9e0944a68fe91d12ead5b2ece186b8e3

This patch fixes the case, where WebKit was failing to account for perspective
of the scroller when determining a transformed child's contribution to layout
overflow and was not drawing any scrollbar at all.

* Source/WebCore/rendering/RenderBox.cpp:
(WebCore::RenderBox::layoutOverflowRectForPropagation const):
* LayoutTests/overflow/overflow-transform-perspective.html:
* LayoutTests/overflow/overflow-transform-perspective-expected.txt:
* LayoutTests/platform/ios/overflow/overflow-transform-perspective-expected.txt:
* LayoutTests/platform/glib/overflow/overflow-transform-perspective-expected.txt:
* LayoutTests/platform/visionos/TestExpectations: Skip `overflow` directory

> Progression (No Horizontal Scrollbar - matching Chrome):
* LayoutTests/platform/glib/imported/w3c/web-platform-tests/css/css-transforms/text-perspective-001-expected.txt:
* LayoutTests/platform/ios/imported/w3c/web-platform-tests/css/css-transforms/text-perspective-001-expected.txt:
* LayoutTests/imported/w3c/web-platform-tests/css/css-transforms/text-perspective-001-expected.txt:

> Rebaseline:
* LayoutTests/compositing/tiling/perspective-on-scroller-tile-coverage-expected.txt:
* LayoutTests/platform/ios/compositing/tiling/perspective-on-scroller-tile-coverage-expected.txt:
* LayoutTests/svg/compositing/svg-poster-circle.html: Scrollbar Placement change (no rendering difference)

Canonical link: https://commits.webkit.org/296652@main
@webkit-commit-queue webkit-commit-queue force-pushed the eng/Account-for-perspective-of-the-scroller-when-determining-a-transformed-child-s-contribution-to-layout-overflow branch from 24fffdd to 7005f16 Compare June 26, 2025 05:14
@webkit-commit-queue
Copy link
Collaborator

Committed 296652@main (7005f16): https://commits.webkit.org/296652@main

Reviewed commits have been landed. Closing PR #47032 and removing active labels.

@webkit-commit-queue webkit-commit-queue merged commit 7005f16 into WebKit:main Jun 26, 2025
@webkit-commit-queue webkit-commit-queue removed the merge-queue Applied to send a pull request to merge-queue label Jun 26, 2025
@Ahmad-S792 Ahmad-S792 deleted the eng/Account-for-perspective-of-the-scroller-when-determining-a-transformed-child-s-contribution-to-layout-overflow branch June 26, 2025 10:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Layout and Rendering For bugs with layout and rendering of Web pages.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants