Stores the initial glyphs and glyph properties for a character range.
- iOS 7.0+
- macOS 10.11+
- Mac Catalyst 13.0+
- tvOS 9.0+
A pointer to the layout manager's glyph cache.
A pointer to a buffer containing glyph properties for the glyphs in the cache.
A pointer to the starting index for the characters in the text storage for which glyphs are generated.
A font to override the font attributes in the text storage for the specified character range.
The range of glyphs in the glyph cache to set.
This method is invoked by text system during the glyph generation process. The only place apps are allowed to call this method directly is from an implementation of the
NSLayout protocol method
Each array has
glyph items. The specified
char must be contiguous (no skipped indexes), enabling multiple items to have a same character index (as when one character index generates multiple glyph IDs). Due to font substitution,
a passed into this method might not match the font in the attributes dictionary. Calling this method for a character range that has previously calculated layout information invalidates the layout and display.