freetype-devel
[Top][All Lists]
Advanced

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

Re: ftdump can show the CID registry, ordering, and supplement?


From: Werner LEMBERG
Subject: Re: ftdump can show the CID registry, ordering, and supplement?
Date: Sat, 22 Apr 2023 06:15:42 +0000 (UTC)

> In the [.otf] font that you provided [privately], there are 4
> *normal* charmaps.

Yes, from a user's point of view, this is a normal OpenType font.

> Is it considered a CID font just because those were added later?
> Were CIDs there to begin with?

Yes.  It is possible to completely strip off the SFNT wrapper to get a
'pure' CFF, i.e., the contents of the 'CFF ' table; this is normally
done if you are going to embed a CFF-based OpenType font into a PDF.
Such a pure CFF font can be CID-keyed.

This wrapping leads to a waste of space because glyphs are encoded
twice: first with the SFNT 'cmap' table, then with either SIDs (for
normal CFFs) or CIDs (for CID-keyed fonts).  For this reason, the
'CFF2' SFNT table format was developed to avoid this double mapping,
among other things.

> How is one supposed to use the CIDs in this font if the glyphs are
> indexed sequentially, not by CID?

CID-keyed fonts are *always* indexed by CID, there is no exception
possible due to design, AFAIK.

> What FreeType interface?  There is no interface
> FT_Load_Glyph_by_CID.

Such an interface is not necessary.  For CFFs, the interpretation
whether you are handing SIDs or CIDs can be checked easily.  However,
the mapping data for CIDs are to be provided by a higher level.


    Werner



reply via email to

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