<div dir="ltr"><div><div>Hi Andy,<br><br>StartupWMClass usage should be considered legacy. In order to compute a mapping from window class to .desktop file, we need to read *all* files from disk, which is super expensive to do first thing on boot.<br><br></div>I wouldn't be too happy modifying it so that we have to do *more* work to make it work. I would rather work on a replacement so that we don't have to do as much work to find a .desktop file from a window.<br><br></div><div>Adding a new X window property like _NET_WM_DESKTOP_ID would be more up my alley, but I know Ryan isn't too happy with it, and is instead working on a better proposal. CCing him to hear his current thoughts.<br></div><div><div><br></div></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Jan 27, 2015 at 1:01 PM, Andy <span dir="ltr"><<a href="mailto:AndydeCleyre@gmail.com" target="_blank">AndydeCleyre@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div><div>Hi,<br><br>I'm just following up with some more use cases. The KDE System Settings can be launched as a monolithic item, or alternatively each module can be launched independently. The full application window's class is "systemsettings" while the components' are "kcmshell4" -- both of these should be grouped and matched with the System Settings .desktop file, so it would be appropriate to set both window classes in the System Settings .desktop file.<br><br>In looking for a solution to this StartupWMClass limitation, I came across folks asking the same questions two years ago: <a href="http://askubuntu.com/questions/248826/set-multiple-values-for-startupwmclass-to-group-under-same-launcher-in-unity" target="_blank">http://askubuntu.com/questions/248826/set-multiple-values-for-startupwmclass-to-group-under-same-launcher-in-unity</a><br><br>From that post:<br><br>'''<br>I have a program (Android Virtual Device Manager) that launches 'sub-programs' (namely emulators or virtual devices) from within itself (also can be launched from else where). I want any instances of EITHER of these programs to be grouped under the same Unity icon.<br><br>I have created a .desktop file to try and accomplish this but don't exactly know how to go about it. . . .<br>I am assuming that I somehow need to set two values for StartupWMClass but have not been able to do it correctly (or know if it is a valid operation). I have tried, colon separated like environment variables, comma separated, quotes, etc and I cannot find any hints in the <a href="http://standards.freedesktop.org/desktop-entry-spec/latest/ar01s05.html" rel="nofollow" target="_blank">official documentation</a>.<br><br>. . .<br><br>Another, more pedantic, but probably more identifiable example is with Matlab. I am running 2013a and the splash screen that initially shows and the program have completely different WM_CLASS values. This means, when I click my launcher with StartupWMClass=com-mathworks-util-PostVMInit in it, the splash screen comes up with a different (default Unknown) Unity icon, while the rest comes up grouped under my launcher. . . .<br><br>If I could specify something along the lines of:<br><br>StartupWMClass=com-mathworks-util-PostVMInit&&MATLAB<br><br>That would work perfectly (as both work separately) but I have no idea of the syntax, if it even exists. I just know nothing I have tried has worked thus far.<br><br>Any help or a definitive answer either way would be great as I believe this is a pretty fundamental element of a well functioning desktop.<br>'''<br><br></div>Someone responded 4 months later with:<br><br>'''<br>Same problem for me with Starcraft II launched throw playonlinux. There is first a application launcher:<br><br>(WM_CLASS(STRING) = "Blizzard Launcher.exe", "Wine") <br><br>and then the game itself:<br><br>(WM_CLASS(STRING) = "SC2.exe", "Wine")<br>'''<br><br></div>So there are clearly cases where this would help, and the limitation has been a known inconvenience for at least 2 years so far. Does anyone have a reason not to go forward allowing multiple values for StartupWMClass?<br><br></div><div>Thanks for reading,<br></div><div>Andy<br></div></div>
<br>_______________________________________________<br>
xdg mailing list<br>
<a href="mailto:xdg@lists.freedesktop.org">xdg@lists.freedesktop.org</a><br>
<a href="http://lists.freedesktop.org/mailman/listinfo/xdg" target="_blank">http://lists.freedesktop.org/mailman/listinfo/xdg</a><br>
<br></blockquote></div><br><br clear="all"><br>-- <br><div class="gmail_signature">  Jasper<br></div>
</div>