• 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
Re: File Icon
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: File Icon


  • Subject: Re: File Icon
  • From: Joshua Clements <email@hidden>
  • Date: Tue, 6 Nov 2001 00:53:36 -0500

Thanks Finlay, for the pointer to NSWorkspace.
I've got that returning me an icon but it doesn't look
so hot at 16x16. I'm assuming that NSWorkspace is
returning me the 32x32 icon and the NSImageCell is
scaling it down to 16x16. Is there a way to get load the 16x16 icon?


On Sunday, November 4, 2001, at 02:56 PM, Finlay Dobbie wrote:


On Sunday, November 4, 2001, at 07:45 pm, Joshua Clements wrote:

Anyone know how to get the icon associated with a file that can be used in Cocoa?

RTFM NSWorkspace.

I have located a function in Carbon "GetIconRefFromFile" which returns an IconRef.
Is that IconRef usable in Cocoa for displaying on the screen?

Yes, indirectly, but you should probably use the NSWorkspace method.

-- Finlay


  • Follow-Ups:
    • Re: File Icon
      • From: Chuck Norris <email@hidden>
    • Re: File Icon
      • From: Sam Goldman <email@hidden>
References: 
 >Re: File Icon (From: Finlay Dobbie <email@hidden>)

  • Prev by Date: dynamic NSPopUpButton
  • Next by Date: Re: File Icon
  • Previous by thread: Re: File Icon
  • Next by thread: Re: File Icon
  • Index(es):
    • Date
    • Thread