This question already has an answer here:

I downloaded and installed Neatbeans 8.1 from the official site. Even if I tick Keep in Dock for the Netbeans icon, a new icon is generated every time I click on it. This new icon doesn't have the option to Keep in Dock, only Close.

I googled a bit and came to know about .desktop files in /usr/share/applications

However, there is no .desktop file for netbeans!


Update: I copied the .desktop file from ~/.local/share/applications to /usr/share/applications

I guess the only problem remaining is figuring out the WM_CLASS of Netbeans 8.1

But when I run this command:

xprop WM_CLASS

as suggested in the other question, it returns WM_CLASS: not found

So how to find that out?

marked as duplicate by Ravan, bigbang, Lewis Goddard Dec 10 '15 at 14:19

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

  • I updated the question. Please check it out :) – Raj Mehta Dec 10 '15 at 6:41

Try StartupWMClass=NetBeans IDE 8.1


  • short, precise but works =) – Ravan Dec 10 '15 at 10:12
  • Just to clarify this should be added on a new line in the netbeans .desktop file found in ~/.local/applications or /usr/share/applications – Chris Aug 5 at 6:51

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