LayoutNG + CompositeAfterPaint cause trouble for background-attachment:local |
|||
Issue descriptionRunning with --enable-blink-features=LayoutNG,CompositeAfterPaint causes virtual/composite-after-paint/paint/background/scrolling-background-with-negative-z-child.html to fail. Attaching a simplified test case. It almost looks like there's some code somewhere that doesn't understand that an out-of-flow object may actually cause scrollable overflow in an parent. But, then again, the test passes without LayoutNG, so maybe it's NG that forgets to write back some critical information back to legacy layout. If we modify my attached test to contain *any* in-flow content at all (even an empty zero-height DIV next to the abspos will do the trick), the test passes.
,
Dec 19
There are two issues that cause this test failure: 1) NGBoxFragmentPainter::Paint differs from BlockPainter::Paint. In BlockPainter::Paint, with CompositeAfterPaint, SetIsPaintingScrollingBackground is called before painting the background. We'll need to implement LayoutBlock::GetBackgroundPaintLocation for LayoutNG. 2) NGBoxFragmentPainter::IsPaintingScrollingBackground differs from BoxModelObjectPainter::IsPaintingScrollingBackground. In BoxModelObjectPainter::IsPaintingScrollingBackground, there is a CompositeAfterPaint conditional that checks PaintInfo::IsPaintingScrollingBackground. There is a third bug that is related but does not cause this test failure: NGBoxFragmentPainter::PaintObject has a commented out block of code for painting the scroll hit test display item, and this prevents composited scrolling from working (e.g., mouse-wheel scrolling). The scroll hit test display item needs some cleanup so I recommend not worrying about that for now.
,
Dec 19
|
|||
►
Sign in to add a comment |
|||
Comment 1 by bugdroid1@chromium.org
, Dec 19