0

I created three different versions of one Mac icon in Sketch ranging from least detailed (small version) for 16x16 to most detailed (large version) at 512x512. The plugin I use in Sketch exports an artboard into an icns file that include all the necessary resolutions for implementation. This is helpful because implementation of Mac icons only allow for one file. However, I want to be able to use the small version of the design for 16x16/@2x, 32x32/@2x; the medium version for 128x128/@2x; and the large version for 512x512/@2x. But I'm finding it hard/have no resources for combining all of those versions into one icns file.

I find it pretty disheartening since the HIG recommends designing less detailed versions of the same design for smaller resolutions from what I understand.

Does anyone have any advice, resources or workaround? Thanks!

1 Answer 1

2

I have no idea about Sketch (I don't use it), but you can create the ICNS file from the Terminal...

Put all your icons in a folder with nothing but the individual image files. The images should all be named with the convention:

icon_<sizeinpoints>x<sizeinpoints>[@<scale>].png

The folder can be called whatever you like but has to have the .iconset extension (it's weird for a folder to have an extension, yes, but that's how the system knows it's an icon set).

So your folder should look something like:

MyIcons.iconset
|- icon_16x16.png
|- [email protected]
|- icon_32x32.png
|- [email protected]
|- icon_128x128.png
|- [email protected]
|- icon_512x512.png
|- [email protected]

Then from Terminal, run iconutil with the command...

iconutil -c icns <iconset filename>

Where <iconset filename> is the path to the iconset folder (Tip: you can drag the folder from Finder to the terminal and it will paste the correct path).

That will create the ICNS file for you with the same name and in the same location as the iconset folder you created it from.

You can read more here:

2
  • Hah! I actually came across this solution a split second before you answered. Very helpful - thank you! Here's what I referenced: stackoverflow.com/questions/12306223/…
    – wendy
    May 1, 2017 at 20:26
  • No worries, glad you found a solution!
    – Cai
    May 1, 2017 at 20:30

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.