Thank you for the article. -Michael
On Jan 15, 2010, at 12:54 PM, Arun wrote: > You can find a beautiful article on the same @ > http://www.martinkahr.com/2007/05/04/nscell-image-and-text-sample/ > > HTH > -Arun KA > > On Fri, Jan 15, 2010 at 11:20 PM, Michael A. Crawford > <michaelacrawf...@me.com> wrote: > Consider an NSTableView instance populated with data from an > NSArrayController, which is bound to a content array containing instances of > class foo. All of class foo's properties return BOOL and NSString values. > The two BOOL values need to be shown in the table using icon images. > > Should the images be properties of class foo, which are bound by the > array-controller, in order for them to show up in the table? > > Normally, when not using NSArrayController, I would make my controller the > data-source for the table. When the > -[tableView:objectValueForTableColumn:row:] method is called for the BOOL > columns, I would return an NSImageCell. I was assuming that I cannot do this > while using bindings and the NSArrayController. However, when I coded it up, > I got the callbacks even though the table was bound to the array-controller > > Is this the correct way to do this? I'm worried that using both the > DataSource callbacks and bindings to an array-controller might not be what > Apple had in mind and will lead to unforeseen issues. > > Is there a better way? > > -Michael > _______________________________________________ > > 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: > http://lists.apple.com/mailman/options/cocoa-dev/arun.ka%40gmail.com > > This email sent to arun...@gmail.com > _______________________________________________ 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: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com