[v3] xdg-shell: use case to change the app ID at runtime

Submitted by Jan-Marek Glogowski on July 15, 2019, 2:20 p.m.

Details

Message ID 20190715142010.1823-1-glogow@fbihome.de
State Accepted
Commit e0d6ad1d5e7e80321285a9b14ca3329289eb02e6
Headers show

Not browsing as part of any series.

Commit Message

Jan-Marek Glogowski July 15, 2019, 2:20 p.m.
From: Jan-Marek Glogowski <glogow@fbihome.de>

LibreOffice is one big binary with explicit brandings for different
application modules. This is represented in X11 by a different
WM_CLASS setting for a window. The WM_CLASS is changed based on the
loaded document at runtime. As a result LibreOffice already offers
multiple desktop files with different icons, StartupWMClass
entries and application names.

This amendment of the set_app_id request just explicitly specifies
the use case to change a surfaces' app ID at runtime, so a compositor
implementor is made aware of it. Just as the WM_CLASS, a change of
the app ID should result in an update of the propertes of a surface
depending on the app ID, like the window icon specified in the
desktop file or a re-grouping of the surfaces in a task manager.
---
 stable/xdg-shell/xdg-shell.xml | 3 +++
 1 file changed, 3 insertions(+)

Patch hide | download patch | download mbox

diff --git a/stable/xdg-shell/xdg-shell.xml b/stable/xdg-shell/xdg-shell.xml
index 2e420c6..3a87a9e 100644
--- a/stable/xdg-shell/xdg-shell.xml
+++ b/stable/xdg-shell/xdg-shell.xml
@@ -604,6 +604,9 @@ 
 	For example, "org.freedesktop.FooViewer" where the .desktop file is
 	"org.freedesktop.FooViewer.desktop".
 
+	Like other properties, a set_app_id request can be sent after the
+	xdg_toplevel has been mapped to update the property.
+
 	See the desktop-entry specification [0] for more details on
 	application identifiers and how they relate to well-known D-Bus
 	names and .desktop files.

Comments

On Mon, Jul 15, 2019 at 04:20:10PM +0200, glogow@fbihome.de wrote:
> From: Jan-Marek Glogowski <glogow@fbihome.de>
> 
> LibreOffice is one big binary with explicit brandings for different
> application modules. This is represented in X11 by a different
> WM_CLASS setting for a window. The WM_CLASS is changed based on the
> loaded document at runtime. As a result LibreOffice already offers
> multiple desktop files with different icons, StartupWMClass
> entries and application names.
> 
> This amendment of the set_app_id request just explicitly specifies
> the use case to change a surfaces' app ID at runtime, so a compositor
> implementor is made aware of it. Just as the WM_CLASS, a change of
> the app ID should result in an update of the propertes of a surface
> depending on the app ID, like the window icon specified in the
> desktop file or a re-grouping of the surfaces in a task manager.

Reviewed-by: Jonas Ådahl <jadahl@gmail.com>


Jonas

> ---
>  stable/xdg-shell/xdg-shell.xml | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/stable/xdg-shell/xdg-shell.xml b/stable/xdg-shell/xdg-shell.xml
> index 2e420c6..3a87a9e 100644
> --- a/stable/xdg-shell/xdg-shell.xml
> +++ b/stable/xdg-shell/xdg-shell.xml
> @@ -604,6 +604,9 @@
>  	For example, "org.freedesktop.FooViewer" where the .desktop file is
>  	"org.freedesktop.FooViewer.desktop".
>  
> +	Like other properties, a set_app_id request can be sent after the
> +	xdg_toplevel has been mapped to update the property.
> +
>  	See the desktop-entry specification [0] for more details on
>  	application identifiers and how they relate to well-known D-Bus
>  	names and .desktop files.
> -- 
> 2.20.1
>
On Monday, July 15, 2019 5:20 PM, <glogow@fbihome.de> wrote:
> From: Jan-Marek Glogowski glogow@fbihome.de
>
> LibreOffice is one big binary with explicit brandings for different
> application modules. This is represented in X11 by a different
> WM_CLASS setting for a window. The WM_CLASS is changed based on the
> loaded document at runtime. As a result LibreOffice already offers
> multiple desktop files with different icons, StartupWMClass
> entries and application names.
>
> This amendment of the set_app_id request just explicitly specifies
> the use case to change a surfaces' app ID at runtime, so a compositor
> implementor is made aware of it. Just as the WM_CLASS, a change of
> the app ID should result in an update of the propertes of a surface
> depending on the app ID, like the window icon specified in the
> desktop file or a re-grouping of the surfaces in a task manager.

This LGTM.

Reviewed-by: Simon Ser <contact@emersion.fr>

Thanks!
On Mon, Jul 15, 2019 at 04:20:10PM +0200, glogow@fbihome.de wrote:
> From: Jan-Marek Glogowski <glogow@fbihome.de>
> 
> LibreOffice is one big binary with explicit brandings for different
> application modules. This is represented in X11 by a different
> WM_CLASS setting for a window. The WM_CLASS is changed based on the
> loaded document at runtime. As a result LibreOffice already offers
> multiple desktop files with different icons, StartupWMClass
> entries and application names.
> 
> This amendment of the set_app_id request just explicitly specifies
> the use case to change a surfaces' app ID at runtime, so a compositor
> implementor is made aware of it. Just as the WM_CLASS, a change of
> the app ID should result in an update of the propertes of a surface
> depending on the app ID, like the window icon specified in the
> desktop file or a re-grouping of the surfaces in a task manager.

Just noted this is missing Signed-off-by. Mind if I help you add it?


Jonas

> ---
>  stable/xdg-shell/xdg-shell.xml | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/stable/xdg-shell/xdg-shell.xml b/stable/xdg-shell/xdg-shell.xml
> index 2e420c6..3a87a9e 100644
> --- a/stable/xdg-shell/xdg-shell.xml
> +++ b/stable/xdg-shell/xdg-shell.xml
> @@ -604,6 +604,9 @@
>  	For example, "org.freedesktop.FooViewer" where the .desktop file is
>  	"org.freedesktop.FooViewer.desktop".
>  
> +	Like other properties, a set_app_id request can be sent after the
> +	xdg_toplevel has been mapped to update the property.
> +
>  	See the desktop-entry specification [0] for more details on
>  	application identifiers and how they relate to well-known D-Bus
>  	names and .desktop files.
> -- 
> 2.20.1
>
Am 15.07.19 um 16:20 schrieb glogow@fbihome.de:
> From: Jan-Marek Glogowski <glogow@fbihome.de>
> 
> LibreOffice is one big binary with explicit brandings for different
> application modules. This is represented in X11 by a different
> WM_CLASS setting for a window. The WM_CLASS is changed based on the
> loaded document at runtime. As a result LibreOffice already offers
> multiple desktop files with different icons, StartupWMClass
> entries and application names.
> 
> This amendment of the set_app_id request just explicitly specifies
> the use case to change a surfaces' app ID at runtime, so a compositor
> implementor is made aware of it. Just as the WM_CLASS, a change of
> the app ID should result in an update of the propertes of a surface
> depending on the app ID, like the window icon specified in the
> desktop file or a re-grouping of the surfaces in a task manager.

Signed-off-by: Jan-Marek Glogowski <glogow@fbihome.de>
On Wed, Jul 17, 2019 at 12:12:37PM +0200, Jan-Marek Glogowski wrote:
> Am 15.07.19 um 16:20 schrieb glogow@fbihome.de:
> > From: Jan-Marek Glogowski <glogow@fbihome.de>
> > 
> > LibreOffice is one big binary with explicit brandings for different
> > application modules. This is represented in X11 by a different
> > WM_CLASS setting for a window. The WM_CLASS is changed based on the
> > loaded document at runtime. As a result LibreOffice already offers
> > multiple desktop files with different icons, StartupWMClass
> > entries and application names.
> > 
> > This amendment of the set_app_id request just explicitly specifies
> > the use case to change a surfaces' app ID at runtime, so a compositor
> > implementor is made aware of it. Just as the WM_CLASS, a change of
> > the app ID should result in an update of the propertes of a surface
> > depending on the app ID, like the window icon specified in the
> > desktop file or a re-grouping of the surfaces in a task manager.
> 
> Signed-off-by: Jan-Marek Glogowski <glogow@fbihome.de>

Thanks, this has now landed.


Jonas

> _______________________________________________
> wayland-devel mailing list
> wayland-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/wayland-devel