From 42e890f4a47adde2b91eda348fac01b73de516ee Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jindra=20Pet=C5=99=C3=ADk?= Date: Sat, 21 Mar 2026 20:31:54 +0100 Subject: [PATCH] fix: svg shape export - use proper winding --- .../decompiler/flash/exporters/shape/SVGShapeExporter.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/exporters/shape/SVGShapeExporter.java b/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/exporters/shape/SVGShapeExporter.java index c6327bd11..0412d323c 100644 --- a/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/exporters/shape/SVGShapeExporter.java +++ b/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/exporters/shape/SVGShapeExporter.java @@ -152,7 +152,7 @@ public class SVGShapeExporter extends DefaultSVGShapeExporter { gradient.setAttribute("id", gradientId); path.setAttribute("stroke", "none"); path.setAttribute("fill", "url(#" + gradientId + ")"); - path.setAttribute("fill-rule", "evenodd"); + path.setAttribute("fill-rule", windingRule == ShapeTag.WIND_NONZERO ? "nonzero" : "evenodd"); exporter.addToDefs(gradient); } @@ -226,6 +226,7 @@ public class SVGShapeExporter extends DefaultSVGShapeExporter { finalizePath(); String patternId = getPattern(bitmapId, matrix, colorTransform, smooth); path.setAttribute("ffdec:fill-bitmapId", "" + bitmapId); + path.setAttribute("fill-rule", windingRule == ShapeTag.WIND_NONZERO ? "nonzero" : "evenodd"); if (patternId != null) { path.setAttribute("style", "fill:url(#" + patternId + ")"); return;