I created a .desktop file for my Qt application, but it still doesn't becomes available in Dash, and default icon is getting displayed when I'm running it manually:

[Desktop Entry]
GenericName=My Application
Comment=My Application Descr

What I have already tried to do:

  • Reading dozens of tutorials related to that topic
  • Moving this desktop file to /usr/share/applications/myapp.desktop
  • Moving an icon to /usr/share/icons/hicolor/128x128/apps/myapp.png
  • Running desktop-file-validate myapp.desktop - doesn't prints any errors
  • Running sudo desktop-file-install /usr/share/applications/myapp.desktop
  • Running sudo update-desktop-database
  • Logging out

But still no luck.

Is there any way to debug this issue? Also, do I understand right that Unity uses executable name in order to establish an association with a desktop file?

1 Answer 1


Finally, the following helped:

  1. Adding StartupWMClass=myapp in my .desktop file (it's possible to figure out a one by using xprop WM_CLASS)
  2. Placing icon in /usr/share/pixmaps/ instead.

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.