1
0
Fork 0
mirror of https://github.com/LadybirdBrowser/ladybird.git synced 2025-06-10 18:10:56 +09:00

LibWeb: Preserve paint state when painting stacking contexts indirectly

For layers that require indirect painting (due to opacity, transform,
etc.) we create a nested PaintContext. Until now, that PaintContext
was created fresh without transferring all the state from the parent
PaintContext.
This commit is contained in:
Andreas Kling 2022-03-26 12:33:34 +01:00
parent 2a8c6361aa
commit 54c3053bc3
Notes: sideshowbarker 2024-07-17 16:44:48 +09:00
2 changed files with 11 additions and 1 deletions

View file

@ -262,7 +262,7 @@ void StackingContext::paint(PaintContext& context) const
return;
auto bitmap = bitmap_or_error.release_value_but_fixme_should_propagate_errors();
Gfx::Painter painter(bitmap);
PaintContext paint_context(painter, context.palette(), context.scroll_offset());
auto paint_context = context.clone();
paint_internal(paint_context);
auto transform_origin = this->transform_origin();