FONT END statement

Purpose

Destroy a font when it is no longer needed.

Syntax

FONT END fonthndl&

fonthndl&

Handle of the font to be destroyed.

Remarks

When you have no further need for a font originally created with FONT NEW, you can destroy it and reclaim the memory space which was originally allocated for it.

If the specified font is still in use by a Control, a Graphic Control, a Graphic Window, or an XPrint page, an error 5 (Illegal Function Call) will be generated.  To avoid this error, you may restore the original default font with CONTROL/GRAPHIC/XPRINT SET FONT using a handle number of zero (0).

When your program ends, any existing fonts are automatically destroyed by PowerBASIC.

See also

CONTROL SET FONT, FONT NEW, GRAPHIC PRINT, GRAPHIC SET FONT, XPRINT, XPRINT SET FONT