dbeaver: [Linux][Gnome3] DBeaver has incorrect WM_CLASS
Hello,
DBeaver on Gnome 3.x sets a generic WM_CLASS="SWT", "SWT", as you can see using xprop on the application window. Being Gnome3 “application-based” [1], this prevents the correct association between windows and the application icon (I’m using a .desktop file created by me).
A workaround would be setting up the property StartupWMClass="SWT" in the desktop, but SWT looks too generic to be useful. A sensible value would be DBeaver o a more specific DBeaver <Community|Enterprise>.
Thanks for your work!
[1] https://wiki.gnome.org/Projects/GnomeShell/ApplicationBased
About this issue
- Original URL
- State: closed
- Created 8 years ago
- Comments: 24 (10 by maintainers)
Commits related to this issue
- #609 SWT display init fix (set app name at start). Move SQL editor prefs in editor base class — committed to dbeaver/dbeaver by serge-rider 7 years ago
@meden Good point. I’ve fixed DBeaver app init so display name now should be correct (it is
DBeaverorDBeaver Enterprise). You can check this in EA version (http://dbeaver.jkiss.org/files/ea/)I looked into this and the fundamental idea seems to me to be the following: The values in the .desktop file like WM_CLASS and StartupWMClass just help the Desktop environment to match up icons and the like. StartupWMClass seems to work like this: The executable mentioned in the field “Exec” is launched and a bouncing startup notification is started - as soon as a window with the mentioned StartupWMClass pops up the bouncing action is stopped. These strings simply have to match up with the values the app itself sets when it initializes its environment. The problem cannot be solved by putting different stuff into the .desktop file, but only by putting something other than the default “WM_CLASS=SWT” in the actual java code. see this stackexchange page that explains how to set that exact property in the java code:
WM_CLASS is supposed to be specific to the the app (not the same for every app that uses the same toolkit) and static (not dynamicly changing for example into the name of the currently opened document). see the X11 docs for that matter