diff options
Diffstat (limited to 'Master/texmf-dist/source/fonts/gentium-tug/type1/generate-extra-kerns.sh')
-rwxr-xr-x | Master/texmf-dist/source/fonts/gentium-tug/type1/generate-extra-kerns.sh | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/Master/texmf-dist/source/fonts/gentium-tug/type1/generate-extra-kerns.sh b/Master/texmf-dist/source/fonts/gentium-tug/type1/generate-extra-kerns.sh new file mode 100755 index 00000000000..d1806543668 --- /dev/null +++ b/Master/texmf-dist/source/fonts/gentium-tug/type1/generate-extra-kerns.sh @@ -0,0 +1,27 @@ +#!/bin/sh +# This file is part of the Gentium package for TeX. +# It is licensed under the Expat License, see doc//README for details. + +# Generates extra kerning pairs for Greek. +# GentiumBasic has no Greek, so no correction is needed. +# +# If you want to keep the files with extra kerning pairs, +# run just this script. + +TTF_PATH="../../../../fonts/truetype/public/gentium-tug" +AFM_PATH="../../../../fonts/afm/public/gentium-tug" + +for i in GentiumPlus-R.ttf GentiumPlus-I.ttf; do + echo "----------------------------------------------" + echo "* Generating extra kerns for $i" + echo "* Converting font to sfd" + FILE_TTF="$TTF_PATH/$i" + FILE_SFD="$(basename $i .ttf).sfd" + fontforge -lang=ff -c "Open('$FILE_TTF');Save('$FILE_SFD')" + echo "* Calculating the kerns" + greekcorrection.py $(basename $i .ttf).sfd + kerncorrection.py "$AFM_PATH/$(basename $i .ttf).afm" $(basename $i .ttf)-extra.afm + cat $(basename $i .ttf)-Czech.kern >> $(basename $i .ttf)-extra.afm +done + +rm *sfd |