Discussion:
Font Metrics
Atul Barve
2004-07-06 05:33:47 UTC
Permalink
Hello,

I am running into a bit of a problem. I am trying to implement a List
Panel. In order to do this i need to calculate the text height. Using
font.GetFontMetrics(), returns some really weird numbers. any clues.

Here is the sample code.

CascadeFont::Attributes attr( "system", CascadeFont::kNormal, 18 );
CascadeFont::Metrics fontMetrics;

mListFont.SetAttributes( attr );
mListFont.GetFontMetrics(fontMetrics);

the Values 29811 txt Height, 10752 txtDecent

What am i doing wrong. GetTextExtents returns the correct Height of 16



Atul

Loading...