• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
NSOutlineView with NSImage and NSStrings
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSOutlineView with NSImage and NSStrings


  • Subject: NSOutlineView with NSImage and NSStrings
  • From: iseecolors <email@hidden>
  • Date: Mon, 4 May 2009 10:56:44 -0700

I would like to have an image and a string together in my NSOutlineView, but it is not clear to me how to do this. Basically I want to do what iTunes appears to do (icons in front of the text descriptors).

My initial thought was to return and NSArray that contains and NSImage and NSString from the method:

- (id)outlineView:(NSOutlineView *)outlineView objectValueForTableColumn:(NSTableColumn *)tableColumn byItem:(id)item

But apparently the returned id is just converted to an NSString. (if it only deals with strings, why support id?)

Is there support for this built in to do this, or will I need to subclass NSOutlineView and override the drawRect method?

Rich Collyer
_______________________________________________

Cocoa-dev mailing list (email@hidden)

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:
This email sent to email@hidden


  • Prev by Date: Programmatically Changing Display(s) to Greyscale
  • Next by Date: Re: Cocoa Drawing
  • Previous by thread: Re: NSOutlineView with NSImage and NSStrings
  • Next by thread: Discussion on how to draw text like that seen in toolbars
  • Index(es):
    • Date
    • Thread