Carbon


ATSUGetFontFallbacks

Header: ATSUnicode.h Carbon status: Supported

Indicates the previously specified font list and search order to use when a font does not have all the glyphs for the characters it is trying to draw.

OSStatus ATSUGetFontFallbacks (
    ItemCount iMaxFontFallbacksCount, 
    ATSUFontID oFonts, 
    ATSUFontFallbackMethod *oFontFallbackMethod, 
    ItemCount *oActualFallbacksCount
);
Parameter descriptions
iMaxFontFallbacksCount

The maximum number of fonts that you want searched. Typically, this is equivalent to the number of fonts in the oFontIDs array. To determine this value, see the discussion below.

oFonts

An array of fonts. Before calling ATSUGetFontFallbacks, pass a pointer to memory that you have allocated for this array. If you are uncertain of how much memory to allocate, see the discussion below. On return, an array of the font IDs to be searched when a font does not have all the glyphs for the characters it is trying to draw.

oFontFallbackMethod

On return, a pointer to the order that fonts should be searched. See “Font Fallback Constants” for a description of possible values.

oActualFallbacksCount

On return, a pointer to the number of fonts that you want searched. This may be greater than the value passed in the iMaxFontFallbacksCount parameter. You cannot pass NULL for this parameter.

function result

A result code.

DISCUSSION

The ATSUGetFontFallbacks function determines the fonts you want searched and the search order to use when a font does not have all the glyphs for the characters it is trying to draw.

The best way to use ATSUGetFontFallbacks is to call it twice:

  1. Pass NULL for the oFontIDs parameter and 0 for the other parameters. ATSUGetFontFallbacks returns the size of the font array in the oActualFallbacksCount parameter.
  2. Allocate enough space for an array of the returned size, then call the function again, passing a pointer in the oFontIDs parameter; on return, the pointer references an array of fonts to be searched.

VERSION NOTES

Available beginning with ATSUI 1.1.

AVAILABILITY

Supported in Carbon. Available in Carbon 1.0.2 and later when running Mac OS 8.6 or later.


© 2000 Apple Computer, Inc. (Last Updated 6/30/2000)