<!--
{
  "documentType" : "article",
  "framework" : "AppKit",
  "identifier" : "/documentation/AppKit/nslayoutmanager-deprecated-symbols",
  "metadataVersion" : "0.1.0",
  "role" : "collectionGroup",
  "title" : "Deprecated Symbols"
}
-->

# Deprecated Symbols

Review unsupported symbols and their replacements.

## Topics

### Methods

[`func showCGGlyphs(UnsafePointer<CGGlyph>, positions: UnsafePointer<NSPoint>, count: Int, font: NSFont, matrix: AffineTransform, attributes: [NSAttributedString.Key : Any], in: NSGraphicsContext)`](/documentation/AppKit/NSLayoutManager/showCGGlyphs(_:positions:count:font:matrix:attributes:in:))

Renders the glyphs at the specified positions, using the specified attributes.

[`func invalidateGlyphs(onLayoutInvalidationForGlyphRange: NSRange)`](/documentation/AppKit/NSLayoutManager/invalidateGlyphs(onLayoutInvalidationForGlyphRange:))

Specifies explicitly when portions of the glyph stream depend on layout.

[`func invalidateLayout(forCharacterRange: NSRange, isSoft: Bool, actualCharacterRange: NSRangePointer?)`](/documentation/AppKit/NSLayoutManager/invalidateLayout(forCharacterRange:isSoft:actualCharacterRange:))

Invalidates the layout information for the glyphs mapped to the given range of characters.

[`func textStorage(NSTextStorage, edited: Int, range: NSRange, changeInLength: Int, invalidatedRange: NSRange)`](/documentation/AppKit/NSLayoutManager/textStorage(_:edited:range:changeInLength:invalidatedRange:))

Invalidates glyph and layout information for a portion of the text in the given text storage object.

[`func insertGlyph(NSGlyph, atGlyphIndex: Int, characterIndex: Int)`](/documentation/AppKit/NSLayoutManager/insertGlyph(_:atGlyphIndex:characterIndex:))

Inserts a single glyph into the glyph stream at the given index and maps it to the character at the given character index.

[`func insertGlyphs(UnsafePointer<NSGlyph>, length: Int, forStartingGlyphAt: Int, characterIndex: Int)`](/documentation/AppKit/NSLayoutManager/insertGlyphs(_:length:forStartingGlyphAt:characterIndex:))

Inserts the given glyphs into the glyph cache at the given index and maps them to characters beginning at the given character index.

[`func glyph(at: Int) -> NSGlyph`](/documentation/AppKit/NSLayoutManager/glyph(at:))

Returns the glyph at the specified index.

[`func glyph(at: Int, isValidIndex: UnsafeMutablePointer<ObjCBool>?) -> NSGlyph`](/documentation/AppKit/NSLayoutManager/glyph(at:isValidIndex:))

Returns the glyph at a specified index, and optionally returns a flag indicating whether the requested index is valid.

[`func replaceGlyph(at: Int, withGlyph: NSGlyph)`](/documentation/AppKit/NSLayoutManager/replaceGlyph(at:withGlyph:))

Replaces the glyph at the given index with a new glyph.

[`func getGlyphs(UnsafeMutablePointer<NSGlyph>?, range: NSRange) -> Int`](/documentation/AppKit/NSLayoutManager/getGlyphs(_:range:))

Fills the passed-in buffer with a sequence of glyphs.

[`func getGlyphs(in: NSRange, glyphs: UnsafeMutablePointer<NSGlyph>?, characterIndexes: UnsafeMutablePointer<Int>?, glyphInscriptions: UnsafeMutablePointer<NSGlyphInscription>?, elasticBits: UnsafeMutablePointer<ObjCBool>?) -> Int`](/documentation/AppKit/NSLayoutManager/getGlyphs(in:glyphs:characterIndexes:glyphInscriptions:elasticBits:))

Returns the glyphs and information needed to perform layout for the given glyph range.

[`func getGlyphs(in: NSRange, glyphs: UnsafeMutablePointer<NSGlyph>?, characterIndexes: UnsafeMutablePointer<Int>?, glyphInscriptions: UnsafeMutablePointer<NSGlyphInscription>?, elasticBits: UnsafeMutablePointer<ObjCBool>?, bidiLevels: UnsafeMutablePointer<UInt8>?) -> Int`](/documentation/AppKit/NSLayoutManager/getGlyphs(in:glyphs:characterIndexes:glyphInscriptions:elasticBits:bidiLevels:))

Returns the glyphs and information needed to perform layout for the given glyph range.

[`func deleteGlyphs(in: NSRange)`](/documentation/AppKit/NSLayoutManager/deleteGlyphs(in:))

Deletes the glyphs in the given range from the receiver’s glyph store.

[`func setCharacterIndex(Int, forGlyphAt: Int)`](/documentation/AppKit/NSLayoutManager/setCharacterIndex(_:forGlyphAt:))

Sets the index of the character corresponding to the glyph at the given glyph index.

[`func intAttribute(Int, forGlyphAt: Int) -> Int`](/documentation/AppKit/NSLayoutManager/intAttribute(_:forGlyphAt:))

Returns the value of the attribute identified by the given attribute tag for the glyph at the given index.

[`func setIntAttribute(Int, value: Int, forGlyphAt: Int)`](/documentation/AppKit/NSLayoutManager/setIntAttribute(_:value:forGlyphAt:))

Sets a custom attribute value for a given glyph.

[`func setLocations(NSPointArray, startingGlyphIndexes: UnsafeMutablePointer<Int>, count: Int, forGlyphRange: NSRange)`](/documentation/AppKit/NSLayoutManager/setLocations(_:startingGlyphIndexes:count:forGlyphRange:))

Sets locations for many glyph ranges at once.

[`func rectArray(forCharacterRange: NSRange, withinSelectedCharacterRange: NSRange, in: NSTextContainer, rectCount: UnsafeMutablePointer<Int>) -> NSRectArray?`](/documentation/AppKit/NSLayoutManager/rectArray(forCharacterRange:withinSelectedCharacterRange:in:rectCount:))

Returns an array of rectangles and, by reference, the number of such rectangles, that define the region in the given container enclosing the given character range.

[`func rectArray(forGlyphRange: NSRange, withinSelectedGlyphRange: NSRange, in: NSTextContainer, rectCount: UnsafeMutablePointer<Int>) -> NSRectArray?`](/documentation/AppKit/NSLayoutManager/rectArray(forGlyphRange:withinSelectedGlyphRange:in:rectCount:))

Returns an array of rectangles and, by reference, the number of such rectangles, that define the region in the given container enclosing the given glyph range.

[`func substituteFont(for: NSFont) -> NSFont`](/documentation/AppKit/NSLayoutManager/substituteFont(for:))

Replaces the specified font with a suitable screen font if one is available.

[`- (void) showPackedGlyphs:(char *) glyphs length:(NSUInteger) glyphLen glyphRange:(NSRange) glyphRange atPoint:(NSPoint) point font:(NSFont *) font color:(NSColor *) color printingAdjustment:(NSSize) printingAdjustment;`](/documentation/AppKit/NSLayoutManager/showPackedGlyphs:length:glyphRange:atPoint:font:color:printingAdjustment:)

Draws a range of glyphs.

### Properties

[`var hyphenationFactor: Float`](/documentation/AppKit/NSLayoutManager/hyphenationFactor)

The threshold controlling when hyphenation is done.

[`var usesScreenFonts: Bool`](/documentation/AppKit/NSLayoutManager/usesScreenFonts)

A Boolean that controls using screen fonts to calculate layout and display text.

### Types

[`enum NSGlyphInscription : NSUInteger;`](/documentation/AppKit/NSGlyphInscription)

Constants that specify how a glyph is laid out relative to the previous glyph.



---

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)