---
title: "outlineView(_:shouldShowCellExpansionFor:item:)"
framework: appkit
role: symbol
role_heading: Instance Method
path: "appkit/nsoutlineviewdelegate/outlineview(_:shouldshowcellexpansionfor:item:)"
---

# outlineView(_:shouldShowCellExpansionFor:item:)

Invoked to allow the delegate to control cell expansion for a specific column and item.

## Declaration

```swift
@MainActor optional func outlineView(_ outlineView: NSOutlineView, shouldShowCellExpansionFor tableColumn: NSTableColumn?, item: Any) -> Bool
```

## Parameters

- `outlineView`: The outline view that sent the message.
- `tableColumn`: A table column in the outline view.
- `item`: An item in the outline view.

## Return Value

Return Value true to allow an expansion tooltip to appear in the column tableColumn for item item, otherwise false.

## Discussion

Discussion Cell expansion can occur when the mouse hovers over the specified cell and the cell contents are unable to be fully displayed within the cell. If this method returns true, the full cell contents will be shown in a special floating tool tip view, otherwise the content is truncated.

## See Also

### Displaying Cells

- [outlineView(_:willDisplayCell:for:item:)](appkit/nsoutlineviewdelegate/outlineview(_:willdisplaycell:for:item:).md)
- [outlineView(_:willDisplayOutlineCell:for:item:)](appkit/nsoutlineviewdelegate/outlineview(_:willdisplayoutlinecell:for:item:).md)
- [outlineView(_:dataCellFor:item:)](appkit/nsoutlineviewdelegate/outlineview(_:datacellfor:item:).md)
- [outlineView(_:shouldShowOutlineCellForItem:)](appkit/nsoutlineviewdelegate/outlineview(_:shouldshowoutlinecellforitem:).md)
