Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

My goal is to create a working launcher for PHPStorm which will work in both the desktop and the Unity launcher, using the proper logo, in 12.04. I followed the instructions here - How can I create launchers on my desktop? - to create a launcher on the desktop using the Gnome dialog box. That worked a treat as far as the desktop was concerned, but dragging the icon to the Unity launcher gave it a weird icon:

enter image description here

The PHPStorm.desktop file looks like this:

#!/usr/bin/env xdg-open

[Desktop Entry]

Next I tried to follow the accepted answer from here: How can I change the icon of an application in the Unity launcher?, but I found that there was no icons folder in ~/.local/share/. I went ahead and created it, and the rest of the folders mentioned in the answer, ~/.local/share/icons/hicolor/16x16/ etc. I then created a phpstorm.png in each folder, at the required sizes.

Next, I edited my PHPStorm.desktop file to the following and copied it to ~/.local/share/applications/

#!/usr/bin/env xdg-open

[Desktop Entry]

After logging back in, my unity launcher icon had disappeared completely, and the icon on my desktop had turned white.

What have I done wrong here? Why aren't the icons being picked up from the icons folder, and is the initial lack of icons folder something I should be concerned about?

share|improve this question
up vote 6 down vote accepted

Regarding the icons folder

The only program that has icons in ~/.local/share/icons is Wine, so no, a default install shouldn't create the folder.

Most installed programs place their icons in /usr/share/icons, where all users can access them.

Regarding the .desktop file

I went ahead and created it, and the rest of the folders mentioned in the answer, ~/.local/share/icons/hicolor/16x16/ etc.

The icon has to be placed in a folder called ~/.local/share/icons/hicolor/16x16/apps/.

share|improve this answer
22 hours... I can't even vote up with 8 rep! – shanethehat Apr 30 '12 at 22:16

I just created this wiki page :)

share|improve this answer
Sadly I can't even vote up this effort, but thank you! – shanethehat Apr 30 '12 at 22:30
Hey, you are welcome :) I don't need your upvote, I like helping out. – hakermania Apr 30 '12 at 22:44

I personally prefer adding icons to launcher by first adding applications to unity dash:

  1. Install Main Menu via Ubuntu Software Center.
  2. Open dash and type "Main Menu".
  3. Open menu editor and add your application to proper category (set name, icon, command etc).
  4. Save and exit.
  5. Open dash again type application name and run it.
  6. Right-click on icon of your application in launcher and check that you want hold it in launcher.

Now you have application in launcher and also in dash :)

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.