cua icon indicating copy to clipboard operation
cua copied to clipboard

[Bug]: Super shortcuts from the Spaces viewer never reach the guest compositor (Omarchy/Hyprland)

Open Ayuilos opened this issue 1 month ago • 1 comments

Primary area

Cua Driver (Spaces interactive input on Hyprland guests: cua-spacesd → cua-driver tools)

Summary

When a person drives an Omarchy (Hyprland) Space from the Spaces viewer, Super chords never reach the guest compositor. Super+W arrives in the focused window as a plain w, so none of Omarchy's Super-based Hyprland bindings can be used from the viewer. Ctrl, Alt and Shift chords arrive correctly.

Reproduction

  1. Run Cua Spaces 0.9.3 (Linux AppImage) and open an Omarchy Space (ghcr.io/trycua/omarchy, local QEMU VM), streaming the desktop.
  2. In the Space, open a terminal and run showkey -a.
  3. Focus the Space window and press, one at a time: Alt+W, Super+Shift+W, Shift+W, Super+W, Ctrl+W, then Ctrl+D.
  4. Compare what showkey prints with what was pressed, and note that Super+W does not close the window (Omarchy binds SUPER+W to close).

Reproduced with the physical keyboard and with wtype injecting the same chords into the focused Space window.

Expected behavior

Keyboard input on a desktop stream behaves like a physical keyboard: Super+W reaches Hyprland as SUPER+W and triggers the binding (closes the window), the same way the chord would on the machine itself.

Actual behavior

Pressed in the Space window Received by the focused window (showkey -a)
Super+W w (119); the Hyprland binding does not fire
Super+Shift+W W; Super has no effect
Ctrl+W ^W (23) ✅
Alt+W ESC w (27, 119) ✅

In the same Space, cua do hotkey super+return does trigger the Omarchy binding (a terminal opens), so Hyprland accepts injected Super chords that arrive through that route.

Environment

  • Viewer host: CachyOS (Arch), niri 26.04 Wayland session, Cua Spaces 0.9.3 AppImage (bundled cua 0.4.1)
  • Guest: Omarchy image (ghcr.io/trycua/omarchy), local QEMU VM, cua-spacesd 0.5.3, cua-driver-bin 0.33.4, cua-hyprland-plugin 0.33.2, Hyprland 0.56.2
  • Same result before upgrading the guest's cua-driver from 0.28.2.

Evidence

  • showkey -a capture summarized above.
  • The modifier name survives the pipeline: the viewer encodes metaKey as command, cua-spacesd maps InputModifier::Command to the driver's Modifier::Command (driver_input.rs), and the tool adapter names it super (tool_input.rs).
  • On Hyprland there is no stateful input session; each batch is folded into cua-driver tool calls (lib.rs). For a desktop target, every key becomes a press_key call addressed to the focused window (pid/window_id, foreground) with modifiers: ["super"] (tool_input.rs, L371-L378).
  • Given the observed result, that window-addressed press_key route appears not to produce a compositor-visible Super chord, while cua do hotkey does. I have not traced which delivery the driver uses for that press_key call, so this is the likely location rather than a confirmed root cause.

Workaround and additional context

  • No in-viewer workaround; Super shortcuts cannot be used from the viewer.
  • Related but separate: on Wayland hosts such as niri, the Space window does not request zwp_keyboard_shortcuts_inhibit_v1, so Super chords bound by the host compositor (e.g. Mod+Return, Mod+1..9) never reach the window at all. Remote-desktop style clients usually request the inhibitor while focused.

Submission checks

  • [x] I searched for duplicate issues and active pull requests.
  • [x] This issue describes a single problem.
  • [x] I removed credentials, private data, sensitive screenshots, and vulnerability details from this public report.

Ayuilos avatar Oct 16 '26 06:10 Ayuilos

Thanks for the showkey repro. Linking #5345, the macOS side of the same problem (no way to send Super). @injaneity is looking at both.

f-trycua avatar Oct 18 '26 06:10 f-trycua