Up

# NSCell

### Authors

Scott Christley (`scottc@net-community.com`)

> The abstract cell class

Copyright: (C) 1996 Free Software Foundation, Inc.

### Contents -

1. Software documentation for the NSCell class
2. Software documentation for the NSCell(PrivateMethods) category

# Software documentation for the NSCell class

## NSCell : NSObject

> Declared in:
>   AppKit/NSCell.h

> Conforms to:
>   NSCopying
>   NSCoding

Availability: OpenStep

TODO Desctiption

Instance Variables
Method summary

- -_drawAttributedString
- -_drawAttributedText:inFrame:
- -_drawBorderAndBackgroundWithFrame:inView:
- -_drawFocusRingWithFrame:inView:
- -_drawText:inFrame:
- -_nonAutoreleasedTypingAttributes
- -_sendsActionOn:
- -_sizeText:
- -textColor
- +defaultFocusRingType
- +defaultMenu
- +prefersTrackingUntilMouseUp
- -acceptsFirstResponder
- -action
- -alignment
- -allowsEditingTextAttributes
- -allowsMixedState
- -allowsUndo
- -attributedStringValue
- -baseWritingDirection
- -calcDrawInfo:
- -cellAttribute:
- -cellSize
- -cellSizeForBounds:
- -compare:
- -continueTracking:at:inView:
- -controlSize
- -controlTint
- -controlView
- -doubleValue
- -drawInteriorWithFrame:inView:
- -drawWithFrame:inView:
- -drawingRectForBounds:
- -editWithFrame:inView:editor:delegate:event:
- -endEditing:
- -entryType
- -floatValue
- -focusRingType
- -font
- -formatter
- -getPeriodicDelay:interval:
- -hasValidObjectValue
- -highlight:withFrame:inView:
- -highlightColorWithFrame:inView:
- -image
- -imageRectForBounds:
- -importsGraphics
- -initImageCell:
- -initTextCell:
- -intValue
- -isBezeled
- -isBordered
- -isContinuous
- -isEditable
- -isEnabled
- -isEntryAcceptable:
- -isHighlighted
- -isOpaque
- -isScrollable
- -isSelectable
- -keyEquivalent
- -lineBreakMode
- -menu
- -menuForEvent:inRect:ofView:
- -mnemonic
- -mnemonicLocation
- -mouseDownFlags
- -nextState
- -objectValue
- -performClick:
- -performClickWithFrame:inView:
- -refusesFirstResponder
- -representedObject
- -resetCursorRect:inView:
- -selectWithFrame:inView:editor:delegate:start:length:
- -sendActionOn:
- -sendsActionOnEndEditing
- -setAction:
- -setAlignment:
- -setAllowsEditingTextAttributes:
- -setAllowsMixedState:
- -setAllowsUndo:
- -setAttributedStringValue:
- -setBaseWritingDirection:
- -setBezeled:
- -setBordered:
- -setCellAttribute:to:
- -setContinuous:
- -setControlSize:
- -setControlTint:
- -setControlView:
- -setDoubleValue:
- -setEditable:
- -setEnabled:
- -setEntryType:
- -setFloatValue:
- -setFloatingPointFormat:left:right:
- -setFocusRingType:
- -setFont:
- -setFormatter:
- -setHighlighted:
- -setImage:
- -setImportsGraphics:
- -setIntValue:
- -setLineBreakMode:
- -setMenu:
- -setMnemonicLocation:
- -setNextState
- -setObjectValue:
- -setRefusesFirstResponder:
- -setRepresentedObject:
- -setScrollable:
- -setSelectable:
- -setSendsActionOnEndEditing:
- -setShowsFirstResponder:
- -setState:
- -setStringValue:
- -setTag:
- -setTarget:
- -setTitle:
- -setTitleWithMnemonic:
- -setType:
- -setUpFieldEditorAttributes:
- -setWraps:
- -showsFirstResponder
- -startTrackingAt:inView:
- -state
- -stopTracking:at:inView:mouseIsUp:
- -stringValue
- -tag
- -takeDoubleValueFrom:
- -takeFloatValueFrom:
- -takeIntValueFrom:
- -takeObjectValueFrom:
- -takeStringValueFrom:
- -target
- -title
- -titleRectForBounds:
- -trackMouse:inRect:ofView:untilMouseUp:
- -type
- -wraps

### defaultFocusRingType

+ (NSFocusRingType) defaultFocusRingType;
Availability: Not in OpenStep/MacOS-X
Description forthcoming.

### defaultMenu

+ (NSMenu*) defaultMenu;
Availability: MacOS-X 10.0.0
Description forthcoming.

### prefersTrackingUntilMouseUp

+ (BOOL) prefersTrackingUntilMouseUp;
Availability: OpenStep

This class method returns `NO`. This method should be overrided by subclasses.

### acceptsFirstResponder

- (BOOL) acceptsFirstResponder;
Availability: MacOS-X 10.0.0
Description forthcoming.

### action

- (SEL) action;
Availability: OpenStep

Implemented by subclasses to return the action method. The NSCell implementaiton returns NULL.

See Also: -setAction: -setTarget: -target

### alignment

- (NSTextAlignment) alignment;
Availability: OpenStep

Returns the alignment of the text used in the NSCell. See NSTextAlignment for more informations. By default the text alignment is NSJustifiedTextAlignment

See Also: -setAlignment:

### allowsEditingTextAttributes

- (BOOL) allowsEditingTextAttributes;
Availability: MacOS-X 10.0.0
Description forthcoming.

### allowsMixedState

- (BOOL) allowsMixedState;
Availability: OpenStep
Description forthcoming.

### allowsUndo

- (BOOL) allowsUndo;
Availability: Not in OpenStep/MacOS-X
Description forthcoming.

### attributedStringValue

- (NSAttributedString*) attributedStringValue;
Availability: MacOS-X 10.0.0
Description forthcoming.

### baseWritingDirection

- (NSWritingDirection) baseWritingDirection;
Availability: Not in OpenStep/MacOS-X
Description forthcoming.

### calcDrawInfo:

- (void) calcDrawInfo: (NSRect)aRect;
Availability: OpenStep

Does nothing. This method is used by subclasses to recalculate sizes

It is usally called from a NSControl object

See Also: [NSControl -calcSize]

### cellAttribute:

- (int) cellAttribute: (NSCellAttribute)aParameter;
Availability: OpenStep

Returns some NSCell's attributes for the specified NSCellAttribute

See Also: -setCellAttribute:to:

### cellSize

- (NSSize) cellSize;
Availability: OpenStep
Returns the minimun size needed to display the NSCell. This size is calculate by adding :

- the borders (plain or bezeled) size
- the spacing between the border and inside the cell
- the TODO... if the cell is type of NSTextCellType or the image size if the cell has a NSImageCellType type.

This method returns NSZeroSize if the cell has a NSNullCellType type (Cocoa returns a very big size instead).

### cellSizeForBounds:

- (NSSize) cellSizeForBounds: (NSRect)aRect;
Availability: OpenStep

TODO. Currently the GNUstep implementation returns -cellSize

See Also: -cellSize

### compare:

- (NSComparisonResult) compare: (id)otherCell;
Availability: OpenStep
Compares the reciever to another to another NSCell. The argument must be an NSCell sublclass and have the NSCellType NSTextCellType. Returns the result of the comparison of each cell's stringValue.

### continueTracking: at: inView:

- (BOOL) continueTracking: (NSPoint)lastPoint at: (NSPoint)currentPoint inView: (NSView*)controlView;
Availability: OpenStep

Returns `YES`. Subclasses should overrided this method if you want stop tracking the mouse. This method is call in the -trackMouse:inRect:ofView:untilMouseUp: main loop.

See Also: -trackMouse:inRect:ofView:untilMouseUp:

### controlSize

- (NSControlSize) controlSize;
Availability: MacOS-X 10.0.0
Description forthcoming.

### controlTint

- (NSControlTint) controlTint;
Availability: MacOS-X 10.0.0
Description forthcoming.

### controlView

- (NSView*) controlView;
Availability: OpenStep

This method is used by subclasses to get the control view. This method returns `nil`.

### doubleValue

- (double) doubleValue;
Availability: OpenStep

Returns the NSCell's value as a double.

See Also: -setDoubleValue:

### drawInteriorWithFrame: inView:

- (void) drawInteriorWithFrame: (NSRect)cellFrame inView: (NSView*)controlView;
Availability: OpenStep

This drawing is minimal and with no background, to make it easier for subclass to customize drawing.

### drawWithFrame: inView:

- (void) drawWithFrame: (NSRect)cellFrame inView: (NSView*)controlView;
Availability: OpenStep

Draws the cell in controlView

### drawingRectForBounds:

- (NSRect) drawingRectForBounds: (NSRect)theRect;
Availability: OpenStep

TODO

### editWithFrame: inView: editor: delegate: event:

- (void) editWithFrame: (NSRect)aRect inView: (NSView*)controlView editor: (NSText*)textObject delegate: (id)anObject event: (NSEvent*)theEvent;
Availability: OpenStep

.This method does nothing if a the controlView is `nil`, if text object does not exist or if the cell's type is not NSTextCellType

### endEditing:

- (void) endEditing: (NSText*)textObject;
Availability: OpenStep

Ends any text editing. This method sets the text object's delegate to `nil`, and remove the NSClipView and the text object used for editing

See Also: -editWithFrame:inView:editor:delegate:event:

### entryType

- (int) entryType;
Availability: OpenStep

TODO

### floatValue

- (float) floatValue;
Availability: OpenStep

Returns the cell's value as a float.

See Also: -setFloatValue:

### focusRingType

- (NSFocusRingType) focusRingType;
Availability: Not in OpenStep/MacOS-X
Description forthcoming.

### font

- (NSFont*) font;
Availability: OpenStep

Returns the font of the text used in the NSCell

See Also: -setFont:

### formatter

- (id) formatter;
Availability: MacOS-X 10.0.0
Description forthcoming.

### getPeriodicDelay: interval:

- (void) getPeriodicDelay: (float*)delay interval: (float*)interval;
Availability: OpenStep

Gets the NSCell's delay and the interval parameters used when NSCell sends continouly action messages. The NSCell implementation sets both delay and interval to 0.1.

See Also: -trackMouse:inRect:ofView:untilMouseUp:

### hasValidObjectValue

- (BOOL) hasValidObjectValue;
Availability: OpenStep
Description forthcoming.

### highlight: withFrame: inView:

- (void) highlight: (BOOL)lit withFrame: (NSRect)cellFrame inView: (NSView*)controlView;
Availability: OpenStep

TODO explain

### highlightColorWithFrame: inView:

- (NSColor*) highlightColorWithFrame: (NSRect)cellFrame inView: (NSView*)controlView;
Availability: MacOS-X 10.0.0
Description forthcoming.

### image

- (NSImage*) image;
Availability: OpenStep

Returns the NSCell's image if the NSCell's type is NSImageCellType , returns `nil` otherwise.

See Also: -setImage: -setType: -type

### imageRectForBounds:

- (NSRect) imageRectForBounds: (NSRect)theRect;
Availability: OpenStep

The GNUstep implementation returns -drawingRectForBounds:

### importsGraphics

- (BOOL) importsGraphics;
Availability: MacOS-X 10.0.0
Description forthcoming.

### initImageCell:

- (id) initImageCell: (NSImage*)anImage;
Availability: OpenStep

Initializes and returns a new NSCell with a NSImage anImage. This method sets the image position to NSImageOnly and the cell's type to NSImageCellType .

See Also: -initTextCell:

### initTextCell:

- (id) initTextCell: (NSString*)aString;
Availability: OpenStep

Initializes and returns a new NSCell with a NSString aString. This method sets the cell's type to NSTextCellType .

See Also: -initImageCell:

### intValue

- (int) intValue;
Availability: OpenStep

Returns the cell's value as an int.

See Also: -setIntValue:

### isBezeled

- (BOOL) isBezeled;
Availability: OpenStep

Returns whether the NSCell has a bezeled border. By default a NSCell has no bezeled border

See Also: -setBezeled:

### isBordered

- (BOOL) isBordered;
Availability: OpenStep

Returns whether the NSCell has a border. By default a NSCell has border

See Also: -setBordered: -setBezeled: -isBezeled

### isContinuous

- (BOOL) isContinuous;
Availability: OpenStep

Returns whether the cell can continuously send its action messages.

See Also: -setContinuous:

### isEditable

- (BOOL) isEditable;
Availability: OpenStep

Returns whether the cell is editable.By default a NSCell is not editable.

See Also: -setEditable:

### isEnabled

- (BOOL) isEnabled;
Availability: OpenStep

Returns whether the NSCell can respond to mouse events.

See Also: -setEnabled:

### isEntryAcceptable:

- (BOOL) isEntryAcceptable: (NSString*)aString;
Availability: OpenStep
Description forthcoming.

### isHighlighted

- (BOOL) isHighlighted;
Availability: OpenStep

Returns whether the cell is highlighted. By default `NO`

See Also: -setHighlighted:

### isOpaque

- (BOOL) isOpaque;
Availability: OpenStep

Returns whether the cell is opaque. Return `NO` by default

### isScrollable

- (BOOL) isScrollable;
Availability: OpenStep

Returns whether the NSCell is scrollable. By default a NSCell is not scrollable

See Also: -setScrollable:

### isSelectable

- (BOOL) isSelectable;
Availability: OpenStep

Returns whether the cell is selectable. This method returns `YES` if the cell is selectable or editable. `NO` otherwise

See Also: -setSelectable: -isEditable -setEditable:

### keyEquivalent

- (NSString*) keyEquivalent;
Availability: OpenStep

Implemented by subclasses to returns the key equivalent. The NSCell implementation returns an empty NSString.

### lineBreakMode

- (NSLineBreakMode) lineBreakMode;
Availability: Not in OpenStep/MacOS-X
Description forthcoming.

### menu

- (NSMenu*) menu;
Availability: MacOS-X 10.0.0
Description forthcoming.

### menuForEvent: inRect: ofView:

- (NSMenu*) menuForEvent: (NSEvent*)anEvent inRect: (NSRect)cellFrame ofView: (NSView*)aView;
Availability: MacOS-X 10.0.0
Description forthcoming.

### mnemonic

- (NSString*) mnemonic;
Availability: MacOS-X 10.0.0
Description forthcoming.

### mnemonicLocation

- (unsigned int) mnemonicLocation;
Availability: MacOS-X 10.0.0
Description forthcoming.

### mouseDownFlags

- (int) mouseDownFlags;
Availability: OpenStep

Returns the mouse flags. This flags are usally sets in the -trackMouse:inRect:ofView:untilMouseUp: method

### nextState

- (int) nextState;
Availability: OpenStep
Description forthcoming.

### objectValue

- (id) objectValue;
Availability: OpenStep
Description forthcoming.

### performClick:

- (void) performClick: (id)sender;
Availability: MacOS-X 10.0.0
Simulates a single click in the cell (only works with controls which have no more than one cell). This method is deprecated, performClickWithFrame:inView: is the right method to use now.

### performClickWithFrame: inView:

- (void) performClickWithFrame: (NSRect)cellFrame inView: (NSView*)controlView;
Availability: MacOS-X 10.0.0
Simulates a single click in the cell. The display of the cell with this event occurs in the area delimited by cellFrame within controlView.

### refusesFirstResponder

- (BOOL) refusesFirstResponder;
Availability: MacOS-X 10.0.0
Description forthcoming.

### representedObject

- (id) representedObject;
Availability: OpenStep

Returns the NSCell's represented object

See Also: -setRepresentedObject:

### resetCursorRect: inView:

- (void) resetCursorRect: (NSRect)cellFrame inView: (NSView*)controlView;
Availability: OpenStep

TODO

### selectWithFrame: inView: editor: delegate: start: length:

- (void) selectWithFrame: (NSRect)aRect inView: (NSView*)controlView editor: (NSText*)textObject delegate: (id)anObject start: (int)selStart length: (int)selLength;
Availability: OpenStep

This method does nothing if the controlView is `nil`, if text object does not exist or if the cell's type is not NSTextCellType

### sendActionOn:

- (int) sendActionOn: (int)mask;
Availability: OpenStep

TODO Explain

### sendsActionOnEndEditing

- (BOOL) sendsActionOnEndEditing;
Availability: MacOS-X 10.0.0
Description forthcoming.

### setAction:

- (void) setAction: (SEL)aSelector;
Availability: OpenStep

Implemented by subclasses to set the action method. The NSCell implementation raises a NSInternalInconsistencyException

See Also: -action -setTarget: -target

### setAlignment:

- (void) setAlignment: (NSTextAlignment)mode;
Availability: OpenStep

Sets the alignment of the text. See NSTextAlignment .

See Also: -alignment

### setAllowsEditingTextAttributes:

- (void) setAllowsEditingTextAttributes: (BOOL)flag;
Availability: MacOS-X 10.0.0
Description forthcoming.

### setAllowsMixedState:

- (void) setAllowsMixedState: (BOOL)flag;
Availability: OpenStep
Description forthcoming.

### setAllowsUndo:

- (void) setAllowsUndo: (BOOL)flag;
Availability: Not in OpenStep/MacOS-X
Description forthcoming.

### setAttributedStringValue:

- (void) setAttributedStringValue: (NSAttributedString*)attribStr;
Availability: MacOS-X 10.0.0
Description forthcoming.

### setBaseWritingDirection:

- (void) setBaseWritingDirection: (NSWritingDirection)direction;
Availability: Not in OpenStep/MacOS-X
Description forthcoming.

### setBezeled:

- (void) setBezeled: (BOOL)flag;
Availability: OpenStep

Sets whether the cell has a bezeled border. If this method is called, the bordered flag is turn off. By default a NSCell has no bezeled border

See Also: -isBezeled -setBordered: -isBordered

### setBordered:

- (void) setBordered: (BOOL)flag;
Availability: OpenStep

Sets whether the cell has a border. If this method is called, the bezeled flag is turn off. By default a NSCell has no border

See Also: -isBordered -setBezeled: -isBezeled

### setCellAttribute: to:

- (void) setCellAttribute: (NSCellAttribute)aParameter to: (int)value;
Availability: OpenStep

TODO

See Also: -cellAttribute:

### setContinuous:

- (void) setContinuous: (BOOL)flag;
Availability: OpenStep

Sets whether the cell can continuously send its action messages.

See Also: -isContinuous

### setControlSize:

- (void) setControlSize: (NSControlSize)controlSize;
Availability: MacOS-X 10.0.0
Description forthcoming.

### setControlTint:

- (void) setControlTint: (NSControlTint)controlTint;
Availability: MacOS-X 10.0.0
Description forthcoming.

### setControlView:

- (void) setControlView: (NSView*)view;
Availability: Not in OpenStep/MacOS-X

This method is used by subclasses to specify the control view.

### setDoubleValue:

- (void) setDoubleValue: (double)aDouble;
Availability: OpenStep

Sets the NSCell's value to aDouble.

See Also: -doubleValue

### setEditable:

- (void) setEditable: (BOOL)flag;
Availability: OpenStep

Sets whether the NSCell's text is editable.

See Also: -isEditable -setSelectable: -isSelectable

### setEnabled:

- (void) setEnabled: (BOOL)flag;
Availability: OpenStep

Sets whether the NSCell can respond to mouse events

See Also: -isEnabled

### setEntryType:

- (void) setEntryType: (int)aType;
Availability: OpenStep

TODO

### setFloatValue:

- (void) setFloatValue: (float)aFloat;
Availability: OpenStep

Sets the NSCell's value to a aFloat. This used for example in NSSliderCell

See Also: -floatValue

### setFloatingPointFormat: left: right:

- (void) setFloatingPointFormat: (BOOL)autoRange left: (unsigned int)leftDigits right: (unsigned int)rightDigits;
Availability: OpenStep
Description forthcoming.

### setFocusRingType:

- (void) setFocusRingType: (NSFocusRingType)type;
Availability: Not in OpenStep/MacOS-X
Description forthcoming.

### setFont:

- (void) setFont: (NSFont*)fontObject;
Availability: OpenStep

Sets the text font. The NSCell's type is set to NSTextCellType if needed

See Also: -font -setType: -type

### setFormatter:

- (void) setFormatter: (NSFormatter*)newFormatter;
Availability: MacOS-X 10.0.0
Description forthcoming.

### setHighlighted:

- (void) setHighlighted: (BOOL)flag;
Availability: MacOS-X 10.0.0

Sets whether the NSCell is highlighted.

See Also: -isHighlighted

### setImage:

- (void) setImage: (NSImage*)anImage;
Availability: OpenStep

Sets the NSCell's image to anImage. This method sets the cell's type to NSImageCellType if needed. Raises an NSInvalidArgumentException if the anImage is not an NSImage (sub)class. The new image is retained and the old one is released

See Also: -image

### setImportsGraphics:

- (void) setImportsGraphics: (BOOL)flag;
Availability: MacOS-X 10.0.0
Description forthcoming.

### setIntValue:

- (void) setIntValue: (int)anInt;
Availability: OpenStep

Sets the NSCell's value to anInt.

See Also: -intValue

### setLineBreakMode:

- (void) setLineBreakMode: (NSLineBreakMode)mode;
Availability: Not in OpenStep/MacOS-X
Description forthcoming.

### setMenu:

- (void) setMenu: (NSMenu*)aMenu;
Availability: MacOS-X 10.0.0
Description forthcoming.

### setMnemonicLocation:

- (void) setMnemonicLocation: (unsigned int)location;
Availability: MacOS-X 10.0.0
Description forthcoming.

### setNextState

- (void) setNextState;
Availability: OpenStep
Description forthcoming.

### setObjectValue:

- (void) setObjectValue: (id)object;
Availability: OpenStep
Description forthcoming.

### setRefusesFirstResponder:

- (void) setRefusesFirstResponder: (BOOL)flag;
Availability: MacOS-X 10.0.0
Description forthcoming.

### setRepresentedObject:

- (void) setRepresentedObject: (id)anObject;
Availability: OpenStep

Sets the NSCell's represented object to anObject. anObject will be retain.

See Also: -representedObject

### setScrollable:

- (void) setScrollable: (BOOL)flag;
Availability: OpenStep

Sets whether the NCell is scrollable. By default a NSCell is not scrollable

See Also: -isSelectable

### setSelectable:

- (void) setSelectable: (BOOL)flag;
Availability: OpenStep

Sets whether the cell selectable. Making a cell unselectable also makes it uneditable until a -setEditable: re-enables it.

See Also: -isSelectable -setEditable: -isEditable

### setSendsActionOnEndEditing:

- (void) setSendsActionOnEndEditing: (BOOL)flag;
Availability: MacOS-X 10.0.0
Description forthcoming.

### setShowsFirstResponder:

- (void) setShowsFirstResponder: (BOOL)flag;
Availability: MacOS-X 10.0.0
Description forthcoming.

### setState:

- (void) setState: (int)value;
Availability: OpenStep

Sets the NSCell's state. Please use always symbolic constants when calling this method. The integer values could be changed in the this implementation. (Currently they match the Cocoa values but they are quite strange)

See Also: -state

### setStringValue:

- (void) setStringValue: (NSString*)aString;
Availability: OpenStep

Sets the cell's value to a NSString. The NSCell's type is set to NSTextCellType if needed

See Also: -stringValue

### setTag:

- (void) setTag: (int)anInt;
Availability: OpenStep

Implemented by sublclasses to assigns the tag anInt. The NSCell implementation raises an NSInvalidArgumentException.

See Also: -tag

### setTarget:

- (void) setTarget: (id)anObject;
Availability: OpenStep

Implemented by subclasses to set the target object. The NSCell implementation raises a NSInternalInconsistencyException

See Also: -target -setAction: -action

### setTitle:

- (void) setTitle: (NSString*)aString;
Availability: MacOS-X 10.0.0
Description forthcoming.

### setTitleWithMnemonic:

- (void) setTitleWithMnemonic: (NSString*)aString;
Availability: MacOS-X 10.0.0
Description forthcoming.

### setType:

- (void) setType: (NSCellType)aType;
Availability: OpenStep

Sets the NSCell's type. See NSCellType .If the cell is set to NSTextCellType, the cell is given a default title and is reset to the default system font.

See Also: -type

### setUpFieldEditorAttributes:

- (NSText*) setUpFieldEditorAttributes: (NSText*)textObject;
Availability: OpenStep
Description forthcoming.

### setWraps:

- (void) setWraps: (BOOL)flag;
Availability: OpenStep
Description forthcoming.

### showsFirstResponder

- (BOOL) showsFirstResponder;
Availability: MacOS-X 10.0.0
Description forthcoming.

### startTrackingAt: inView:

- (BOOL) startTrackingAt: (NSPoint)startPoint inView: (NSView*)controlView;
Availability: OpenStep

Returns whether tracking starts. The NSCell implementation returns `YES` when the startPoint is into the control view retangle, `NO` otherwise. This method is call at the early stage of -trackMouse:inRect:ofView:untilMouseUp:

See Also: [NSView -mouse:inRect:] -trackMouse:inRect:ofView:untilMouseUp:

### state

- (int) state;
Availability: OpenStep

Returns the NSCell's state

See Also: -setState:

### stopTracking: at: inView: mouseIsUp:

- (void) stopTracking: (NSPoint)lastPoint at: (NSPoint)stopPoint inView: (NSView*)controlView mouseIsUp: (BOOL)flag;
Availability: OpenStep

TODO

### stringValue

- (NSString*) stringValue;
Availability: OpenStep

Returns the cell's value as a NSString.

See Also: -setStringValue:

### tag

- (int) tag;
Availability: OpenStep

Implemented by subclasses to Return the tag. The NSCell implementation returns -1

See Also: -setTag:

### takeDoubleValueFrom:

- (void) takeDoubleValueFrom: (id)sender;
Availability: OpenStep

Sets the NSCell's double value to sender's double value

See Also: -setDoubleValue:

### takeFloatValueFrom:

- (void) takeFloatValueFrom: (id)sender;
Availability: OpenStep

Sets the NSCell's float value to sender's float value

See Also: -setFloatValue:

### takeIntValueFrom:

- (void) takeIntValueFrom: (id)sender;
Availability: OpenStep

Sets the NSCell's int value to sender's int value

See Also: -setIntValue:

### takeObjectValueFrom:

- (void) takeObjectValueFrom: (id)sender;
Availability: OpenStep
Description forthcoming.

### takeStringValueFrom:

- (void) takeStringValueFrom: (id)sender;
Availability: OpenStep

Sets the NSCell's NSString value to sender's NSSting value

See Also: -setStringValue:

### target

- (id) target;
Availability: OpenStep

Implemented by subclass to return the target object. The NSCell implementation returns `nil`

See Also: -setTarget: -setAction: -action

### title

- (NSString*) title;
Availability: MacOS-X 10.0.0
Description forthcoming.

### titleRectForBounds:

- (NSRect) titleRectForBounds: (NSRect)theRect;
Availability: OpenStep

TODO

### trackMouse: inRect: ofView: untilMouseUp:

- (BOOL) trackMouse: (NSEvent*)theEvent inRect: (NSRect)cellFrame ofView: (NSView*)controlView untilMouseUp: (BOOL)flag;
Availability: OpenStep
Description forthcoming.

### type

- (NSCellType) type;
Availability: OpenStep

Returns the cell's type. Returns NSNullCellType if the cell's type flag is set to NSImageCellType and if the cell's image is `nil`. See NSCellType for more information.

See Also -setType:

### wraps

- (BOOL) wraps;
Availability: OpenStep
Description forthcoming.

## Instance Variables for NSCell Class

### _action_mask

@protected unsigned int _action_mask;
Availability: OpenStep
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.

### _cell

@protected struct GSCellFlagsType _cell;
Availability: OpenStep
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.

### _cell_image

@protected NSImage* _cell_image;
Availability: OpenStep
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.

### _contents

@protected NSString* _contents;
Availability: OpenStep
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.

### _font

@protected NSFont* _font;
Availability: OpenStep
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.

### _formatter

@protected NSFormatter* _formatter;
Availability: OpenStep
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.

### _menu

@protected NSMenu* _menu;
Availability: OpenStep
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.

### _mouse_down_flags

@protected unsigned int _mouse_down_flags;
Availability: OpenStep
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.

### _object_value

@protected id _object_value;
Availability: OpenStep
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.

### _represented_object

@protected id _represented_object;
Availability: OpenStep
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.

### _reserved1

@protected void* _reserved1;
Availability: OpenStep
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.

# Software documentation for the NSCell(PrivateMethods) category

## NSCell(PrivateMethods)

> Declared in:
>   AppKit/NSCell.h

Availability: OpenStep
Warning this category is private, which means that the methods are for internal use by the package. You should not use them in external code.
Method summary

- -_drawAttributedString
- -_drawAttributedText:inFrame:
- -_drawBorderAndBackgroundWithFrame:inView:
- -_drawFocusRingWithFrame:inView:
- -_drawText:inFrame:
- -_nonAutoreleasedTypingAttributes
- -_sendsActionOn:
- -_sizeText:
- -textColor

### _drawAttributedString

- (NSAttributedString*) _drawAttributedString;
Availability: OpenStep
Warning the underscore at the start of the name of this method indicates that it is private, for internal use only, and you should not use the method in your code.
Private internal method, returns an attributed string to display.

### _drawAttributedText: inFrame:

- (void) _drawAttributedText: (NSAttributedString*)aString inFrame: (NSRect)aRect;
Availability: OpenStep
Warning the underscore at the start of the name of this method indicates that it is private, for internal use only, and you should not use the method in your code.
Private internal method to display an attributed string.
Important: text should always be vertically centered without considering descender [as if descender did not exist]. This is particularly important for single line texts. Please make sure the output remains always correct.

### _drawBorderAndBackgroundWithFrame: inView:

- (void) _drawBorderAndBackgroundWithFrame: (NSRect)cellFrame inView: (NSView*)controlView;
Availability: OpenStep
Warning the underscore at the start of the name of this method indicates that it is private, for internal use only, and you should not use the method in your code.

### _drawFocusRingWithFrame: inView:

- (void) _drawFocusRingWithFrame: (NSRect)cellFrame inView: (NSView*)controlView;
Availability: OpenStep
Warning the underscore at the start of the name of this method indicates that it is private, for internal use only, and you should not use the method in your code.

### _drawText: inFrame:

- (void) _drawText: (NSString*)aString inFrame: (NSRect)cellFrame;
Availability: OpenStep
Warning the underscore at the start of the name of this method indicates that it is private, for internal use only, and you should not use the method in your code.
Important: text should always be vertically centered without considering descender [as if descender did not exist]. This is particularly important for single line texts. Please make sure the output remains always correct.

### _nonAutoreleasedTypingAttributes

- (NSDictionary*) _nonAutoreleasedTypingAttributes;
Availability: OpenStep
Warning the underscore at the start of the name of this method indicates that it is private, for internal use only, and you should not use the method in your code.

### _sendsActionOn:

- (BOOL) _sendsActionOn: (int)eventTypeMask;
Availability: OpenStep
Warning the underscore at the start of the name of this method indicates that it is private, for internal use only, and you should not use the method in your code.

### _sizeText:

- (NSSize) _sizeText: (NSString*)title;
Availability: OpenStep
Warning the underscore at the start of the name of this method indicates that it is private, for internal use only, and you should not use the method in your code.

### textColor

- (NSColor*) textColor;
Availability: OpenStep
Description forthcoming.

Up