• 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: Does NSImage handle Icns Files?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Does NSImage handle Icns Files?


  • Subject: Re: Does NSImage handle Icns Files?
  • From: Seth Willits <email@hidden>
  • Date: Tue, 17 Jan 2006 15:22:33 -0800

On Jan 17, 2006, at 2:48 PM, Seth Willits wrote:

I'm trying just to get an image of my document's icon inside my app, and I though [NSImage imageNamed:@"DocumentIcon"] might work, and although it returns something, when drawing in a view, it doesn't draw anything recognizable as part of the icon. (I actually just see a gradient shadowy kind of thing on the right side of where it should be drawing.)

Does NSImage handle icns files? How else can I get the icon for my document? (NSWorkspace's iconForFileType won't work because the file type isn't unique to my application.)

It turns out the value to setSize: wasn't an exact size of one of the representations and that was causing it to do some funky stuff. Weirdly enough though, that same size value worked for icons retrieved via NSWorkspace's iconForFile:.




--
Seth Willits
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >Does NSImage handle Icns Files? (From: Seth Willits <email@hidden>)

  • Prev by Date: Re: Translucent black window
  • Next by Date: Re: Cocoa AppleScript question
  • Previous by thread: Does NSImage handle Icns Files?
  • Next by thread: creating a draw window
  • Index(es):
    • Date
    • Thread