The Birdfont Source Code


All Repositories / birdfont.git / commitdiff – RSS feed

Fix generated italics

These changes was commited to the Birdfont repository Thu, 30 Jun 2016 09:36:23 +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, 30 Jun 2016 09:36:23 +0000]

Updated Files

libbirdfont/OverViewItem.vala
libbirdfont/OverviewTools.vala
libbirdfont/SvgParser.vala
--- a/libbirdfont/OverViewItem.vala +++ b/libbirdfont/OverViewItem.vala @@ -82,6 +82,15 @@ } draw_background (); + } + + public void clear_cache () { + cache = null; + + if (glyphs != null) { + Glyph g = ((!) glyphs).get_current (); + g.overview_thumbnail = null; + } } public void draw_glyph_from_font () {
--- a/libbirdfont/OverviewTools.vala +++ b/libbirdfont/OverviewTools.vala @@ -325,10 +325,13 @@ } foreach (OverViewItem item in o.visible_items) { - item.draw_glyph_from_font (); + item.clear_cache (); + item.draw_glyph_from_font (); } o.undo_items.add (ui); + + MainWindow.get_overview ().update_item_list (); GlyphCanvas.redraw (); }
--- a/libbirdfont/SvgParser.vala +++ b/libbirdfont/SvgParser.vala @@ -336,8 +336,14 @@ foreach (EditPoint ep in path.points) { apply_matrix_on_handle (ep.get_right_handle (), a, b, c, d, e, f); - apply_matrix_on_handle (ep.get_left_handle (), a, b, c, d, e, f); - + + EditPointHandle left = ep.get_left_handle (); + if (left.type == PointType.QUADRATIC || left.type == PointType.LINE_QUADRATIC) { + ep.get_right_handle ().process_connected_handle (); + } else { + apply_matrix_on_handle (left, a, b, c, d, e, f); + } + ep.independent_y = font.top_position - ep.independent_y; ep.independent_x -= glyph.left_limit;