Creating and managing styled text

The basic text classes are the low-level classes that help you store and manipulate sequences of Unicode characters. You create text objects and add the Unicode character data, along with any style information associated with individual characters or ranges of characters. The system also includes classes for iterating through both the character and style data contained by a text object (see "Iterating through character data and style sets" on page 53).

NOTE These classes do not directly support text rendering or keyboard input. They provide the basic facility for manipulating text in memory. The Text Editing framework uses these classes as the foundation for displayable editable text data models (see Chapter 5, "Text Editing framework").


TText provides the basic protocol for manipulating strings of styled text. TText encapsulates character and style data and defines the protocol for accessing character data, inserting and deleting characters, and accessing and modifying style information.

TStandardText provides a default implementation of TText that you can generally use whenever you need to create a text object, for either styled or unstyled text. TStandardText is appropriate for text strings of any size up to 2 billion characters.

TStyleSet provides the protocol for storing the set of styles associated with a particular range of characters.

TStyle provides the abstract base protocol for character styles. Each style is defined as a style object containing the style name and the current value--for example, the style name Point size and the value 14.


[Contents] [Previous] [Next]
Click the icon to mail questions or corrections about this material to Taligent personnel.
Copyright©1995 Taligent,Inc. All rights reserved.

Generated with WebMaker