Page MenuHome

Curve Tools: Ensure nested paths in exported SVG look as expected
AcceptedPublic

Authored by Johan Althoff (teetow) on Oct 10 2022, 6:58 PM.

Details

Summary

When editing curves in Blender, curves that are completely enclosed by another curve are treated as holes. Subsequent curves within a hole will be solid, and so on.

This behavior has an equivalent in SVG: it's the fill-rule="evenodd". This patch applies the fill-rule to the outermost <svg> element, so that the exported SVG:s look as expected.

In Blender:

Before patch:

After patch:

Diff Detail

Event Timeline

Johan Althoff (teetow) requested review of this revision.Oct 10 2022, 6:58 PM
Johan Althoff (teetow) created this revision.
Johan Althoff (teetow) retitled this revision from Curve Tools: Ensure nested paths in exported SVG are filled with the same fill-rule to Curve Tools: Ensure nested paths in exported SVG look as expected.
This revision is now accepted and ready to land.Oct 10 2022, 7:26 PM

@Vladimir Spivak (cwolf3d) Thanks for the review! Would you be OK with committing this as well?