On 20/02/2013, at 12:10 PM, Chuck Soper <chu...@veladg.com> wrote: > Thanks for your very thorough response. It sounds possible, but quite > labor intensive. So much so, that I think that I should not be using > NSTableView. I was using NSTableView, with one row, as way to horizontally > scroll custom views. To auto adjust the height of the single row I added > an observer for NSViewFrameDidChangeNotification on the NSTableView > object. Then called setRowHeight: to > scrollView.documentVisibleRect.size.height as the table was resized. > > This was pretty fast to implement and worked fine. I think that this could > have been a good way to make use of a table view except for needing to > customize the headerCell and implement custom column dragging. I think > that I'll just use an NSScrollView and avoid customizing NSTableView.
Yeah, sounds to me like you're gaining next to nothing from NSTableView. Just implement the whole thing as a custom view containing other custom views (of a different or the same kind). In fact, I just did that for something almost identical except it's vertical rather than horizontal. I implemented drag and drop reordering in almost exactly the way I described and there wasn't too much to it - I even have the animation working nicely where an appropriate gap opens up to accommodate the dropped item. The main thing I ran into there was that using Core Animation (via [NSView animator]) to change frame origins and sizes was more troublesome than doing my own animations. Unfortunately I can't share as a) it's commercial code and b) it's probably too rough for public consumption. --Graham _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com