I dont understand why
LOCAL oFont := TFONT():NEW( "SEGOE UI", 0, - 12 , .F., .F.,,,,,,,,,,, )
is bigger than
LOCAL oFont := TFONT():NEW( "SEGOE UI", 0, 12 , .F., .F.,,,,,,,,,,, )
Tx U
I dont understand why
LOCAL oFont := TFONT():NEW( "SEGOE UI", 0, - 12 , .F., .F.,,,,,,,,,,, )
is bigger than
LOCAL oFont := TFONT():NEW( "SEGOE UI", 0, 12 , .F., .F.,,,,,,,,,,, )
Tx U
It's an expected Windows API behavior.
EMG
The negative sign really means points instead of pixels. Without the negative it means pixels.
So, 0,-12 is a 12 point font. 0,12 is a font 0 pixels wide and 12 pixels high. I suspect the zero defaults to something larger than 0.
James
A point is 1/72 of an inch, so a 12 point font would be 12/72 inch. This is independent of the device that is displaying the font.
Pixels are dependent on the device (screen, printer) so they would be different heights on different devices. For this reaon you would generally want to use fonts defined in points rather than pixels.
There is a good definition of points in wikipedia.
Regards,
James





