does anyone know how to access different formats of an icns file?
For example this file contains multiple sizes of the same icon:

In some cases I just want the large one and in other cases I want the small one.
I couldn’t find something in Cocoa.
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
An
NSImageis a container forNSImageReps. When you load an icns file, you get an image containing anNSBitmapImageRepfor each size in the file. You can iterate over the image’srepresentationsproperty to access them. (Also, the image will automatically choose the most appropriate rep when drawing.)