TUAW Tutorial: Custom Stack Drawer icons

Mat Lu
M. Lu|11.16.07

Sponsored Links

Mat Lu
November 16th, 2007
In this article: custom, ICNS, icon, icons, Stacks
TUAW Tutorial: Custom Stack Drawer icons

Many folks commented on our recent post about adding those gorgeous drawer icons to your Stacks. As great as the originals are, however, a lot of you also wanted to know how to customize them. Fortunately, the original author was kind enough to make the blank drawer PNG available, so in this little tutorial I'll show you how to make your own customized drawer icons using nothing more than Preview. Obviously you can get much sophisticated results using a more serious image editing application, but Preview can do enough to get you the results you see above and since everyone has it, I thought it best to focus on using it despite its limitations.

Step 1 Grab the 512x512 blank drawer image from the original author and save it somewhere (or right-click and save it from here). That will get you this (this version is resized down so don't use it, use the original):

Step 2 Get another image that you want to overlay onto the drawer. I'm naturally enough going to use the TUAW logo. Now I want my custom drawer to look something like the originals, so that means we're going to need to extract the image from its background. Fortunately, one of the great new features of Preview is "Instant Alpha." I selected the white background with the Instant Alpha tool (from the drop-down menu of the selection tool), being sure to get all the interiors as well. Then when I hit return and the background disappears like magic!

Step 3 (optional): Since I'm trying to remain consistent with the original drawers I decided to make the TUAW logo black, rather than leaving it blue and green. One of the easiest ways to do this is open up the Adjust Color panel and push the White and Black levels all the way over to the right and the saturation all the way over to the left. Of course you can also play with these to get whatever effect you want. Naturally, if you were doing this in a more sophisticated image editor you could add gradients, etc. Once you're finished, copy the image to the clipboard.

Step 4 Using Preview open the blank drawer PNG you got in step one. Paste the image from step 3 onto it, move it around until you get it where you want it, and and then save it.

Step 5 Still in Preview, copy the image to the clipboard. In the FInder, select the folder you want to change the icon of and Get Info (⌘-I). Select the folder icon at the top left of the Get Info pane and paste in your custom graphic. Voilà, you're done!

Step 6 (optional): You can also convert your custom icon into a standard ICNS file using the Icon Composer from the Developer Tools. If you haven't already you'll need to install those from the optional installs folder of your Leopard disc. Once you do so Icon Composer can be found at /Developer/Applications/Utilities. The Icon Composer lets you drop in a 512 x 512 image and automatically convert it to an IconsFileStore file. You can then export it to an ICNS file.

All products recommended by Engadget are selected by our editorial team, independent of our parent company. Some of our stories include affiliate links. If you buy something through one of these links, we may earn an affiliate commission.
Popular on Engadget