The Birdfont Source Code


All Repositories / birdfont.git / commitdiff – RSS feed

Fix points on points removal in SVG import

These changes was commited to the Birdfont repository Thu, 21 Jan 2016 20:44:07 +0000.

Contributing

Send patches or pull requests to johan.mattsson.m@gmail.com.
Clone this repository: git clone https://github.com/johanmattssonm/birdfont.git
[Thu, 21 Jan 2016 20:44:07 +0000]

Updated Files

libbirdfont/Path.vala
libbirdfont/SvgParser.vala
--- a/libbirdfont/Path.vala +++ b/libbirdfont/Path.vala @@ -1,5 +1,5 @@ /* - Copyright (C) 2012 2013 2014 2015 Johan Mattsson + Copyright (C) 2012 - 2016 Johan Mattsson This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as @@ -2313,10 +2313,11 @@ if (points.size == 0) { return; } - + for (int i = 0; i < points.size + 1; i++) { EditPoint ep = points.get (i % points.size); - if (ep.get_right_handle ().length < t3 + if ((ep.flags & EditPoint.STROKE_OFFSET) > 0 + && ep.get_right_handle ().length < t3 && ep.get_left_handle ().length < t3 && !is_endpoint (ep) && (ep.flags & EditPoint.CURVE_KEEP) == 0
--- a/libbirdfont/SvgParser.vala +++ b/libbirdfont/SvgParser.vala @@ -1,5 +1,5 @@ /* - Copyright (C) 2012 2013 2014 2015 Johan Mattsson + Copyright (C) 2012 - 2016 Johan Mattsson This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as