NSOutlineView and NSTreeController

View nested lists easily!

NSOutlineView is a subclass of NSTableView that provides a way to display hierarchical data. For example, file hierarchies (though, you’d actually use an NSBrowser object for a file hierarchy).

NSTreeController is a controller that works with NSOutlineView and NSBrowser to manage the data that they display.

In cocoa, controllers are super powerful because they allow you to bypass implementing a lot of the really boring delegate/datasource stuff that you’re forced to do in iOS.

Bindings

This is a much better explanation of how to set up bindings correctly than I’m currently able to do.

Delegate Methods

Tooltips

Implement outlineView(_:tooltipFor:rect:tableColumn:item:mouseLocation).

Last updated: 2020-06-07 16:24:37 -0700