View Full Version : [SOLVED] Launch application using various icons with gnome desktop shortcut
nlee2
March 16th, 2018, 01:01 AM
In ubuntu 17.10 gnome desktop, I made desktop shortcuts to launch an application with different parameter on the exec line. Each desktop shortcut uses a different icon to represent the parameter being passed. The proper custom icon is displayed in Activities and Favorites but when I launch the desktop shortcut it is the generic application icon that is displayed.
How do I create a shortcut that will use a different icon to distinguish between each exec parameter?
kostkon
March 16th, 2018, 03:35 PM
You could try the following, it might make a difference:
Append the --class parameter to your Exec entry in order to set a custom WM_CLASS for each .desktop file, e.g.:
Exec=my_executable --class=MyCustomClass1
and also add the following line to each .desktop file:
StartupWMClass=MyCustomClass1
Hope that helps
nlee2
March 17th, 2018, 02:13 AM
Thanks for the info. Unforunately vncviewer aka my_executable does not support --class parameter. What to do?
edit
Got it working by using xprop to get the vm_class and use that class in StartupWMClass.
Powered by vBulletin® Version 4.2.2 Copyright © 2024 vBulletin Solutions, Inc. All rights reserved.