From d5bf831f6083bd2378f000df1797eb27e24f03b5 Mon Sep 17 00:00:00 2001 From: Seth Hillbrand Date: Thu, 20 Apr 2023 12:29:51 -0700 Subject: [PATCH] Ensure that even open paths with fills are filled SVG paths that are "open" can still have a fill internally, so avoid dropping fills for these non-standard polygons Fixes https://gitlab.com/kicad/code/kicad/issues/14518 (cherry picked from commit b56db300195daff1a726dfa0019200febc0e6e9f) --- pcbnew/import_gfx/svg_import_plugin.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pcbnew/import_gfx/svg_import_plugin.cpp b/pcbnew/import_gfx/svg_import_plugin.cpp index 310191875e..23c31241ad 100644 --- a/pcbnew/import_gfx/svg_import_plugin.cpp +++ b/pcbnew/import_gfx/svg_import_plugin.cpp @@ -97,7 +97,7 @@ bool SVG_IMPORT_PLUGIN::Import() for( NSVGpath* path = shape->paths; path != nullptr; path = path->next ) { - bool closed = path->closed || rule == GRAPHICS_IMPORTER::PF_EVEN_ODD; + bool closed = path->closed || filled || rule == GRAPHICS_IMPORTER::PF_EVEN_ODD; DrawPath( path->pts, path->npts, closed, filled, lineWidth ); }