Font

Version:1.0
Status:Unspecified
Date:May 2001
Author:Rocklyte Systems
Copyright:  Rocklyte Systems (c) 1998-2001. All rights reserved.



Function Index
InstallFont  Installs a new font to the system.
UninstallFont  Removes an installed font from the system.

 

Function:InstallFont()
Short:Installs a new font to the system.
Synopsis:ERROR InstallFont(Tags, ...)
Arguments:
Tags  A list of TGF tags, terminated with a TAGEND marker.

The InstallFont() function is used to install new fonts on a system running the Pandora Engine. While it is possible for users to download new font files and install them by hand, this is a process that is too difficult for novices and is open to mistakes on the part of the user. By writing a program that uses this function, the installation process can take place automatically.

To install a new font, you need to know the font's name, files and its category. A number of other details are optional. Calling this function requires that you provide this information in a tag-list. The available tags are listed in the following table:

TagDescription
TGF_NAMEThe name of the font.
TGF_FILESA list of data files that make up the font structure must be specified here. If there is more than one data file, separate each file name with a comma.
TGF_SUBDIRECTORY  You must provide a sub-directory, or 'category' that the font belongs to. For instance, if the font is a bitmap type then specify "Bitmap", if the font is in TrueType format then specify "TrueType".
TGF_FIXEDSIZEIf the font data supports a restricted amount of point sizes, list them in this string. For instance, if the Font can be drawn in 8pt, 12pt and 20pt sizes, the string should be set to "8,12,20"
TGF_RANGEDSIZEIf the font data supports a range of point sizes, list them in this string. For instance, if the Font supports any size between 8pt and 30pt and 50pt to 70pt then the string should be set to "8-30,50-70".

Once this function is called, the data files will be copied into the correct sub-directory and the font registration files will be updated to reflect the presence of the new font. The font will be available immediately thereafter and there is no need to reset the system to acknowledge the presence of the font.

Result
ERR_Okay  The font information was successfully installed.
ERR_ExclusiveDenied  Access to the SystemFonts object was denied.
ERR_Args  The Name, Files or SubDirectory tags were not specified.

 

Function:UninstallFont()
Short:Removes an installed font from the system.
Synopsis:ERROR UninstallFont(STRING Name)
Arguments:
Name  The name of the font face that you want to delete.

This function is designed to remove fonts that have been installed on a Pandora Engine system. All you need to do is provide the Name (face) of the font and it will be removed if it exists. Once a font has been removed, the data is permanently destroyed and it cannot be recovered.

Result
ERR_Okay  The font was succesfully removed.
ERR_Args  Invalid arguments were specified.