[NTG-pdftex] [ pdftex-Bugs-509 ] invalid pdf created if font name contains space
noreply at sarovar.org
noreply at sarovar.org
Thu Apr 13 22:54:27 CEST 2006
Bugs item #509, was opened at 2006-04-13 20:37
You can respond by visiting:
http://sarovar.org/tracker/?func=detail&atid=493&aid=509&group_id=106
Category: Fonts
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: Tom Bishop (tbishop)
Assigned to: Hartmut Henkel (hhenkel)
Summary: invalid pdf created if font name contains space
Initial Comment:
pdftex 3.141592-1.30.4-2.2 runs the following code without
complaining:
\pdfmapline{+mssong4e <mssong.ttf <mssong4e.enc}
\font\testfont=mssong4e at 20pt
\testfont\char"00
\bye
-- but the resulting pdf file can't be opened by Adobe Reader or
GhostScript. GhostScript reports "Unknown operator: Song".
The pdf file includes "/BaseFont /FEVAQU+MS Song". Evidently, the
problem is the space in "MS Song", because if I use a hex editor to
replace the space with an underscore, then the pdf becomes OK.
The same font worked fine with earlier pdftex versions. It's a Chinese
Unicode TrueType font, from Microsoft.
I haven't tried installing pdftex 1.30.6; is it possible that would fix the
problem? I just re-installed TeX using i-Installer for Mac OS X; it still
uses pdftex 1.30.4.
Here is the output of pdftex when running the test file:
This is pdfeTeX, Version 3.141592-1.30.4-2.2 (Web2C 7.5.5)
entering extended mode
(./test3.tex [1{/Users/tbishop/Library/texmf/fonts/map/pdftex/
updmap/pdftex.map
}] )</usr/local/teTeX/share/texmf.tetex/fonts/type1/bluesky/cm/
cmr10.pfb>{/usr/
local/teTeX/share/texmf.local/fonts/enc/pdftex/enc/mssong4e.enc}
</usr/local/teT
eX/share/texmf.local/fonts/truetype/mssong.ttf>
Output written on test3.pdf (1 page, 5067 bytes).
Transcript written on test3.log.
Thanks in advance for any help!
Best wishes,
Tom Bishop (wenlin at wenlin.com)
----------------------------------------------------------------------
>Comment By: Hartmut Henkel (hhenkel)
Date: 2006-04-13 22:54
Message:
Logged In: YES
user_id=929
ah, after the PDF reference 5. ed. page 388 in case there
would be no PostScript name entry we could be cruesome and
strip the blank. But there is a wrong PostScript name in the
font. So maybe one could flag a warning (or not?) and just
strip the blank? (which would be easy)
Regards, Hartmut
----------------------------------------------------------------------
Comment By: Hartmut Henkel (hhenkel)
Date: 2006-04-13 22:39
Message:
Logged In: YES
user_id=929
This mssong.ttf version seems to be buggy. Here is a
diagnostic printout from function ttf_read_name() in
writettf.c; these are all available entries from the "Naming
Table":
i=0 platform_id=1 encoding_id=0 name_id=0 name <(c)
Copyright ZHUHAI Stone Computerized typesetting system R&D
LTD., 1995-1996>
i=1 platform_id=1 encoding_id=0 name_id=1 name <MS Song>
i=2 platform_id=1 encoding_id=0 name_id=2 name <Regular>
i=3 platform_id=1 encoding_id=0 name_id=3 name <Microsoft:MS
Song:1996>
i=4 platform_id=1 encoding_id=0 name_id=4 name <MS Song>
i=5 platform_id=1 encoding_id=0 name_id=5 name <Version 1.00>
i=6 platform_id=1 encoding_id=0 name_id=6 name <MS Song>
---> ttf_read_name <MS Song>
There is no usable PostScript name in: The TTF standard
tells that under name_id=6 there should be the Postscript
font, but here it is "MS Song" with a blank.
As long as the font does not contain a valid PostScript
name, i have no idea how to tweak this correctly...
Other clues anybody?
Regards, Hartmut
----------------------------------------------------------------------
You can respond by visiting:
http://sarovar.org/tracker/?func=detail&atid=493&aid=509&group_id=106
More information about the ntg-pdftex
mailing list