Remove unnecessary TTX compile step

Use .ttx with components as input for emoji_builder.py

Originally the .ttx generated by add_glyphs.py was compiled to
a .ttf file so it could be fed to emoji_builder.py. Now we can
feed it a .ttx file and remove the compile step. This way the
original glyph names are preserved and we can start adding
PNGs for the components.
This commit is contained in:
Roel Nieskens 2019-09-10 13:29:06 +02:00
parent e6d784e3e0
commit f342d17758
2 changed files with 6 additions and 6 deletions

View file

@ -209,11 +209,7 @@ endif
%.ttx: %.ttx.tmpl $(ADD_GLYPHS) $(ALL_COMPRESSED_FILES)
@python $(ADD_GLYPHS) -f "$<" -o "$@" -d "$(COMPRESSED_DIR)" $(ADD_GLYPHS_FLAGS)
%.ttf: %.ttx
@rm -f "$@"
ttx "$<"
$(EMOJI).ttf: $(EMOJI).tmpl.ttf $(EMOJI_BUILDER) $(PUA_ADDER) \
$(EMOJI).ttf: $(EMOJI).tmpl.ttx $(EMOJI_BUILDER) $(PUA_ADDER) \
$(ALL_COMPRESSED_FILES) | check_vs_adder
@python $(EMOJI_BUILDER) $(SMALL_METRICS) -V $< "$@" "$(COMPRESSED_DIR)/emoji_u"
@python $(PUA_ADDER) "$@" "$@-with-pua"

View file

@ -475,6 +475,10 @@ By default they are dropped.
print()
if font_file.endswith(".ttx"):
font = ttx.TTFont()
font.importXML(font_file)
else:
font = ttx.TTFont(font_file)
print("Loaded font '%s'." % font_file)