Details
-
Task
-
Resolution: Unresolved
-
Not Evaluated
-
None
-
6.8
-
None
Description
QWidget::setWindowRole is important for session restoration.
The current implementation calls QXcbWindow::setWindowRole directly. This then sets the X11 atom WM_WINDOW_ROLE[1] with a unique ID for that window so that the position and state can be restored correctly,
There is nothing Widget specific about this function. It's a window property. It equally applies to any QtQuick apps that wanted to have working session management. Right now almost all QtQuick apps simply don't do session restoration well.
We need to have something lifted up into QWindow or exposed via the X11 native interface.
This same idea of a unique window id for session management is also identical on wayland, and I intend to copy whatever we do on X.