Commit 99362e5
add points even if point type is none
Changed files (4)
modifiedbavala.pymodifiedlibbirdfont/Font.valamodifiedlibbirdfont/Path.valamodifiedlibbirdfont/Svg.vala
Diff
@@ -40,8 +40,6 @@ class Vala(object): self.obj = [f.replace('.c', '.o') for f in self.cc] self.obj += [join(build, f.replace('.vala', '.o')) for f in self.vala] - print (self.cc)- if library: self.header = join(build, library) + '.h' self.vapi = join(build, library) + '.vapi'@@ -1396,7 +1396,7 @@ public class Font : GLib.Object { bool r; if (unlikely (unicode.index_of ("U+") != 0)) {- warning (@"All unicode values must begin with U+ ($unicode");+ warning (@"All unicode values must begin with U+ ($unicode)"); return '\0'; } @@ -208,7 +208,7 @@ public class Path { cr.set_source_rgba (line_color_r, line_color_g, line_color_b, line_color_a); cr.set_line_width (stroke_width / g.view_zoom); - cr.line_to (xa, ya); // this point makes sense only if it is the first or last position, the other points are meaning less don't export them+ cr.line_to (xa, ya); // this point makes sense only if it is the first or last position, the other points are meaningless don't export them if (en.get_right_handle ().type == PointType.QUADRATIC) { cr.curve_to ((xa + 2 * xb) / 3, (ya + 2 * yb) / 3, (xd + 2 * xb) / 3, (yd + 2 * yb) / 3, xd, yd); @@ -80,11 +80,9 @@ class Svg { private static void add_abs_next (EditPoint start, EditPoint end, StringBuilder svg, Glyph g, bool do_glyph) { if (end.get_left_handle ().type == PointType.QUADRATIC) { add_quadratic_abs_path (end, start, svg, g, do_glyph);- }- - if (start.right_handle.type == PointType.LINE && end.left_handle.type == PointType.LINE) {+ } else if (start.right_handle.type == PointType.LINE && end.left_handle.type == PointType.LINE) { add_abs_line_to (end, start, svg, g, do_glyph);- } else if (end.get_left_handle ().type == PointType.CURVE) {+ } else { add_cubic_abs_path (end, start, svg, g, do_glyph); } }