Re: Alternative to NSWorkspace iconForFileType for icons?
Re: Alternative to NSWorkspace iconForFileType for icons?
- Subject: Re: Alternative to NSWorkspace iconForFileType for icons?
- From: Ken Thomases <email@hidden>
- Date: Tue, 24 Feb 2009 21:32:48 -0600
On Feb 24, 2009, at 5:57 PM, Kevin Walzer wrote:
As I read it, the iconForFileType and related methods form
NSWorkspace returns an NSImage. I don't want an NSImage. I want the
path to the 'icns' file that the iconForFileType NSImage is based on.
What makes you think that all icons come from free-standing icns files?
Am I missing something in Cocoa here? Can anyone suggest an
alternative API/class/method to me?
I don't believe the API you're looking for exists. My first thought
was to check Launch Services, but the icon-related stuff in there is
documented as no longer being used. After that, I checked Icon
Services. There are functions there to obtain an IconRef for a given
item in the file system, but there doesn't appear to be a way to
obtain a reference to the file that that icon comes from, if there is
even such a file.
Regards,
Ken
_______________________________________________
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