Contents

CTFontCreatePathForGlyph(_:_:_:)

Creates a path for the specified glyph.

Declaration

func CTFontCreatePathForGlyph(_ font: CTFont, _ glyph: CGGlyph, _ matrix: UnsafePointer<CGAffineTransform>?) -> CGPath?

Parameters

  • font:

    The font reference.

  • glyph:

    The glyph.

  • matrix:

    An affine transform applied to the path. Can be NULL. If NULL, Cgaffinetransformidentity is used.

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.

See Also

Getting Glyph Data