IGR_Canvas_SetFont¶
Specifies the font to use when drawing text to the canvas. All subsequent calls to TextOut and MeasureText will use this font.
Prototype¶
IGR_LONG IGR_Canvas_SetFont(
HCANVAS canvas,
const IGR_UCS2* fontFamily,
IGR_LONG size,
IGR_LONG style,
Error_Control_Block* error);
Parameters¶
Canvas: HCANVAS
Handle to a canvas, opened by a call to IGR_Make_Output_Canvas.
FontFamily: Pointer to Unicode String
The font family (or typeface) of the font.
Size: IGR_LONG
The size, in points, of the font.
Style: IGR_LONG
A bitmask of style information, can be zero or more of the following:
Character Value | Description |
---|---|
0x01 | FONT_STYLE_BOLD |
0x02 | FONT_STYLE_ITALICS |
0x04 | FONT_STYLE_UNDERLINE |
0x08 | FONT_STYLE_STRIKEOUT |
0x10 | FONT_STYLE_SERIF |
0x20 | FONT_STYLE_MONO |
0x40 | FONT_STYLE_RTL |
Error: Pointer to Error_Control_Block
Returns error details if the call fails.
Return value¶
Success: IGR_LONG
Returns IGR_OK.
Failure: IGR_LONG
Returns one of the possible IGR_E error codes.
Additional information¶
Note The drawing API is available for bitmap and PDF outputs only. Drawing onto an HTML5 output is not supported.