From 8d256841ca7462fd596329abf6f71bafb56fd621 Mon Sep 17 00:00:00 2001 From: Dominik Schloesser Date: Sun, 26 Mar 2017 09:22:34 +0200 Subject: [PATCH] Current fonttools (3.9.1) generate subset-file called font.subset.ttf instead of older font.ttf.subset --- test/shaping/record-test.sh | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/test/shaping/record-test.sh b/test/shaping/record-test.sh index b2a74f7..cf17c54 100755 --- a/test/shaping/record-test.sh +++ b/test/shaping/record-test.sh @@ -48,20 +48,20 @@ pyftsubset \ --no-hinting \ "$dir/font.ttf" \ --text="$text" -if ! test -s "$dir/font.ttf.subset"; then - echo "Subsetter didn't produce nonempty subset font in $dir/font.ttf.subset" >&2 +if ! test -s "$dir/font.subset.ttf"; then + echo "Subsetter didn't produce nonempty subset font in $dir/font.subset.ttf" >&2 exit 2 fi # Verify that subset font produces same glyphs! -glyphs_subset=`echo "$text" | $hb_shape $options "$dir/font.ttf.subset"` +glyphs_subset=`echo "$text" | $hb_shape $options "$dir/font.subset.ttf"` if ! test "x$glyphs" = "x$glyphs_subset"; then echo "Subset font produced different glyphs!" >&2 echo "Perhaps font doesn't have glyph names; checking visually..." >&2 hb_view=${hb_shape/shape/view} echo "$text" | $hb_view $options "$dir/font.ttf" --output-format=png --output-file="$dir/orig.png" - echo "$text" | $hb_view $options "$dir/font.ttf.subset" --output-format=png --output-file="$dir/subset.png" + echo "$text" | $hb_view $options "$dir/font.subset.ttf" --output-format=png --output-file="$dir/subset.png" if ! cmp "$dir/orig.png" "$dir/subset.png"; then echo "Images differ. Please inspect $dir/*.png." >&2 echo "$glyphs" @@ -74,9 +74,9 @@ if ! test "x$glyphs" = "x$glyphs_subset"; then glyphs=$glyphs_subset fi -sha1sum=`sha1sum "$dir/font.ttf.subset" | cut -d' ' -f1` +sha1sum=`sha1sum "$dir/font.subset.ttf" | cut -d' ' -f1` subset="fonts/sha1sum/$sha1sum.ttf" -mv "$dir/font.ttf.subset" "$subset" +mv "$dir/font.subset.ttf" "$subset" # There ought to be an easier way to do this, but it escapes me... unicodes_file=`mktemp` -- 2.7.4