SVG import: skip shapes that are not stroked and not filled.

This commit is contained in:
Alex Shvartzkop 2023-09-08 14:45:32 +03:00
parent ab1a6651a9
commit bc846f5fca
1 changed files with 3 additions and 0 deletions

View File

@ -107,6 +107,9 @@ bool SVG_IMPORT_PLUGIN::Import()
if( !( shape->flags & NSVG_FLAGS_VISIBLE ) )
continue;
if( shape->stroke.type == NSVG_PAINT_NONE && shape->fill.type == NSVG_PAINT_NONE )
continue;
double lineWidth = shape->stroke.type != NSVG_PAINT_NONE ? shape->strokeWidth : -1;
bool filled = shape->fill.type != NSVG_PAINT_NONE && alpha( shape->fill.color ) > 0;