[tlbuild] ttf2pk versus ttf2pk2
Hin-Tak Leung
htl10 at users.sourceforge.net
Wed Jul 31 20:21:35 CEST 2013
Here is the subset relevant to texlive of the (still growing) list of issues
while revising cjk/doc/pdfhowto/HOWTO.txt I wrote 10 years ago:
- segmentation fault with 10 fonts
- tfm indeterminism with every font
- intermittent floating point exception with every ttc's.
- post version 0 (of two rather old ttf's) not accepted by pdftex/dvipdfmx
- bad/non-working interaction between dvipdfmx and the lscape/pdflscape packages
- ttf2tfm generates invalid tfm's. (7 invalid CHARHT, 2 invalid CHARIC, and
1 invalid CHARDP).
- ttf2tfm generates negative CHARWD's for a font which should have +ve ones.
- dvipdfmx and pdftex processes negative CHARWD's differently.
(negative CHARWD's are not invalid per se).
Here are the screenshots for the last item:
http://www.ghostscript.com/~hintak/tmp/dvipdfmx-retro.png
http://www.ghostscript.com/~hintak/tmp/pdftex-retro.png
After fixing the indeterminism and the floating point exception, the
segmentation fault also seems to disappeared (or it may come back with a
different compilation...). Look at the result afterwards compared to the
10-year-old tfm's (about 14,000 of them; the current set is 21000+),
about 2/3 of them are the same.
about 20% of them have a "progression" - it looks like 10 years ago
ttf2tfm always generates half-width for font dimensions, even for proportional
fonts; this is no longer the case.
The rest (about 10%) is actually indeterminism in the 10-year-old versions.
There also seems to be another "progression" - new subfont #00 and #56 and #57
where there were none. (a few dozen of these).
I offered to spend time fixing these issues. It was rejected. I don't
particularly want to spend time doing that anyway. Just as well.
I don't think it is appropriate for somebody who does not use or understand
ttf2pk/ttf2tfm for their intended purposes (adding new fonts to TeX) to do a
re-write.
Claiming the new version does the "same" as the old, when the old is
indeterministic, seems wrong, and also quite dishonest.
attached is the patch to fix the post-table issue with dvipdfmx. (same patch
should apply to xdvipdfmx as well). also inlined below.
--- texlive-source/texk/dvipdfmx/src/tt_post.c.orig 2013-01-10
14:06:19.000000000 +0000
+++ texlive-source/texk/dvipdfmx/src/tt_post.c 2013-07-31 18:43:19.658344495 +0100
@@ -148,15 +148,13 @@
tt_release_post_table(post);
post = NULL;
}
- } else if (post->Version == 0x00030000UL) {
+ } else {
+ if (post->Version != 0x00030000UL)
+ WARN("Unknown 'post' version: %08X, treat as v3", post->Version);
post->numberOfGlyphs = 0; /* wrong */
post->glyphNamePtr = NULL;
post->count = 0;
post->names = NULL;
- } else {
- WARN("Unknown 'post' version: %08X", post->Version);
- tt_release_post_table(post);
- post = NULL;
}
return post;
-------------- next part --------------
A non-text attachment was scrubbed...
Name: dvipdfmx-post-table.diff
Type: text/x-patch
Size: 719 bytes
Desc: not available
URL: <http://tug.org/pipermail/tlbuild/attachments/20130731/f20ac510/attachment.bin>
More information about the tlbuild
mailing list