[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[ft-devel] ascender = descender = linegap = 0
From: |
Werner LEMBERG |
Subject: |
[ft-devel] ascender = descender = linegap = 0 |
Date: |
Mon, 22 Jun 2009 17:14:19 +0200 (CEST) |
I have an old font called `Agenda-MediumItalic.ttf' (probably from
1993) which has very strange `hhea' entries:
<ascent value="0"/>
<descent value="0"/>
<lineGap value="0"/>
Additionally, it has an `OS/2' table, versionĀ 0 -- something which
Windows doesn't accept IIRC -- so it seems that this font is from/for
the Mac. On the other hand, it has valid entries in `OS/2':
<sTypoAscender value="712"/>
<sTypoDescender value="-231"/>
<sTypoLineGap value="71"/>
<usWinAscent value="930"/>
<usWinDescent value="238"/>
Currently, FreeType only uses the `hhea' table entries to compute the
`ascender', `descender', and `height' fields in `FT_Face' which means
that you get unusable values for this font. What do you think about
providing a fall-back, say:
if ascent == 0 && descent == 0
use sTypoAscender and sTypoDescender
endif
if lineGap == 0
use TypoLineGap
endif
Do you have a better idea? Shall I take care of this situation at
all?
Werner
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [ft-devel] ascender = descender = linegap = 0,
Werner LEMBERG <=