Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I've noticed that some system directories, when dragged to the Finder's sidebar, utilize special small-scale icons not visible in any other place. Even when looking at one of these folders in a Finder window using the smallest possible icon size, these "special" icons don't appear (so it's not just the small version of the folder's icon).

So my question is, where is this information stored? If I wanted to duplicate this behavior for an arbitrary folder, where would I need to look?

I like to replace my home directory with a symlink to a location on another partition, but when I do this, I lose this sidebar icon behavior. I would love to get this back if I can.

share|improve this question
    
Odd, when I change an icon in the sidebar the usual way, the icon of the target folder is changed the very same way as well. –  Arjan Sep 12 '10 at 19:51

1 Answer 1

up vote 2 down vote accepted

It's not possible to do this yourself. These special sidebar icons are hard-coded to use files whose names start with Toolbar in /System/Library/CoreServices/CoreTypes.bundle/Contents/Resources/, such as ToolbarDownloadsFolderIcon.icns for the Downloads folder. If placed in the sidebar, this file is used instead of the folder's actual icon, which is DownloadsFolder.icns in the same directory by default.

This is why icon changing applications such as Panic's CandyBar only provide the default selection of sidebar folder icons to change.

You can get close though.


Use Icon Composer in Apple's developer tools to create an icns file with different versions for the varying sizes.

Use icns2rsrc (Rosetta needed) to convert your icns file into a rsrc file.

When you copy its icon from Finder's Get Info dialog and paste it onto a folder, the different icon versions for different sizes are preserved.

  • 16x16 is used by Finder sidebar and small list icons
  • 32x32 is used by Get Info dialog and big list icons
  • 256x256 is used by QuickLook
  • All of the sizes are used by Finder's icon view, depending on the icon size. Larger icon size is used starting at 20, 36, 132 and 260 pixels, as you'd expect.
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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