---
title: "getGlyphAdvances(glyphs:count:advances:)"
framework: coregraphics
role: symbol
role_heading: Instance Method
path: "coregraphics/cgfont/getglyphadvances(glyphs:count:advances:)"
---

# getGlyphAdvances(glyphs:count:advances:)

Gets the advance width of each glyph in the provided array.

## Declaration

```swift
func getGlyphAdvances(glyphs: UnsafePointer<CGGlyph>, count: Int, advances: UnsafeMutablePointer<Int32>) -> Bool
```

## Parameters

- `glyphs`: An array of glyphs.
- `count`: The number of glyphs in the array.
- `advances`: On output, an array of advance widths for the provided glyphs.

## Return Value

Return Value true unless the advance widths can’t be provided for some reason.

## See Also

### Working with Glyphs

- [numberOfGlyphs](coregraphics/cgfont/numberofglyphs.md)
- [name(for:)](coregraphics/cgfont/name(for:).md)
- [getGlyphWithGlyphName(name:)](coregraphics/cgfont/getglyphwithglyphname(name:).md)
- [getGlyphBBoxes(glyphs:count:bboxes:)](coregraphics/cgfont/getglyphbboxes(glyphs:count:bboxes:).md)
- [CGGlyph](coregraphics/cgglyph.md)
- [kCGGlyphMax](coregraphics/kcgglyphmax.md)
- [CGFontIndex](coregraphics/cgfontindex.md)
- [kCGFontIndexMax](coregraphics/kcgfontindexmax.md)
- [kCGFontIndexInvalid](coregraphics/kcgfontindexinvalid.md)
