diff options
author | jaseg <git@jaseg.de> | 2021-02-11 00:18:54 +0100 |
---|---|---|
committer | jaseg <git@jaseg.de> | 2021-02-11 00:18:54 +0100 |
commit | 3fc628beecdfb07feb25c6501070d73090e68f3c (patch) | |
tree | 9bdb122001f0db80964af2c829a63a4726d94da4 | |
parent | e8d7ca1d6c80de91294d8e0ad7a611b774b880dc (diff) | |
download | gerbolyze-3fc628beecdfb07feb25c6501070d73090e68f3c.tar.gz gerbolyze-3fc628beecdfb07feb25c6501070d73090e68f3c.tar.bz2 gerbolyze-3fc628beecdfb07feb25c6501070d73090e68f3c.zip |
Fix handling of stroke width under transformations
-rw-r--r-- | svg-flatten/src/svg_doc.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/svg-flatten/src/svg_doc.cpp b/svg-flatten/src/svg_doc.cpp index e9c9dfc..0ae9b68 100644 --- a/svg-flatten/src/svg_doc.cpp +++ b/svg-flatten/src/svg_doc.cpp @@ -231,10 +231,15 @@ void gerbolyze::SVGDocument::export_svg_path(const RenderSettings &rset, const p } /* Load path from SVG path data and transform into document units. */ - PolyTree ptree; cairo_save(cr); apply_cairo_transform_from_svg(cr, node.attribute("transform").value()); + + PolyTree ptree; load_svg_path(cr, node, ptree); + + double _y = 0; + cairo_user_to_device_distance(cr, &stroke_width, &_y); + cairo_restore (cr); Paths open_paths, closed_paths; |