freetype-devel
[Top][All Lists]
Advanced

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

[Devel] FT_CONFIG_OPTION_USE_CMAPS?


From: Wenlin Institute
Subject: [Devel] FT_CONFIG_OPTION_USE_CMAPS?
Date: Mon, 29 Apr 2002 18:16:03 -0700

Hi,

With FreeType 2.0.6, calling FT_New_Face() with any .ttf font would succeed, and magically almost always resulted in face->charmap->encoding == ft_encoding_unicode, even for an ASCII/Latin1 font.

Now with 2.1.0, although FT_New_Face() still returns FT_Err_Ok, it gives face->charmap == NULL, even for Unicode fonts, and FT_Select_Charmap(face, ft_encoding_unicode) returns FT_Err_Invalid_Argument. This is on MacOS X, by the way, but does not appear to involve ftmac.c.

The old (2.0.6) behavior can be restored by #undef FT_CONFIG_OPTION_USE_CMAPS in ftoption.h, where there is a mysterious comment, "Define this if you want generic cmap support."

Presumably FT_CONFIG_OPTION_USE_CMAPS is an improvement, or it wouldn't exist, but what is the improvement and how does one take advantage of it?

If FT_CONFIG_OPTION_USE_CMAPS is defined, is it still possible to determine whether a font is Unicode-compatible, in the sense that FT_Get_Char_Index() will interpret the charcode as Unicode, and this won't result in a random glyph?

Tom Bishop
--

Wenlin Institute, Inc.        Software for Learning Chinese
E-mail: address@hidden     Web: http://www.wenlin.com
Telephone: 1-877-4-WENLIN (1-877-493-6546)



reply via email to

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