- (NSSize)contentSize
in Appkit
returns the size of the NSClipView
, and not the height of the content that scrolls inside the table view. I don't know how UIScrollView
s work, but on OS X, an NSScrollView
has a "content view" (more aptly named the NSClipView
) that clips the actual content, which is provided by a document view (scrollable if it has a size larger than that of the clip view) that is a subview of the clip view.
As a side note, the NSScrollView
scrolls by setting the document view's bounds origin (to the best of my knowledge).
It looks like what you want is the height of the document view, the height of the actual content. For that, try something like
scrollView.documentView.frame.size.height