fune/testing/web-platform/tests/css/css-overflow/overflow-recalc-001.html
Xianzhu Wang fa50a6caed Bug 1825903 [wpt PR 39321] - [CompositeScrollAfterPaint] Consider composited scrolls in CanUpcastWith, a=testonly
Automatic update from web-platform-tests
[CompositeScrollAfterPaint] Consider composited scrolls in CanUpcastWith

In CompositeScrollAfterPaint, the compositing status of a transform
node not only from HasDirectlyCompositedReasons(), but also
composited scroll status determined by PaintArtifactCompositor. This
requires PropertyTreeState::CanUpcastWith also check composited
scroll status when checking if two transform nodes are within the
same compositing boundary.

Also PaintArtifactCompositor needs to handle a case where a scroll
translation is used before the ScrollHitTest chunk. This happens
for negative z-order scrolling contents in a non-stacking-context
scroller. In the case we always composite the scroller to prefer
performance because it's likely there are overlapping interlacing
scrolling and non-scrolling contents. This can also simplify code
because otherwise we would need to find the ScrollHitTest and
compute composited scroll status.

Bug: 1414885
Change-Id: I03411a883dde11e692432da25b87fb49afd7be74
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4389490
Commit-Queue: Xianzhu Wang <wangxianzhu@chromium.org>
Reviewed-by: Philip Rogers <pdr@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1125675}

--

wpt-commits: 26c0b8da74a164c22279b2570ff28821db757a8c
wpt-pr: 39321
2023-04-14 11:15:28 +00:00

53 lines
1.4 KiB
HTML

<!DOCTYPE html>
<html class="reftest-wait">
<meta charset="utf-8">
<title>CSS Overflow: Overflow recalc after font-size change</title>
<link rel="author" title="Manuel Rego Casasnovas" href="mailto:rego@igalia.com">
<link rel="help" href="https://drafts.csswg.org/css-overflow/">
<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=1036644">
<link rel="match" href="reference/overflow-recalc-001-ref.html">
<meta name="fuzzy" content="maxDifference=0-1;totalPixels=0-5">
<meta name="assert" content="Checks that overflow of an inline element is properly recomputed after changes on the descendants.">
<script src="/common/reftest-wait.js"></script>
<link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
<style>
#scroller {
height: 200px;
overflow: scroll;
position: relative;
}
#wrapper {
margin-top: 100px;
width: 200px;
height: 200px;
overflow: hidden;
font-family: Ahem;
line-height: 1;
color: green;
}
#red {
background: red;
width: 200px;
height: 200px;
position: absolute;
top: 100px;
z-index: -1;
}
</style>
<p>Test passes if there is <strong>no red</strong>.</p>
<div id="scroller">
<div id="wrapper">
<span id="inlineouter">
<span id="inlineinner">X</span>
</span>
</div>
<div id="red"></div>
</div>
<script>
requestAnimationFrame(() => requestAnimationFrame(() => {
inlineinner.style.fontSize = "200px";
takeScreenshot();
}));
</script>
</html>