XPRINT CHR SIZE statement

Purpose | Retrieve the character size for the current font on a host printer page.
Syntax | XPRINT CHR SIZE TO WidthVar!, HeightVar! Function Form: WidthVar! = XPRINT(Chr.Size.X) HeightVar! = XPRINT(Chr.Size.Y)

Remarks

The character size is specified in the same terms (pixels or scaled units) as originally stated. The height value retrieved is the actual size of the printed character without including any external leading for this particular font.

If the font is a fixed-width font, like Courier New or Lucida Console, the sizes returned are as exact as possible, given the fractional rounding approximations possible when converting from pixels to other coordinates. If the font is proportional, like Arial or Times New Roman, the width will be the average size for the entire font.

External leading is the vertical distance from the bottom of one character to the top of the character below it. This value is specified by the font in use. It may vary from zero to a larger value, depending upon the font and point size. To retrieve the total row height including external leading, use XPRINT CELL SIZE.

See also | XPRINT, XPRINT ATTACH, XPRINT CELL SIZE, XPRINT SET FONT, XPRINT TEXT SIZE