<!--
{
  "availability" : [
    "macOS: 10.5.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "AppKit",
  "identifier" : "/documentation/AppKit/NSTableViewDelegate/tableView(_:shouldShowCellExpansionFor:row:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "AppKit"
    ],
    "preciseIdentifier" : "c:objc(pl)NSTableViewDelegate(im)tableView:shouldShowCellExpansionForTableColumn:row:"
  },
  "title" : "tableView(_:shouldShowCellExpansionFor:row:)"
}
-->

# tableView(_:shouldShowCellExpansionFor:row:)

Asks the delegate if an expansion tooltip should be displayed for a specific row and column.

```
@MainActor optional func tableView(_ tableView: NSTableView, shouldShowCellExpansionFor tableColumn: NSTableColumn?, row: Int) -> Bool
```

## Parameters

`tableView`

The table view that sent the message.

`tableColumn`

The table column.

`row`

The row index.

## Return Value

<doc://com.apple.documentation/documentation/Swift/true> if an expansion tooltip should be displayed, <doc://com.apple.documentation/documentation/Swift/false> otherwise.

## Discussion

An expansion tooltip can be displayed when the pointer hovers over a cell that contains truncated text. When this method returns <doc://com.apple.documentation/documentation/Swift/true>, the cell’s full contents is shown in an expansion tooltip, which looks similar to a help tag.

> Note:
> This method is only valid for ``doc://com.apple.appkit/documentation/AppKit/NSCell``-based table views.

---

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)