freetype
[Top][All Lists]
Advanced

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

Re: [ft] Re French accents & Freetype2 :)


From: Mahendra Tallur
Subject: Re: [ft] Re French accents & Freetype2 :)
Date: Mon, 01 Aug 2005 09:53:36 +0200

> when using ft2, trying to display some text in iso 8859-1 encoding, the
> French accents don't get displayed - I get empty boxes instead.

OK, so when keeping the most important bits, here is basically what I do
- in other word, I don't select another Charmap, because I can't find an
iso 8859-1 one, just unicode...

        
FT_Library library;
FT_Face face;

if ((error = FT_Init_FreeType( &library )))
{
        *ierr=2;
        return(-1);
}
                
if ((error = FT_New_Face( library, font, 0, &face )))
{
        *ierr=3;
        return(-1);
} 

(...)

glyph_index = FT_Get_Char_Index(face, text[i]); 

failure |= FT_Load_Glyph(face, glyph_index, FT_LOAD_DEFAULT ); 
failure |= FT_Render_Glyph(face->glyph, ft_render_mode_normal ); 

(...)

cheers,
- mahen





reply via email to

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