O'Reilly logo

Cocoa in a Nutshell by James Duncan Davidson, Michael Beam

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Name

NSGlyphInfo — Mac OS X 10.2

Synopsis

This class is used in attributed strings as a value for the attribute NSGlyphInfoAttributeName. Glyph info objects are used to specify a mapping between a Unicode character code and a glyph ID, thus permitting clients to override the default glyph used by a font to represent some Unicode character.

image with no caption

@interface NSGlyphInfo : NSObject <NSCoding>
                                  // Class Methods
   + (NSGlyphInfo *)glyphInfoWithCharacterIdentifier:(unsigned int)cid
                                 collection:(NSCharacterCollection)characterCollection 
                                 baseString:(NSString *)theString;
   + (NSGlyphInfo *)glyphInfoWithGlyph:(NSGlyph)glyph 
                                 forFont:(NSFont *)font 
                                 baseString:(NSString *)theString;
   + (NSGlyphInfo *)glyphInfoWithGlyphName:(NSString *)glyphName
                                 forFont:(NSFont *)font 
                                 baseString:(NSString *)theString;
                                  // Instance Methods
   - (NSCharacterCollection)characterCollection;
   - (unsigned int)characterIdentifier;
   - (NSString *)glyphName;
                                  // Methods Implementing NSCoding
   - (void)encodeWithCoder:(NSCoder *)aCoder;
   - (id)initWithCoder:(NSCoder *)aDecoder;

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required