> I need it for filling out a font descriptor in a PDF (it's the StemV > value of the dictionary). By requiring that my CFF font files > contain exactly one font, they can be embedded directly in the PDF > (the PDF spec has this requirement, p 468 in the 1.7 version).
OK. >> Yes, sub-fonts are ignored. However, they aren't needed since only >> the information of the top-level font info dictionary is returned. > > Okay, I must have misread the CFF spec then. I thought the font info > dict was per font as well (and eg UnderlineThickness sounds parallel > to StdVW in this regard, doesn't it?). The structure of a CIDFont is as follows: Top DICT: version Notice Copyright FontName ... FDArray FDArray: Font DICT 0 Font DICT 1 ... Font DICT 0: Font Dict data Private Dict data Font DICT 1: Font Dict data Private Dict data ... For example, the `FontName' entry is present in the Top DICT and in all Font DICT entries indexed in the FDArray. > The implementation I suggest would then only be as bad as the > current implementation of FT_Get_PS_Font_Info. To do better, the > api needs to have the sub-font index as a parameter. Well, FT_Get_PS_Font_Info isn't bad at all, since it correctly returns the Top DICT data of a CIDFont which represents the `public' dictionary data. However, the FDArray data is *completely internal* to FreeType and not publicly visible. It is *not* possible to directly access a CIDFont's subfont. In other words, your suggestion of using a subfont index doesn't work. I'll ask someone from Adobe which value is used for StemV if the particular font is a CIDFont. Werner _______________________________________________ Freetype-devel mailing list Freetype-devel@nongnu.org https://lists.nongnu.org/mailman/listinfo/freetype-devel