Instance Method

outlineView:heightOfRowByItem:

Returns the height in points of the row containing item.

Declaration

- (CGFloat)outlineView:(NSOutlineView *)outlineView heightOfRowByItem:(id)item;

Parameters

outlineView

The outline view that sent the message.

item

The row item.

Return Value

The height of the row.

Discussion

Values returned by this method should not include intercell spacing and must be greater than 0.

Implement this method to support an outline view with varying row heights.

For large tables in particular, you should make sure that this method is efficient. NSOutlineView may cache the values this method returns, so if you would like to change a row's height make sure to invalidate the row height by calling noteHeightOfRowsWithIndexesChanged:. NSOutlineView automatically invalidates its entire row height cache in reloadData and noteNumberOfRowsChanged.

If you call viewAtColumn:row:makeIfNecessary: or rowViewAtRow:makeIfNecessary: within your implementation of this method, an exception is thrown.

See Also

Customizing Column and Row Sizes

- outlineView:sizeToFitWidthOfColumn:

Invoked to allow the delegate to provide custom sizing behavior when a column’s resize divider is double clicked.