|
From: | Peter Hanzel |
Subject: | Re: [ft] freetype render mingliu.ttc |
Date: | Mon, 11 May 2009 10:24:52 +0200 |
Hello.I have just discovered that using FT_New_Face(library, "mingliu.ttc", 1, &face) I get correct advance for glyphs. So latin are proportional and so on. So the algorithm is good. But using FT_New_Face(library, "mingliu.ttc", 0, &face) I get always advance = 17 << 6.
Mingliu.ttf has two faces. Mingliu and PMingLiu. My freetype is version 2.3.9. Regards.----- Original Message ----- From: "Peter Hanzel" <address@hidden>
To: "Werner LEMBERG" <address@hidden> Cc: <address@hidden> Sent: Monday, May 11, 2009 10:10 AM Subject: Re: [ft] freetype render mingliu.ttc
Hello.Yes I have checked it. It returns face->glyph->advance.x = 17 << 6 for ALL GLYPHS in font.Maybe I am doing something bad by openning that TTC, because I am using normal FT_New_Face call to open that font.But TTC is a collection, what font will be choosed than?----- Original Message ----- From: "Werner LEMBERG" <address@hidden>To: <address@hidden> Cc: <address@hidden> Sent: Thursday, May 07, 2009 6:16 PM Subject: Re: [ft] freetype render mingliu.ttcI am using freetype2 to render texts. I am using face->glyph->advance.x to get adavance for moving. It works for arial.ttf like a charm. I have tried the same algorithm for mingliu.ttc and here is problem. For all glyph it returns advance.x = 17 << 6;For all glyphs? It should return the half width for glyphs like latin.I am using LOAD_MONOCHROME, RENDER_MONO on pixelSize = 17.Why do you think this is incorrect?Maybe it uses embedded bitmaps in mingliu.ttc and therefore returns bad advance.There are no embedded bitmaps for 17ppem.What should I do to get correct advance for MingLiu.ttc font?This is a TrueType collection. One font (MingLiU) has only two advance width values (512 and 1024 font units), the other one (PMingLiU) has *some* proportional advance widths. Werner
[Prev in Thread] | Current Thread | [Next in Thread] |