Win32Prn() > Font settings xHarbour Developers Network  

oWin32Prn:fontWidth

Array describing the width of the current font.

Info

Data type:NDefault:{0,0}

Description

The instance variable :fontWidth contains an array with two elements holding numeric integer values. The font width is defined with method :setFont() after :create() is called. It is calculated in the unit "Characters Per Inch" (CPI) by dividing the second element of :fontWidth by the first element. For example:

   ::fontWidth := { 3, 50 }

   nCPI := ::fontWidth[2]/::fontWidth[1]

   ? nCPI  // 16.67 characters per inch

When :fontWidth contains the array {0,0} the default font width is selected.

Note:  when the second element contains a negative value, fixed character spacing is enforced, even if the font is a proportional font.


Copyright © 2006-2007 xHarbour.com Inc. All rights reserved.
http://www.xHarbour.com
Created by docmaker.exe