freetype-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[ft-devel] Re: Report a bug.


From: Deron Kazmaier
Subject: [ft-devel] Re: Report a bug.
Date: Sun, 30 Mar 2008 09:07:52 -0600
User-agent: Thunderbird 2.0.0.12 (Macintosh/20080213)

Werner LEMBERG wrote:
The attachment(F10.ttf) is a font that I draw-out from a PDF.

And the FreeType 2.3.5 cannot deal with it correctly. So I had try
the version 2.0.9 and 2.1.10.

I found that the 2.0.9 is right, and the 2.1.10 is wrong.

Please check it whether it is a bug or not.

The font is fine I think[1], but ftview has problems.  Since version
2.1.8, glyph indices are treated as CIDs for CID-keyed CFFs (similar
to pure CID fonts).  However, ftview only looks at the number of
glyphs in the font which is of no use for subsetted CID fonts.  For
this particular font, the first CID value is 3085 while the number of
glyphs is 12...

On the other hand, I'm not aware of a problem with the functions in
FreeType 2.3.5 w.r.t. CID-keyed fonts.  Can you give more details?

BTW, I plan to add a new flag value, FT_FACE_FLAG_CID_KEYED (together
with an FT_IS_CID_KEYED macro), probably together with an
FT_Get_CID_MaxCount() function (as a service in ftcid.h) since the
highest CID value used in a font is not accessible currently.  You can
then do something like this:

  error = FT_Get_CID_MaxCount(face, &max_count)
  if (!error)
    num_glyphs = max_count;

  for (i = 0; i < num_glyphs; i++ )
  {
    error = FT_Load_Glyph(face, i, 0);
    /* skip invalid CIDs */
    if (FT_IS_CID_KEYED(face)
        && error = FT_Err_Invalid_Argument)
      continue;
    ...
  }

Comments, please.


    Werner

Please forgive me ignorance, but why would the normal FT_Get_First_Char/FT_Get_Next_Char not work for this? Perhaps I missed the part in the documentation which states that no glyph index will exceed the num_glpyhs count, but I have always treated glyph indexes as a discontinuous sequence.

Deron





reply via email to

[Prev in Thread] Current Thread [Next in Thread]