freetype-devel
[Top][All Lists]
Advanced

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

[Devel] Selecting the Unicode charmap by default


From: Graham Asher
Subject: [Devel] Selecting the Unicode charmap by default
Date: Fri, 24 May 2002 14:55:40 +0100

I thought - perhaps wrongly - that FreeType drivers were supposed to select
a Unicode charmap by default after a face is opened. But there seems to be
an inconsistency here. The TrueType driver does this but the Type 1 driver
does not. In fact it selects *no* charmap at all. I think that all drivers
should select a Unicode charmap when loading a face. Can anybody comment?

By the way, I tested this by loading a well-known free PFA font and trying
to find the glyph index for 'G':

This didn't work (it gave the glyph index 0):

ft_error = FT_New_Face(library,"\\font\\misc-fixed.pfa",0,&face);
index = FT_Get_Char_Index(face,'G');

but this did (it gave the glyph index 40):

ft_error = FT_New_Face(library,"\\font\\misc-fixed.pfa",0,&face);
FT_Select_Charmap(face,ft_encoding_unicode);
index = FT_Get_Char_Index(face,'G');

Graham Asher




reply via email to

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