<!--
{
  "availability" : [
    "macOS: -"
  ],
  "documentType" : "symbol",
  "framework" : "AppKit",
  "identifier" : "/documentation/AppKit/NSGlyphStorage/insertGlyphs(_:length:forStartingGlyphAt:characterIndex:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "AppKit"
    ],
    "preciseIdentifier" : "c:objc(pl)NSGlyphStorage(im)insertGlyphs:length:forStartingGlyphAtIndex:characterIndex:"
  },
  "title" : "insertGlyphs(_:length:forStartingGlyphAt:characterIndex:)"
}
-->

# insertGlyphs(_:length:forStartingGlyphAt:characterIndex:)

Inserts the given glyphs into the glyph cache and maps them to the specified characters.

```
func insertGlyphs(_ glyphs: UnsafePointer<NSGlyph>, length: Int, forStartingGlyphAt glyphIndex: Int, characterIndex charIndex: Int)
```

## Parameters

`glyphs`

The glyphs to insert.

`length`

Number of glyphs to insert.

`glyphIndex`

Location in the glyph cache to begin inserting glyphs.

`charIndex`

Index of first character to be mapped.

## Discussion

This is a bulk insert method for the glyph cache.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)