Supreeeme / xwayland-satellite

Xwayland outside your Wayland
Mozilla Public License 2.0
94 stars 4 forks source link

Titles and App IDs are missing #9

Closed maaxxaam closed 1 month ago

maaxxaam commented 1 month ago

First of all, thank you for the project! Running X11 apps becomes much easier this way thanks to your work <3

When attempting to list windows through the foreign-toplevel-management-unstable-v1 Wayland protocol extension, windows created with xwayland-sattelite show up with both title and app_id fields set to NULL. Here's an example of how it looks like when querying with lswt tool (running with two chromium windows, a terminal and a Discord client):

[maaxxaam@Maaxxaam ~]$ lswt -j
[
 {
        "title": "<NULL>",
        "app_id": "<NULL>",
        "maximized": false,
        "minimized": false,
        "activated": false,
        "fullscreen": true,
        "outputs": [ "eDP-1" ]
    },
    {
        "title": "~leon_plickat/lswt - list Wayland toplevels - sourcehut git – Chromium",
        "app_id": "chromium",
        "maximized": false,
        "minimized": false,
        "activated": false,
        "fullscreen": false,
        "outputs": [ "eDP-1" ]
    },
    {
        "title": "Terminal",
        "app_id": "Alacritty",
        "maximized": false,
        "minimized": false,
        "activated": true,
        "fullscreen": false,
        "outputs": [ "eDP-1" ]
    },
    {
        "title": "Issues · Supreeeme/xwayland-satellite – Chromium",
        "app_id": "chromium",
        "maximized": false,
        "minimized": false,
        "activated": false,
        "fullscreen": false,
        "outputs": [ "eDP-1" ]
    }
]
Supreeeme commented 1 month ago

Meant to get around to doing this but just forgot. Should be easy enough.

Supreeeme commented 1 month ago

Should be easy enough.

Famous last words :sweat_smile:. I've added basic naive support but there seems to be some edge cases that don't work properly, so I'll leave this open.

maaxxaam commented 1 month ago

Thank you for the quick reply and the patch! I can't help by be intrigued by the 7976e3a commit message:

for some reason some app ids have the first letter capitalized (Remmina)

I've taken a look at app IDs for things I have installed and seems like they generally may not only have their first letter capitalized (like Zotero, Leafpad and others) but capitalized letters in general (especially GNOME apps with IDs like org.gnome.SystemMonitor or org.gnome.Calculator). Were you expecting them to conform to being lowercase letters only?

Supreeeme commented 1 month ago

No, capitilization itself is not an issue, the issue is capitilization that doesn't match what I see from xprop - for example, I see Org.remmina.Remmina instead of org.remmina.Remmina.

Supreeeme commented 1 month ago

I believe the latest commit (3afc9ffa9d05cb5fc970af5415f6bd0e9ae8999e) fixed this (inadvertently!). Closing.