Creates a path for the specified glyph.
SDKs
- iOS 3.2+
- macOS 10.5+
- Mac Catalyst 13.0+
- tvOS 9.0+
- watchOS 2.0+
Framework
- Core Text
Declaration
CGPath Ref CTFontCreatePathForGlyph(CTFont Ref font, CGGlyph glyph, const CGAffine Transform *matrix);
Parameters
font
The font reference.
glyph
The glyph.
transform
An affine transform applied to the path. Can be
NULL
. IfNULL
,CGAffine
is used.Transform Identity
Return Value
A CGPath object containing the glyph outlines, NULL
on error. Must be released by caller.
Discussion
Creates a path from the outlines of the glyph for the specified font. The path reflects the font point size, matrix, and transform parameter, applied in that order. The transform parameter is most commonly be used to provide a translation to the desired glyph origin.