Re: Set Document Icon from the Command Line
Re: Set Document Icon from the Command Line
- Subject: Re: Set Document Icon from the Command Line
- From: Brian Ray <email@hidden>
- Date: Wed, 11 Apr 2007 11:03:13 -0500
On Apr 11, 2007, at 10:43 AM, Ken Mankoff wrote:
Is there a way to set the document icon from the command line? I am
able to set a folder icon by copying the "Icon^M" file into the
directory, but have not found a way to do this for a file/document.
I know about the 'hidden' rsrc/ sub-folder attached to every file,
and am comfortable using the Rez and DeRez CLI tools, but their man
page did not help...
Why bother setting the icon in the resource fork?
I think the the icon is associated with the document type in the
Applications Info.plist.
Something like:
.....
<key>CFBundleDocumentTypes</key>
<array>
<dict>
<key>CFBundleTypeExtensions</key>
<array>
<string>abc</string>
<string>text</string>
</array>
<key>CFBundleTypeIconFile</key>
<string>MyExample.icns</string>
....
Although, you may need to tell launch services or have the finder see
the Application bundle in some way--like opening the directory where
its contained.
Brian Ray
email@hidden
http://kazavoo.com/blog
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Installer-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden