---
title: "hyphenCharacter(forGlyphAt:)"
framework: appkit
role: symbol
role_heading: Instance Method
path: "appkit/nsatstypesetter/hyphencharacter(forglyphat:)"
---

# hyphenCharacter(forGlyphAt:)

Returns the hyphen character to be inserted after the specified glyph when hyphenation is enabled in the layout manager.

## Declaration

```swift
func hyphenCharacter(forGlyphAt glyphIndex: Int) -> UTF32Char
```

## Discussion

Discussion The typesetter calls this method before hyphenating. A subclass can override this method to return a different hyphen glyph.

## See Also

### Laying Out Glyphs

- [boundingBox(forControlGlyphAt:for:proposedLineFragment:glyphPosition:characterIndex:)](appkit/nsatstypesetter/boundingbox(forcontrolglyphat:for:proposedlinefragment:glyphposition:characterindex:).md)
- [getLineFragmentRect(_:usedRect:forParagraphSeparatorGlyphRange:atProposedOrigin:)](appkit/nsatstypesetter/getlinefragmentrect(_:usedrect:forparagraphseparatorglyphrange:atproposedorigin:).md)
- [hyphenationFactor(forGlyphAt:)](appkit/nsatstypesetter/hyphenationfactor(forglyphat:).md)
- [shouldBreakLine(byHyphenatingBeforeCharacterAt:)](appkit/nsatstypesetter/shouldbreakline(byhyphenatingbeforecharacterat:).md)
- [shouldBreakLine(byWordBeforeCharacterAt:)](appkit/nsatstypesetter/shouldbreakline(bywordbeforecharacterat:).md)
- [willSetLineFragmentRect(_:forGlyphRange:usedRect:baselineOffset:)](appkit/nsatstypesetter/willsetlinefragmentrect(_:forglyphrange:usedrect:baselineoffset:).md)
- [setHardInvalidation(_:forGlyphRange:)](appkit/nsatstypesetter/sethardinvalidation(_:forglyphrange:).md)
