setfont

Syntax

code = setfont ('fontname style', pointsize)

Arguments

code: integer

fontname, style: text

pointsize: numeric

Meaning

Sets the font which is to be used for printing, to fontname (font names are case-sensitive) with a particular pointsize. You can use proportional (like Arial) as well as non-proportional fonts (like Courier). Behind the font name but still within the single quotes, you may also add any of the following styles or combinations of them: bold, italic, and/or underline. Which fonts are available depends on the font collection installed in Windows and on the capabilities of your printer.

A printout may look different on various printers. This is mainly caused by printer properties which cannot be influenced by the Collections software. You may for instance have selected a font and font size in the adapl, that are unavailable in the printer. In such cases, Collections first tries to print in the specified font but in another font size, and if that does not work, it will select a different font. So preferably, select a font that is available in most printers, e.g. Arial, Times New Roman or Courier.

The return code is the error code of the action; this will be 0 if the action is successful. Any other value signifies the error code of the operating system.

Examples

errorcode = setfont ('Times New Roman', 10)

errorcode = setfont ('Arial bold italic', 12)