potential fix for #9

This commit is contained in:
sayyadirfanali
2025-11-10 00:14:32 +05:30
parent f48cc5ec42
commit 4839790002
2 changed files with 27 additions and 0 deletions

BIN
Myna.otf

Binary file not shown.

27
vert_compact.py Normal file
View File

@@ -0,0 +1,27 @@
import fontforge
font = fontforge.open("./Myna.sfd")
ascent = font.ascent
descent = font.descent
RATIO = 0.9
# general
font.ascent = int(font.ascent * RATIO)
font.descent = int(font.descent * RATIO)
# hhea
font.hhea_ascent = int(font.hhea_ascent * RATIO)
font.hhea_descent = int(font.hhea_descent * RATIO)
# OS/2 typo
font.os2_typoascent = font.hhea_ascent
font.os2_typodescent = font.hhea_descent
# OS/2 win
font.os2_winascent = ascent # can increase or decrease this if clipped
font.os2_windescent = descent
font.save("Myna.sfd")
font.close()