freetype-devel
[Top][All Lists]
Advanced

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

Re: [ft-devel] Is it BUG???


From: Z3N
Subject: Re: [ft-devel] Is it BUG???
Date: Thu, 03 Sep 2009 16:18:34 +0300
User-agent: Thunderbird 2.0.0.21 (Windows/20090302)

address@hidden пишет:
Hi,

On Wed, 26 Aug 2009 15:57:21 +0300
Z3N <address@hidden> wrote:

  
Hi! Can you tell me what wrong in this code? Or its one of bugs in 
freetype? I'm use FF 2.3.9.s
/* There hide code, which initializing FF... correctly.
Other things, like rendering, working....*/
FT_UInt        Left,Right;
FT_Vector  delta;
Left=FT_Get_Char_Index( face, (FT_ULong)* L"V" );
Right=FT_Get_Char_Index( face,(FT_ULong)* L"A" );
FT_Get_Kerning( face, Left, Right,FT_KERNING_DEFAULT, &delta );
delta.x=delta.x>>6;

But, the value, which returned from FT_Get_Kerning always 0! This face 
support kerning, I check it with macros FT_HAS_KERNING and he is return 
40!!! This is good, isn't?
What's wrong???
    

Oh, please give a name for any free font to reproduce your problem.

  
And can you tell me how do I handle the "Italic" style in face? Imagine, 
I'm create face from file "arial.ttf" and later I need aply "Italic" 
style to them. I'm know what "italic" style located in other file 
"ariali.ttf", but maybe FreeType provide some useful API for this 
case??? This is can save my psychical health :). Or I need create new 
face from "ariali.ttf" and render from this face???
    

FT_Face object is bound to the font file or memory image
that you opened. In this case, when you open alial.ttf
and create an FT_Face object once, you cannot disconnect
it from arial.ttf. You should open ariali.ttf as another
FT_Face object.

In addition, the searching of font file - from arial.ttf
to ariali.ttf - is not the task of FT2. Most Unix applications
use fontconfig library to obtain the location of expected
font face.

However, there are many font families that only normal
upright styles are provided (without bold, oblique styles).
Some people want to synthesize embolden/slanted typeface
from normal upright typeface, so FT2 provides
FT_GlyphSlot_Oblique(), FT_GlyphSlot_Embolden() etc.
For detail, please check src/base/ftsynth.c.

Regards,
mpsuzuki
  
Hi!
Oh, please give a name for any free font to reproduce your problem.
Thanks, you help me. After reading you letter I'm use debugger to solve problem. I'm think what FT_Get_Kerning always return 0... this is my mistake. Not always, just in most cases. Good experience for me....


I'm have some new question. How to add digits in 16.16, or 26.6 format??? a>>6+b>>6 - not usefull.

With best regards, Z3N


reply via email to

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