Commit 09dc74f
Add space and .notdef character to all new fonts by default
Changed files (2)
Diff
@@ -181,12 +181,19 @@ public class Font : GLib.Object { kerning_strings = new KerningStrings (); alternates = new AlternateSets ();+ + add_default_characters (); } ~Font () { font_deleted (); } + public void add_default_characters () {+ add_glyph_collection (get_notdef_character ());+ add_glyph_collection (get_space ());+ }+ public Alternate? get_alternate (string glyph_name, string tag) { Gee.ArrayList<Alternate> alt = alternates.get_alt (tag); @@ -506,7 +513,7 @@ public class Font : GLib.Object { return gc; } - public GlyphCollection get_not_def_character () {+ public GlyphCollection get_notdef_character () { Glyph g; GlyphCollection gc; @@ -900,6 +907,7 @@ public class Font : GLib.Object { if (loaded) { settings.load (get_file_name ()); kerning_strings.load (this);+ add_default_characters (); } return loaded;@@ -144,7 +144,7 @@ public class GlyfTable : OtfTable { bool unassigned; // add notdef character and other special characters first- glyphs.add (font.get_not_def_character ());+ glyphs.add (font.get_notdef_character ()); glyphs.add (font.get_null_character ()); glyphs.add (font.get_nonmarking_return ()); glyphs.add (font.get_space ());