Name

NSSimpleHorizontalTypesetter — Mac OS X 10.0

Synopsis

This concrete subclass of NSTypesetter supports left-to-right line layout. This class handles such things as hyphenation, word wrapping, and line-breaking. For more information about Cocoa’s text layout engine, see Chapter 5.

image with no caption

@interface NSSimpleHorizontalTypesetter : NSTypesetter
                                  // Class Methods
   + (id)sharedInstance;
                                  // Instance Methods
   - (void)willSetLineFragmentRect:(NSRect *)aRect 
                                 forGlyphRange:(NSRange)aRange 
                                 usedRect:(NSRect *)bRect;
   - (NSTypesetterGlyphInfo *)baseOfTypesetterGlyphInfo;
   - (void)breakLineAtIndex:(unsigned)location;
   - (unsigned)capacityOfTypesetterGlyphInfo;
   - (void)clearAttributesCache;
   - (void)clearGlyphCache;
   - (NSTextContainer *)currentContainer;
   - (NSLayoutManager *)currentLayoutManager;
   - (NSParagraphStyle *)currentParagraphStyle;
   - (NSTextStorage *)currentTextStorage;
   - (void)fillAttributesCache;
   - (unsigned)firstGlyphIndexOfCurrentLineFragment;
   - (void)fullJustifyLineAtGlyphIndex:(unsigned)glyphIndexForLineBreak;
   - (unsigned)glyphIndexToBreakLineByHyphenatingWordAtIndex:(unsigned)charIndex;
   - (unsigned)glyphIndexToBreakLineByWordWrappingAtIndex:(unsigned)charIndex;
   - (unsigned)growGlyphCaches:(unsigned)desiredCapacity 
                                 fillGlyphInfo:(BOOL)fillGlyphInfo;
   - (void)insertGlyph:(NSGlyph)glyph 
                                 atGlyphIndex:(unsigned)glyphIndex 
                                 characterIndex:(unsigned)charIndex ...

Get Cocoa in a Nutshell now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.