Home > Archive > PostScript > January 2007 > CFF CID-keyed font parsing.
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
CFF CID-keyed font parsing.
|
|
| Xeranic 2007-01-11, 10:04 pm |
| Hi, all.
I have correct parsing and render the CFF Type2 CharString which locate
in a OpenType (PS) font. When the CFF is a CID-keyed font, which have a
FDArray index data, the callsubr command is failed.
But the callgsubr command is fine so I belive the calc of subr index is
correct. Is there any special calcuation of subr index when CFF font is
CID-keyed.
I use fonts locate at Acrobat's install dir. When parsing the
AdobeMingStd-Light.otf and AdobeSongStd-Light.otf font, my code works
fine. But for others not!
| |
| Ken Sharp 2007-01-12, 4:11 am |
| In article <1168570646.019516.148320@s34g2000cwa.googlegroups.com>,
Xeranic@gmail.com says...
> I have correct parsing and render the CFF Type2 CharString which locate
> in a OpenType (PS) font. When the CFF is a CID-keyed font, which have a
> FDArray index data, the callsubr command is failed.
> But the callgsubr command is fine so I belive the calc of subr index is
> correct. Is there any special calcuation of subr index when CFF font is
> CID-keyed.
Local and global subroutines are stored separately. If a subroutine is
global there is no reason to store a local copy, since it is accesible
to all fonts.
The local and global subroutie indices are quite different, and the same
index *will* refer to different subroutines when used with callgsubr as
opposed to callsubr. So the fact that callgsubr works doesn't tell you
anything about the validity of that index for use with a local
subroutine (callsubr).
FWIW there is no special calculation for subroutine indices in a CID
keyed font that I'm aware of, other than the difference between local
and global subroutines.
> I use fonts locate at Acrobat's install dir. When parsing the
> AdobeMingStd-Light.otf and AdobeSongStd-Light.otf font, my code works
> fine. But for others not!
Then I'm afraid this points to a bug, but I can't offer any advice
without more information on the problem.
Ken
| |
| Xeranic 2007-01-14, 10:05 pm |
|
On Jan 12, 4:30 pm, Ken Sharp <k...@spamcop.net> wrote:
> In article <1168570646.019516.148...@s34g2000cwa.googlegroups.com>,
> Xera...@gmail.com says...
>
> global there is no reason to store a local copy, since it is accesible
> to all fonts.
>
> The local and global subroutie indices are quite different, and the same
> index *will* refer to different subroutines when used with callgsubr as
> opposed to callsubr. So the fact that callgsubr works doesn't tell you
> anything about the validity of that index for use with a local
> subroutine (callsubr).
>
> FWIW there is no special calculation for subroutine indices in a CID
> keyed font that I'm aware of, other than the difference between local
> and global subroutines.
>
> without more information on the problem.
>
> Ken
Hi, Ken
Thanks, As you said, it's a bug. I just fix it. :)
|
|
|
|
|