TEXTXFORM


typedef struct tagTEXTXFORM {
    short  ftHeight;
    short  ftWidth;
    short  ftEscapement;
    short  ftOrientation;
    short  ftWeight;
    BYTE  ftItalic;
    BYTE  ftUnderline;
    BYTE  ftStrikeOut;
    BYTE  ftOutPrecision;
    BYTE  ftClipPrecision;
    short  ftAccelerator;
    short  ftOverhang;
} TEXTXFORM;

Contains information describing the actual appearance of text as displayed by the device.

ftHeight

Height of characters (ascent + descent), in device units.

ftWidth

Width, in device units, of the bounding box of the uppercase character "X."

ftEscapement

Angle, in tenths of a degree, counterclockwise from the x-axis of the vector passing through the origin of all the characters in the string.

ftOrientation

Angle, in tenths of a degree, counterclockwise from the x-axis of the baseline of the character.

ftWeight

Weight of the font ranging from 1 to 1000, with 400 being the value for the standard font.

ftItalic

Italic flag. If the low bit is set, the font is to be italic. All the other bits must be zero.

ftUnderline

Underline flag. If the low bit is set, the font is to be underlined. All the other bits must be zero.

ftStrikeOut

Strikeout flag. If the low bit is set, the font is to be struck out. All the other bits must be zero.

ftOutPrecision

Output precision for text. Can be one of these values:

OUT_DEFAULT_PRECIS (0x00)

Chooses a reasonable font.

OUT_STRING_PRECIS (0x01)

Chooses the font with a size (height and width) that most closely matches the requested size. The driver may disregard the requested orientation and escapement, but other attributes must match.

OUT_CHARACTER_PRECIS (0x02)

Chooses the font with a size (height and width) that most closely matches the requested size. The driver may disregard the requested orientation, but other attributes must match.

OUT_STROKE_PRECIS (0x03)

Chooses a font with attributes that exactly match the requested attributes.


ftClipPrecision

Clipping precision for text. Can be one of these values:

CLIP_DEFAULT_PRECIS (0x00)

Chooses a reasonable font.

CLIP_CHARACTER_PRECIS (0x01)

Chooses a font that allows clipping of individual characters. The driver must be able to clip a character if any portion of it lies outside the clipping rectangle.

CLIP_STROKE_PRECIS (0x02)

Chooses a font that allows clipping of portions of a character. The driver must be able to clip any portion of a character that lies outside the clipping rectangle.


ftAccelerator

Specifies requested text modifications using the same format as the dpText member of the GDIINFO structure. Each bit in this member is set if the corresponding ability is required to modify the physical font into the requested font.

ftOverhang

Same as tmOverhang of the TEXTMETRIC structure.

Although most of the members in the TEXTXFORM structure correspond to the members in the LOGFONT structure, these members may not always exactly match. For example, if the logical font specified a 19-unit font at string precision and the closest available was a 9-unit font on a device capable of doubling, then the ftHeight member in the structure is 18.

See also LOGFONT