Re: ICON changes
Re: ICON changes
- Subject: Re: ICON changes
- From: Philip Aker <email@hidden>
- Date: Mon, 4 Aug 2008 01:45:53 -0700
On 2008-08-04, at 00:50:44 , Michael wrote:
From my searches I believe this is likely not possible but I will
ask anyway.
I photograph bodybuilding shows.
So I end up with up to 150 folders with the images of individual
competitors in them.
While I am sorting the images and later is is very convenient to
have the icon of the folder be the icon from one of that
competitor's images.
I would like to make a droplet that I could drag and drop a JPG file
onto and have the droplet copy that file's icon and then paste that
icon onto the folder the file was in.
I have not been able to find any examples where Apple script can
access the icon of a file.
It can't without extra help. Here is one scenario for the steps in
your droplet:
Use the built-in shell command 'sips -i' to create a standard custom
icon for the dropped image file.
Use this tool <http://vcn.bc.ca/~philip/#IcnsRsrc2File> to extract the
custom icon in the image file to a temp.icns file.
Use this tool <http://vcn.bc.ca/~philip/#SetCustomIcon> to set the
custom icon for the folder to the temp.icns file.
Delete the temp.icns file (or just create it in /tmp so it will
disappear on next restart).
All of the above steps involve a POSIX path so remember to use the
'quoted form of' on the path before throwing it at a shell tool.
Philip Aker
echo email@hidden@nl | tr a-z@. p-za-o.@
Democracy: Two wolves and a sheep voting on lunch.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden