I have written a Python application (with pygtk and pymozembed) which I use very often.

In the Unity dash my application has an icon (as I definded in the .desktop file). But when I start it, there is no icon in the launcher. Just an empty hole.

Launcher file: /home/witek/.local/share/applications/kadro-reader.desktop

[Desktop Entry]
Name=Google Reader
Comment=Open site with Kadro: reader -> https://www.google.com/reader/view/

Python code for window initialization:

win = gtk.Window()
win.set_title("Google Reader")

How to add an Unity launcher icon to my Python application?

  • 1
    is your icon a png or svg? Where did you install it? Did you run gtk-update-icon-cache after installing your icon? – Timo Kluck Dec 6 '11 at 15:48
  • I have edited my question to add my concrete example. – Witek Dec 8 '11 at 14:35
  • Are you making a site-specific browser? Cuz I want that. – Ken Kinder Feb 16 '12 at 3:39
  • I use it for sites like Facebook or Google which try to track me. That way I have a specific browser for these sites and my default browser is not logged in into these services. You can download it here: github.com/witek/kadro/downloads – Witek Feb 21 '12 at 14:52

I don't think icon in .desktop file takes full path. I think it takes the name of an icon and searches for that icon in the current icon theme.

Try to put that icon at ~/.icons/google-reader.png and in the .desktop file just put


I have got I think a better answer. As the described solution add the icon application to the Dash Unity panel, it fails to display the icon on the application itself in /usr/share/applications.

You only need to add the icon (with the name declared in the Desktop Entry) in the /usr/share/pixmaps/ directory. This is the directory where all applications put their icons. This way you get your icon displaying in Dash Unity and on the application in the applications folder.

Besides the one currently checked is working, it requires you to create a new folder in your Home directory. This is not necessary if you use the /usr/share/pixmaps directory.

  • My application creates launchers (by the user) which are user specific. Therefor they have to be in the users home. The user also has no permissions to write into /usr/share/pixmaps. – Witek Feb 21 '12 at 14:49

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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