Legacy Documentclose button

Important: The information in this document is obsolete and should not be used for new development.

Previous Book Contents Book Index Next

Inside Macintosh: Text /
Chapter 6 - Script Manager / Script Manager Reference
Routines / Determining Script Codes From Font Information


FontToScript

The FontToScript function translates a font family ID number into its corresponding script code, if that script system is currently enabled.

FUNCTION FontToScript (fontNumber: Integer): Integer;
fontNumber
A font family ID number.
DESCRIPTION
The FontToScript function returns a script code. All recognized script codes and their defined constants are listed on page 6-52. FontToScript returns only explicit script codes (\xD1 0).

If fontNumber is in the Roman range and the font force flag is TRUE, the script code returned is that of the system script and the script-forced result flag is set to TRUE.

If fontNumber is in the non-Roman range, the state of the font force flag is ignored.

If the script system corresponding to fontNumber is not enabled, the script code returned is that of the system script and the script-defaulted result flag is set to TRUE.

SPECIAL CONSIDERATIONS
FontToScript may move memory; your application should not call this function at interrupt time.


Previous Book Contents Book Index Next

© Apple Computer, Inc.
6 JUL 1996