Documentation Archive Developer
Search
PATH Documentation > WebObjects

Table of Contents

EOTextAssociation


Inherits from:
EOValueAssociation : EOWidgetAssociation : EOAssociation : EODelayedObserver (EOControl) : Object
Implements:
NSDisposable
EOObserving (EOControl)
Package:
com.webobjects.eointerface


Class Description


In a Java Client application (using Swing), an EOTextAssociation object displays a plain text attribute in an EOTextField, EOTextArea, or EOFormCell by binding the text object to a string. Text is written back to the object as a String.

In a Cocoa application, an EOTextAssociation object displays a plain or rich text attribute in an NSText object 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
com.webobjects.eointerface.swing: EOTextField, EOTextArea, EOFormCell
com.webobjects.eointerface.cocoa: NSText, NSTextView


Aspects
value A text attribute of the selected object.
URL Description forthcoming.
enabled Description forthcoming.
textColor Description forthcoming.
backgroundColor Description forthcoming.
bold Description forthcoming.
italic Description forthcoming.


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
EOObserving


Method Types


All methods
EOTextAssociation
defaultDisabledBackgroundColor
defaultEnabledBackgroundColor
setDefaultBackgroundColors
displayValueFromURL
setUsesDefaultBackgroundColors
usesDefaultBackgroundColors


Constructors



EOTextAssociation

public EOTextAssociation(Object aDisplayObject)

Creates a new EOTextAssociation to monitor and update the value in aDisplayObject, which is typically Cocoa NSActionCell or, in Swing applications, an EOFormCell.

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)




Static Methods



defaultDisabledBackgroundColor

public static Object defaultDisabledBackgroundColor()

Description forthcoming.

defaultEnabledBackgroundColor

public static Object defaultEnabledBackgroundColor()

Description forthcoming.

setDefaultBackgroundColors

public static void setDefaultBackgroundColors( Object enabledColor, Object disabledColor)

Description forthcoming.


Instance Methods



displayValueFromURL

protected Object displayValueFromURL(String URLString)

Description forthcoming.

dispose

public void dispose()

See the description in the documentation for NSDisposable.

setUsesDefaultBackgroundColors

public void setUsesDefaultBackgroundColors(boolean flag)

Description forthcoming.

usesDefaultBackgroundColors

public boolean usesDefaultBackgroundColors()

Description forthcoming.

© 2001 Apple Computer, Inc. (Last Published April 21, 2001)


Table of Contents