[XeTeX] TemporaLGCUni-Italic: Parsing CFF DICT failed

Alexey Kryukov anagnost at yandex.ru
Fri Mar 7 21:04:11 CET 2008


On Tuesday 04 March 2008, Jonathan Kew wrote:
>
> Looking in the source code, it seems that error code -3 is
> CFF_ERROR_STACK_UNDERFLOW. But why that's happening -- whether it's a
> genuine error in the font, or a bug in xdvipdfmx -- I don't know
> without further investigation. I'm not very familiar with CFF font
> structures, so tracing this will be fairly tedious.... :(

OK, I think I have figured out what's wrong. The italic version
of the font has an empty StemSnapV array in its PS Private data,
and this stumbles xdvipdfmx which assumes every operator should
be preceded by some operands. Particularly I think this is a bug
in xdvipdfmx: although the specification doesn't say explicitly
that dictionary keys with no value are allowed, other tools
(e. g. TTX or FontForge) seem to have no problems with this situation.

So my opinion is that the CFF_ERROR_STACK_UNDERFLOW error should
not be triggered at the line 305 of cff_dict.c, if stack_top is 0.

-- 
Regards,
Alexej Kryukov <anagnost at yandex dot ru>

Moscow State University
Historical Faculty


More information about the XeTeX mailing list