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

# NSTableCellView

A reusable container view shown for a particular cell in a table view that uses rows for content.

```
class NSTableCellView
```

## Overview

The [`imageView`](/documentation/AppKit/NSTableCellView/imageView) and [`textField`](/documentation/AppKit/NSTableCellView/textField) properties are connected in Interface Builder. Additional properties can be added by subclassing [`NSTableCellView`](/documentation/AppKit/NSTableCellView) and adding the required properties and connecting them programmatically or in Interface Builder.

The `objectValue` is used when setting the value of the view cell by the [`tableView(_:objectValueFor:row:)`](/documentation/AppKit/NSTableViewDataSource/tableView(_:objectValueFor:row:)) method in the [`NSTableViewDataSource`](/documentation/AppKit/NSTableViewDataSource). If you use your own custom view cells that are not based on [`NSTableCellView`](/documentation/AppKit/NSTableCellView) you should implement this property in order to be able to receive changes to cell values.

## Topics

### Represented Object

[`objectValue`](/documentation/AppKit/NSTableCellView/objectValue)

The object that represents the cell data.

### Displayed Items

[`imageView`](/documentation/AppKit/NSTableCellView/imageView)

Image displayed by the cell.

[`textField`](/documentation/AppKit/NSTableCellView/textField)

Text displayed by the cell.

### Getting and Setting the Background Style

[`backgroundStyle`](/documentation/AppKit/NSTableCellView/backgroundStyle)

This property is automatically set by the enclosing row view to let this view know what its background looks like.

### Getting and Setting the Row Size Style

[`rowSizeStyle`](/documentation/AppKit/NSTableCellView/rowSizeStyle)

Returns the row size style.

### Dragging Images

[`draggingImageComponents`](/documentation/AppKit/NSTableCellView/draggingImageComponents)

Returns dragging images for the cell.



---

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)