Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

Link1010

macrumors newbie
Original poster
Jun 17, 2012
17
0
Ontario, Canada
Okay, so I just got Front row back on my macbook pro, but in order to activate it i needed to make an applescript. The script works fine and will activate front Row, but when I save my script as an application it wont let me change the icon of it. every time I try to replace the icns file with my own (yes changed the name to match of my icns file to match the previous one) all that it shows is the preview applications icon with the letters icns below it.

I have also tried to change it by copy and pasting it using finder.

Can someone please help me? I dont know what to try :(

P.S. If you want I can upload my file to dropbox so you can try and change it yourself.
 

kryten2

macrumors 65816
Mar 17, 2012
1,114
99
Belgium
Okay, so I just got Front row back on my macbook pro, but in order to activate it i needed to make an applescript. The script works fine and will activate front Row, but when I save my script as an application it wont let me change the icon of it. every time I try to replace the icns file with my own (yes changed the name to match of my icns file to match the previous one) all that it shows is the preview applications icon with the letters icns below it.

I have also tried to change it by copy and pasting it using finder.

Can someone please help me? I dont know what to try :(

P.S. If you want I can upload my file to dropbox so you can try and change it yourself.

Does the icns file show when you preview it in the Finder? Or does it also show with the letters icns below it? Could be a wonky icns file. Please attach it to your post and the application as well.
 

Link1010

macrumors newbie
Original poster
Jun 17, 2012
17
0
Ontario, Canada
Does the icns file show when you preview it in the Finder? Or does it also show with the letters icns below it? Could be a wonky icns file. Please attach it to your post and the application as well.

I'm currently changing up my script a bit, so I'll upload it soon, but for now here is the icon (it wont let me attach it because it is in the icns format)

https://www.dropbox.com/s/zh0nzl4tg04kuw3/applet.icns
 

Link1010

macrumors newbie
Original poster
Jun 17, 2012
17
0
Ontario, Canada
Does the icns file show when you preview it in the Finder? Or does it also show with the letters icns below it? Could be a wonky icns file. Please attach it to your post and the application as well.

Yes i can see the icon when i quick view it. Here is the application.
**NOTE: it will probably not work or do anything for you unless you have front row installed** (or it might not work period cause im not that good with applescript yet)

https://www.dropbox.com/sh/ccasvifc0j14n5m/J__BevW2Wh
 

kryten2

macrumors 65816
Mar 17, 2012
1,114
99
Belgium
Copy and pasting the original Front Row icon using the Finder works for me.
Changing the applet.icns file in the Resources folder of the application with the one from the Resources folder of Front Row (eg frontrow.icns) also works.
The third attached thumbnail is your applet.icns file. Something wrong there. It's missing the 256 x 256 and 512 x 512 pixels images. Try the one in the attached zip file.

Note : By application I mean something I made not yours.

Edit : I downloaded your application and it shows the Front Row icon just fine.128 x 128 pixels that is.
 

Attachments

  • Picture 3.png
    Picture 3.png
    101 KB · Views: 515
  • Picture 4.png
    Picture 4.png
    107.6 KB · Views: 533
  • Picture 5.png
    Picture 5.png
    135.5 KB · Views: 519
  • Picture 6.png
    Picture 6.png
    122.2 KB · Views: 582
  • applet.icns.zip
    297.7 KB · Views: 469
Last edited:

Link1010

macrumors newbie
Original poster
Jun 17, 2012
17
0
Ontario, Canada
Copy and pasting the original Front Row icon using the Finder works for me.
Changing the applet.icns file in the Resources folder of the application with the one from the Resources folder of Front Row (eg frontrow.icns) also works.
The third attached thumbnail is your applet.icns file. Something wrong there. It's missing the 256 x 256 and 512 x 512 pixels images. Try the one in the attached zip file.

Note : By application I mean something I made not yours.

Edit : I downloaded your application and it shows the Front Row icon just fine.128 x 128 pixels that is.

Okay so, I copied you icon into the resources folder and nothing happened, I also tried doing the finder way and then restarted my mac to see if it would change then, but of course again, nothing changed unfortunately :(. But when I started spamming the paste button, the icon appeared for a couple seconds and then went away. Check out my screen recording, it'll show you what happens.

BTW thanks for all your help so far! :)
 

Attachments

  • Icon Glitch.mp4.zip
    1.6 MB · Views: 420

kryten2

macrumors 65816
Mar 17, 2012
1,114
99
Belgium
Really don't know what's causing this. Could be corrupted caches or quicklook acting strange. You'll have to look up how to clear caches or fix quicklook.
One last thing you can try is to use SetFileIcon.
 

Asanga

macrumors newbie
Jun 7, 2014
11
1
Bremen, Germany
Really don't know what's causing this. Could be corrupted caches or quicklook acting strange. You'll have to look up how to clear caches or fix quicklook.
One last thing you can try is to use SetFileIcon.

This may be already solved for the OP. Since the solution was not written, I thought of writing what I found when I tried to do the same (i.e., change the icon of the Apple Script based app).

I copied a new icon file (applet.icns) and even though the file was there, it did not appear in the Finder beside the app. After some unsuccessful experiments, I found that in the .app directory, in addition to the Contents directory there was a hidden file starting with the name “Icon?”. This was only visible once I opened a terminal and ran a “ls -la”. I removed this file and voila!, the icon appeared beside the app.

I have no idea how that file got there. Maybe it was my experimenting.

Hope this will help others who may have the same issue.

Best regards,

Asanga

An update:

Feels extremely silly to explain this, but this is how I changed the icon.

- select app in Finder and open app directory through “Show Package Contents”
- go to Contents/Resources and copy/paste the new icon (.icns file) onto applet.icns
- select the app, again in Finder and this time, click on “Get Info”
- select the app icon at the top - a blue outline will appear
- copy the icon (.icns file) onto this outlined icon (command-v)
- now, check the .app directory using a terminal - “ls -la”
- the “Icon?” file should be there
- delete this file - “rm Icon^M”
- immediately, the app should have the copied icon beside it in the Finder

BTW, I have OS X 10.9.3 (13D65)
 
Last edited:
  • Like
Reactions: Yogesh3d

zeppenwolf

macrumors regular
Nov 17, 2009
129
3
...in addition to the Contents directory there was a hidden file starting with the name “Icon?”

Actually, that's not quite exactly the name of the file. That's how UNIX represents a file whose name is "Icon
".

The reason it's called "Icon
" is so that it's utterly impossible for the user to type the same name while in the Finder. Get it? Once you hit the Return key, you've got the name "Icon", so you can never actually type "Icon
".

Are you using Mavericks ? Well, one thing hasn't changed from 1984 until Snow Leopard, which I'm using now as I type, (long story), but I won't be surprised if it's still the same on Mavericks, (whatever the heck a Maverick is???)

Select and Copy a graphic; select a folder, Get Info, and Paste the Copied graphic onto the default folder icon... It works, of course-- the folder now has your custom graphic. What hasn't changed is the way it is implemented: a hidden file is created in the folder with the name "Icon
", and it has a resource fork, with one single resource of type "ICNS", or "icns", (I can't remember), and resource ID -16455.

It might sound strange now, but there was a time when it seemed like ResEdit was the coolest program ever written...
 

Asanga

macrumors newbie
Jun 7, 2014
11
1
Bremen, Germany
Are you using Mavericks ?

Yes.

Select and Copy a graphic; select a folder, Get Info, and Paste the Copied graphic onto the default folder icon... It works, of course-- the folder now has your custom graphic. What hasn't changed is the way it is implemented: a hidden file is created in the folder with the name "Icon
", and it has a resource fork, with one single resource of type "ICNS", or "icns", (I can't remember), and resource ID -16455.

I tried this and saw the “Icon?” file as you mentioned. But, the folder lost the folder icon and shows some other icon, not the one I copied. When I deleted the “Icon?” file, it reverted back to the original folder icon.
 

Yogesh3d

macrumors newbie
Aug 4, 2016
1
0
India
This may be already solved for the OP. Since the solution was not written, I thought of writing what I found when I tried to do the same (i.e., change the icon of the Apple Script based app).

I copied a new icon file (applet.icns) and even though the file was there, it did not appear in the Finder beside the app. After some unsuccessful experiments, I found that in the .app directory, in addition to the Contents directory there was a hidden file starting with the name “Icon?”. This was only visible once I opened a terminal and ran a “ls -la”. I removed this file and voila!, the icon appeared beside the app.

I have no idea how that file got there. Maybe it was my experimenting.

Hope this will help others who may have the same issue.

Best regards,

Asanga

An update:

Feels extremely silly to explain this, but this is how I changed the icon.

- select app in Finder and open app directory through “Show Package Contents”
- go to Contents/Resources and copy/paste the new icon (.icns file) onto applet.icns
- select the app, again in Finder and this time, click on “Get Info”
- select the app icon at the top - a blue outline will appear
- copy the icon (.icns file) onto this outlined icon (command-v)
- now, check the .app directory using a terminal - “ls -la”
- the “Icon?” file should be there
- delete this file - “rm Icon^M”
- immediately, the app should have the copied icon beside it in the Finder

BTW, I have OS X 10.9.3 (13D65)

Thank you .. this worked
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.