[FIX] TTF fix for Bitstream Vera Fonts
tblanchard at mac.com
tblanchard at mac.com
Tue Jun 24 15:09:34 UTC 2003
The Vera fonts have subfamily names like 'Roman' or 'Oblique' which
freaks out TTCFont.
In fact, the base font seems to have a subfamily name 'Roman' but the
TTCFont assumes the base font subfamily name is 'Regular'.
So, what happens is the first font loads in OK because no analysis is
done on the subfamily name. The second font causes a reorganization of
the family name cluster and you get all kinds of assumptions being
broken by unexpected subfamily names. So you can never load in a
second Vera font.
This changeset adds a synonyms dictionary to TTCFont that maps the Vera
names to the appropriate indexes. It allows you to load all the Vera
fonts at once (and they look pretty nice). I've left a halt in the
method that does the lookups - if you ever try to load a font that has
a wacky subfamily name, please update the dictionary and post your fix.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: VeraTTFCompatibility.1.cs
Type: application/octet-stream
Size: 1346 bytes
Desc: not available
Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20030624/5d5f0d98/VeraTTFCompatibility.1.obj
-------------- next part --------------
-Todd Blanchard
More information about the Squeak-dev
mailing list
|