<!--
{
  "availability" : [
    "macOS: -"
  ],
  "documentType" : "symbol",
  "framework" : "AppKit",
  "identifier" : "/documentation/AppKit/NSTokenFieldCell",
  "metadataVersion" : "0.1.0",
  "role" : "Class",
  "symbol" : {
    "kind" : "Class",
    "modules" : [
      "AppKit"
    ],
    "preciseIdentifier" : "c:objc(cs)NSTokenFieldCell"
  },
  "title" : "NSTokenFieldCell"
}
-->

# NSTokenFieldCell

A text field cell subclass that enables tokenized editing of an array of objects.

```
class NSTokenFieldCell
```

## Overview

[`NSTokenFieldCell`](/documentation/AppKit/NSTokenFieldCell) is a subclass of [`NSTextFieldCell`](/documentation/AppKit/NSTextFieldCell) that provides tokenized editing of an array of objects similar to the address field in the Mail app. The objects may be strings or objects that can be represented as strings. A single token field cell can be presented in an [`NSTokenField`](/documentation/AppKit/NSTokenField) control.

## Topics

### Managing the Token Style

[`tokenStyle`](/documentation/AppKit/NSTokenFieldCell/tokenStyle)

The token style of the receiver.

### Managing the Tokenizing Character Set

[`defaultTokenizingCharacterSet`](/documentation/AppKit/NSTokenFieldCell/defaultTokenizingCharacterSet)

Returns the default tokenizing character set.

[`tokenizingCharacterSet`](/documentation/AppKit/NSTokenFieldCell/tokenizingCharacterSet)

The receiver’s tokenizing character set to a given character set.

### Configuring the Completion Delay

[`completionDelay`](/documentation/AppKit/NSTokenFieldCell/completionDelay)

The receiver’s completion delay to a given delay.

[`defaultCompletionDelay`](/documentation/AppKit/NSTokenFieldCell/defaultCompletionDelay)

Returns the default completion delay.

### Managing the Delegate

[`delegate`](/documentation/AppKit/NSTokenFieldCell/delegate)

The receiver’s delegate.

### Constants

[`TokenStyle`](/documentation/AppKit/NSTokenField/TokenStyle-swift.enum)

The NSTokenStyle constants define how tokens are displayed and editable in the `NSTokenFieldCell`. These values are used by [`tokenStyle`](/documentation/AppKit/NSTokenFieldCell/tokenStyle) and the delegate method [`tokenFieldCell(_:styleForRepresentedObject:)`](/documentation/AppKit/NSTokenFieldCellDelegate/tokenFieldCell(_:styleForRepresentedObject:)).

## Relationships

### Conforms To

[`Sendable`](/documentation/Swift/Sendable)

[`NSAccessibilityProtocol`](/documentation/AppKit/NSAccessibilityProtocol)

[`NSCoding`](/documentation/Foundation/NSCoding)

[`CVarArg`](/documentation/Swift/CVarArg)

[`NSUserInterfaceItemIdentification`](/documentation/AppKit/NSUserInterfaceItemIdentification)

[`NSAccessibilityElementProtocol`](/documentation/AppKit/NSAccessibilityElementProtocol)

[`CustomDebugStringConvertible`](/documentation/Swift/CustomDebugStringConvertible)

[`Hashable`](/documentation/Swift/Hashable)

[`NSObjectProtocol`](/documentation/ObjectiveC/NSObjectProtocol)

[`NSCopying`](/documentation/Foundation/NSCopying)

[`CustomStringConvertible`](/documentation/Swift/CustomStringConvertible)

[`Equatable`](/documentation/Swift/Equatable)

[`SendableMetatype`](/documentation/Swift/SendableMetatype)

### Inherits From

[`NSTextFieldCell`](/documentation/AppKit/NSTextFieldCell)

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)