freetype-devel
[Top][All Lists]
Advanced

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

[ft-devel] freetype2 question


From: ayoub mejri
Subject: [ft-devel] freetype2 question
Date: Thu, 30 Oct 2008 12:02:24 +0100

Hello,
This is an explanation of my problem
 
 
the text that I parse is :
"[tagTITLE] Printing [endtagTITLE]
how to make printing."
 
- It consisting of 2 lines: the first is a Title means double sized
the second line is a simple text
 
- The algorthime is
while (getNextToken)
{
 if (tken==tagTITLE)
      FT_Set_Char_Size(ft_face, 64*
     24, 64 *24 ,600,600)
 if (tken==endtagTITLE)
      FT_Set_Char_Size(ft_face, 64*
     12, 64 *12 ,600,600)
 if(token==character)
  draw_character(x,y,character);
}
 
- in the function draw_character , I call the function
FTC_ImageCache_LookupScaler(image_cache, &scaler, ft_load_flags, glyph_index, &CacheGlyph, NULL )
 
-The scaler is always the following:
 
scaler.width =12*64;
 scaler.height = 12*64;
 scaler.pixel = 0;
 scaler.x_res = 600;
 scaler.y_res = 600;
 scaler.face_id = face_id;
 
- The result is
"Printing
how to make printing"
- The second 't' and "printing" are so big beaucause they are cached with the size 24.
I don't comprehend why some character in the second lin are with a 24 size (t,P,r,i,n,t,i,n,g)
 
Please If you can help me.

reply via email to

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