1

trying to create a launcher with a .png image file and main menu keeps on removing it. is .png not supported or do I need to edit the image first?

Jacob Vlijm
  • 83,767

1 Answers1

1

What goes wrong

I tried to create a launcher with Alacarte, with the same result. It turns out that when Alacarte creates a new launcher, it does not handle the icon's file extension correctly on custom icons. In the Icon= line of the launcher; it simply leaves out the extension.

How you can fix it

In your home directory, there is a folder ~/.local/share/applications (.local is invisible by default, press Ctrl + H to make it visible). That is the location where your launcher (file) is created.

  • Open the folder
  • Look for a file named alacarte-made.desktop (if you created more than one, they will be numbered)
  • Open gedit, drag the file alacarte-made.desktop on to the open gedit window to open it.
  • Look for the line, starting with Icon=, replace the section after Icon= with the path to your icon, including the .png extension.

Note

You might have to log out and back in to see the result.

Jacob Vlijm
  • 83,767
  • I did and it already had the right path. – Syi Kargath Sep 11 '14 at 07:18
  • @SyiKargath Then could you paste the content of the file in your post? Alacarte consequently removes the extenion. – Jacob Vlijm Sep 11 '14 at 07:21
  • Icon=/home/randy/Pictures/minecraft_icon_by_dharmainitiative2010-d33ca5p – Syi Kargath Sep 11 '14 at 07:23
  • I don't see a .png extension, like I mentioned in my answer. I assume it is in the icon's name. – Jacob Vlijm Sep 11 '14 at 07:25
  • so just add the .png and it should work? – Syi Kargath Sep 11 '14 at 07:27
  • if the icon's name is minecraft_icon_by_dharmainitiative2010-d33ca5p.png, absolutely. As mentioned, you might have to log out/in before you see the result. – Jacob Vlijm Sep 11 '14 at 07:28
  • not only did it not work but logging out froze my machine. I forced a shutdown and now my mouse pointer is nowhere to be found – Syi Kargath Sep 11 '14 at 07:44
  • Then something else is wrong with your system. There is no way editing a .desktop file like I explained can cause trouble like this. – Jacob Vlijm Sep 11 '14 at 07:46
  • so, I feel very dumb but which one should I be editing? alacarte-made.desktop, alacarte-made.desktop~, alacarte-made-1.desktop? – Syi Kargath Sep 11 '14 at 08:02
  • @SyiKargath The one ending with ~ is just a gedit backup file, don't edit that one! It looks like you made more than one launcher; To see which one is "the right one", you can right-click, go to "properties", then "permissions" tab, then tick "allow to execute". Now you can see/recognize the file, named as you named it. – Jacob Vlijm Sep 11 '14 at 08:07