Field_SetFont()

Examples


The Field_SetFont() function sets the font characteristics for a field.

Syntax

Field_SetFont(text_field, font, size, style)

Parameters

text_field – The field for which the font will be set.

font – An integer corresponding to one of the following constants:

[spacer]

Constant

Description

FONT_COURIER

Courier

FONT_HELVETICA

Helvetica

FONT_TIMES

Times

FONT_SYSTEM

The default system font


size – An integer specifying the size of the font in points.

style – An integer corresponding to one of the following constants:

[spacer]

Constant

Description

FONT_STYLE_PLAIN

Plain

FONT_STYLE_BOLD

Bold

FONT_STYLE_ITALIC

Italic

FONT_STYLE_UNDERLINE

Underline


You can apply multiple styles to a field by adding the style constants together. For example, to specify bold and underline, use FONT_STYLE_BOLD + FONT_STYLE_UNDERLINE.

Return value

A boolean. True indicates the font characteristics were set, while false indicates they were not.


Documentation Feedback