task grouping not working for gtk based applications
d3matt opened this issue · comments
Describe the bug
Launching multiple seamless gtk based applications with the same binary isn't showing them as grouped
To Reproduce
Steps to reproduce the behavior:
- xpra start :8
- using a session to launch xpra with opengl off, connecting to the remote server over ssh on display 8
- launch multiple gvim windows, note that they're not grouped together
System Information (please complete the following information):
- Server OS: Rocky Linux 9.3
- Client OS: Windows 10
- Xpra Server Version 5.0.2
- Xpra Client Version 5.0.8
Additional context
Some QT based applications (such on konsole) and xfce based applications (such as xfce4-terminal) seem to get grouped together but not others. The terminal I launch everything from (usually konsole) was started from the xpra client taskbar start menu.
My guess is that the grouped applications use the same pid
for all of their windows and the others do not.
If so, then I'm not sure that this is fixable in a sane way.
Hmm, yea... Looks like if I force a new PID to get a new window, then QT apps don't group either... Could the client optionally group things based on the /proc//exe symlink?
It should be doable here:
xpra/xpra/client/gtk3/client_base.py
Lines 1427 to 1468 in efa5e2c
I was worried that the signal watcher was going to be tied to it, but I was wrong, it only uses the wid, pid:
xpra/xpra/client/mixins/windows.py
Line 960 in efa5e2c
@d3matt please try 307242b or later.
The default grouping will be the first match from:
xpra/xpra/client/gtk3/client_base.py
Line 79 in 307242b
So what you want should be achievable using:
XPRA_WINDOW_GROUPING=group-leader-xid,command,pid xpra attach ...
(keeping group-leader-xid
as the first option should ensure we honour applications that do request grouping themselves)