Created attachment 148550 [details] Window rules SUMMARY When I apply window rules for Discord they don't work. STEPS TO REPRODUCE 1. Run wayland session 2. Setup window rules (example in attachments) 2. Launch Discord as native wayland app (https://wiki.archlinux.org/title/Wayland#Electron) OBSERVED RESULT Rules are not being applied. Window has titlebar, it is on wrong screen. EXPECTED RESULT Rules apply according to their definition. SOFTWARE/OS VERSIONS Operating System: Arch Linux KDE Plasma Version: 5.24.5 KDE Frameworks Version: 5.93.0 Qt Version: 5.15.3 Graphics Platform: Wayland Graphics Processor: AMD VEGAM
I am experiencing same issue with MPV (which is also native Wayland app)
> I am experiencing same issue with MPV (which is also native Wayland app) Can you show what window rules you have for MPV? (discord doesn't start on my machine in native wayland mode)
I am experiencing same issue with Element in native wayland. rule is [element] Description=element clientmachine=localhost desktops=89fc92f3-0710-4a38-9b3f-4ea322967037 desktopsrule=2 wmclass=element wmclassmatch=2 (In reply to Vlad Zahorodnii from comment #2) > Can you show what window rules you have for MPV? (discord doesn't start on > my machine in native wayland mode) electron bundled with discord doesn't support wayland, you need an external electron (I test electron 19).
Created attachment 155231 [details] wayland_debug discord logs with WAYLAND_DEBUG=1
(In reply to Vlad Zahorodnii from comment #2) > discord doesn't start on my machine in native wayland mode It was working for a while but not anymore. I am using this package: https://aur.archlinux.org/packages/discord_arch_electron If I use "detect window rules" now it treats discord windows as ones with "Electron" window class, or "electron Electron" whole window class. "Electron", "electron", "electron Electron" window classes didn't make rules work. I tried using "Discord", ".*Discord$", ".* - Discord" matches for window title with but none made it work too. I am attaching logs taken with WAYLAND_DEBUG=1.
Created attachment 155232 [details] MPV rules MPV rules partially work. Window placed where it should but it's not getting resized even if I use Force attribute. However, I think this is irrelevant to discord and should be handled separately anyway.
Discord sets "Electron" app id, so the window class match fails. Discord or electron needs some fixing. Mpv: position window rule works, but the size window rule does not. kwin asks mpv to show itself with the given size, but mpv ignores that and attaches a buffer with different size anyway. Can't fix it in kwin, please report this issue to mpv developers.
(In reply to Vlad Zahorodnii from comment #7) > Discord sets "Electron" app id, so the window class match fails. Discord or electron needs some fixing. If that's the case, shouldn't I be able at least have a match with class ~ 'Electron` and title ~ 'Discord'?
*** Bug 464189 has been marked as a duplicate of this bug. ***
*** Bug 464190 has been marked as a duplicate of this bug. ***
Created attachment 155249 [details] window rules For example, these rules don't work too although there is "Discord" match for title and "Electron" for app id.