PATH |
EOCocoaTextPlugin
- Inherits from:
- EOCocoaSimpleTextPlugin : EOTextAssociation.TextPlugin (EOInterface) : EOValueAssociation.ValuePlugin (EOInterface) : EOWidgetAssociation.WidgetPlugin (EOInterface) : Object
- Implements:
- NSDisposable
- Package:
- com.webobjects.eointerface.cocoa
Class Description
In a Cocoa application, an EOCocoaTextPlugin object displays a plain or rich text attribute in an NSText object (com.apple.cocoa.application.NSText) by binding the text object to a string or NSData attribute. It determines the kind of text received from an object by examining the beginning for signature codes specific to RTF and RTFD. When writing text back to the object, the association examines the configuration of the NSText object to determine the type to use according to the following table:
Multiple Fonts | Allows Graphics | Type Written to Object |
NO | NO | NSString text |
YES | NO | NSData containing RTF |
YES | YES | NSData containing RTFD |
Usable With |
NSText, NSTextView. |
Aspects | |
value |
A text attribute of the selected object. |
editable |
A boolean attribute of the selected object, which determines whether the text object is editable. |
enabled |
A boolean attribute of the selected object, which determines whether the text object is enabled. |
Object Keys Taken | |
delegate |
An EOTextAssociation accepts delegate messages related to the editing and validation of text; see the NSText and NSTextView class specifications for more information. |
Interfaces Implemented
- NSDisposable
- dispose
Method Types
- All methods
- EOCocoaTextPlugin
- breakConnection
- establishConnection
- setColors
- setFontProperties
- setValue
- value
Constructors
EOCocoaTextPlugin
public EOCocoaTextPlugin( com.webobjects.eointerface.EOWidgetAssociation anEOWidgetAssociation, Object widget)
You normally set up associations with the Interface Builder application, in which case you don't need to create them programmatically. However, if you do create them up programmatically, setting them up is a multi-step process. After creating an association, you must bind its aspects and establish its connections.
See Also: bindAspect (EOAssociation), establishConnection (EOAssociation)
Instance Methods
breakConnection
public void breakConnection()
dispose
public void dispose()
establishConnection
public void establishConnection()
setColors
public void setColors( Object textColor, Object backgroundColor)
setFontProperties
public void setFontProperties( int boldState, int italicState)
setValue
public void setValue( Object value, boolean editable)
value
public Object value()
© 2001 Apple Computer, Inc. (Last Published April 21, 2001)