Re: Any way in applescript to use an image as a folder icon?
Re: Any way in applescript to use an image as a folder icon?
- Subject: Re: Any way in applescript to use an image as a folder icon?
- From: Kenneth McDonald <email@hidden>
- Date: Sun, 6 Jun 2004 01:47:58 -0500
Using the os x command-line utilities a couple of people mentioned, I
did get
something to work. It's not pure AppleScript so I won't post it here (I
use
Python whenever I can), but you could code the same with, with I suspect
rather more difficulty, in Applescript. It works as follows:
1) Choose the image you wish to use as an icon and the folder to
be iconized.
2) Copy the image to a temporary file (as it will be modified).
3) Use AppleScript and Image Events to save an icon with the
temp file. (There's an example script that does this in
/Library/Scripts/Folder Actions.)
4) Use the 'seticon' command in the command-line package
mentioned before to set the folder's icon to that of the temp
file.
5) Delete the temp file.
It's painful, but it works.
Cheers,
Ken
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.