In my case, I followed @Chris Hayes, method of finding the WMClass and update the file, see below for an example. I referred other *.desktop files in /usr/share/applications
and found that Ubuntu 20.04 is using "StartupWMClass" as the variable and NOT "WMClass". I could not find the Icon for this application so I had to download from the internet a jpeg file icon from Google Image search, save it in the path and assign to the variable "Icon".
Please note, I believe this field "StartupWMClass" is case sensitive
[Desktop Entry]
Name=PDFStudioViewer2020
Comment=View pdf documents
Keywords=pdf;ppdf;
StartupNotify=true
Terminal=false
Type=Application
Categories=Application;Office;Viewer;X-Red-Hat-Base;
MimeType=application/pdf;application/ppdf;
Icon=/opt/pdfstudioviewer2020/pdfstudio_internet_icon.jpeg
Exec=/opt/pdfstudioviewer2020/pdfstudioviewer2020 %F
StartupWMClass=PDF Studio Viewer
"sun-awt-X11-XFramePeer", "jetbrains-pycharm-ce"
as the output for step 6. I usedStartupWMClass=jetbrains-pycharm-ce
and it works. – d4nyll Jan 11 '18 at 15:59WM_CLASS: not found
. As the misbehaving application was kile and the name of the fileorg.kde.kile.desktop
, I just added the lineStartupWMClass=kile
and it works. My wild guess is that the last full-stop separated part of the filename (right before.desktop
) should match the StartupWMClass value. – Ansa211 Feb 11 '19 at 12:57StartupWMClass=QtCreator
). – Jason C Jan 10 '20 at 22:56StartupWMClass="desktop_window", "Nautilus"
inserted (Ubuntu 16.04.6 LTS) – WinEunuuchs2Unix Oct 31 '20 at 18:46.desktop
launchers by hand anyway: https://askubuntu.com/q/13758/480481 and https://askubuntu.com/q/1191962/480481 – pomsky Sep 06 '21 at 14:18*.tar.bz
on Ubuntu 20.04. I've just addedStartupWMClass=sublime_text
tosublime.desktop
) – IStranger Dec 02 '21 at 07:51