Luke Lau 95470a9ce8
🐛 Remove nested_shadows, and fix double group shadows on text (#13280)
* 🔧 Add a render test for group shadows on nested text

The snapshot records the shadow of a group on the texts and shapes
inside it, as rendered today. Stroked text gets the shadow twice (G, I,
J, L) or partly twice (H, K), while plain text (B to F) gets it once.

The next commit fixes this and updates the snapshot.

AI-assisted-by: claude-opus-5-5

* 🐛 Remove nested_shadows, and fix double group shadows on text

The nested_shadows state is only used by text shapes to draw drop
shadows that it inherits from its parents. There's a bug where only
groups pushed onto the stack but both groups and frames popped it.

But when trying to fix this I noticed that
`render_drop_shadow_child_silhouettes` will already render the text
shapes shadow in the parent. So compared to the SVG renderer we were
applying the shadows twice.

We can just remove the stack and let the parent render the shadow
once, which brings text in line with other shapes.  In the render
test, stroked text now gets the shadow once (G to L).

There's some other divergences from the SVG renderer in
`render_drop_shadow_child_silhouettes` to do with non-flattened
containers, which text shapes will now be exposed to. I hope to post a
PR after this to address these.

AI-assisted-by: claude-opus-5-5
2026-11-25 10:36:05 +01:00
..
2026-07-16 08:33:36 +02:00
2026-02-17 08:19:37 +01:00
2025-06-09 17:46:18 +02:00
2025-10-02 16:40:20 +02:00
2025-06-24 12:36:12 +02:00
2026-02-20 13:37:27 +01:00
2026-02-20 13:37:27 +01:00