Chia I Wu wrote:
On Fri, Aug 12, 2005 at 11:28:42AM +0200, Michele Petrazzo wrote:
Chia I Wu wrote: Ok, but if I see this value, I see that it's
lesser than that into glyph! (I think that it's not possible, is it
true?)
I guess it's possible because face->bbox is the bounding box of the
unhinted glyphs and the glyph loaded is hinted. But the reason
face->bbox is smaller than glyph's bbox here might be the wrong
scaling.
Ok.
Is there a possible to know the right value of my "I" character
(19x75) with freetype?
It has width 7 and height 48. The `19' is the advance width and I
don't know where the `75' comes from.
These values come from another library (wxWidgets), that return me 19x75.
http://wxwidgets.org/manuals/2.6.1/wx_wxdc.html#wxdcgettextextent
I had started with that values (library) because before try this
fantastic but very hard to understand (for me) library, freetype, I
thought to start with a simple library like wxWidgets, see what
results it return me and than compare them to freetype's library.
Into my tries, I see that wxWidget (that wrap the OS functions, in this
case GetTextExtentPoint32 on win32 and pango_layout_get_pixel_size on
gtk) return me 19x75, so I think that those are correct, so I'll search
it on freetype.
Is there the possibility that those two library return me different
size ?
<-cut->
and here, since they are already expressed in (26.6) pixels.
Ok.
printf("Face Y: %d, X: %d% \n", FT_MulFix( (bbox.yMax -
bbox.yMin), metric_f.y_scale) , FT_MulFix( (bbox.xMax - bbox.xMin),
metric_f.x_scale )); printf("BBox xMi %d,xMa %d,yMi %d,yMa %d, \n",
bbox.xMin, bbox.xMax, bbox.yMin, bbox.yMax );
And you should scale the values here.
Thanks,
Michele
_______________________________________________
Freetype mailing list
[email protected]
http://lists.nongnu.org/mailman/listinfo/freetype