Keep universal clipboard shortcuts working in terminals
Sending the shortcut through wtype's virtual keyboard let the physically held SUPER merge into the injected chord, so terminals saw SUPER+CTRL+Insert instead of CTRL+Insert, and injected CTRL+V could even trigger the SUPER+CTRL+V clipboard manager bind. Send via send_key_state with no window target instead: explicit mods go straight to the focused surface, layer-shell panels included. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01XnMDbwJXQA3fvW8o8Pwr97
This commit is contained in:
co-authored by
Claude Fable 5
parent
63955e787f
commit
a0e6d65ba8
@@ -105,15 +105,20 @@ grep -Fq $'SUPER + RETURN Terminal' <<<"$fresh_output" || fail "default applicat
|
||||
grep -Fq $'SUPER + SHIFT + A ChatGPT' <<<"$fresh_output" || fail "default application bindings include preinstalled web apps"
|
||||
pass "default application bindings load from package defaults"
|
||||
|
||||
grep -F 'hl.dsp.exec_cmd("wtype -M " .. modifier .. " -k " .. key:lower() .. " -m " .. modifier)' "$ROOT/default/hypr/bindings/clipboard.lua" >/dev/null ||
|
||||
fail "universal clipboard shortcuts use the virtual keyboard"
|
||||
pass "universal clipboard shortcuts reach focused layer-shell fields"
|
||||
grep -F 'hl.dsp.send_key_state({ mods = mods, key = key, state = "down" })' "$ROOT/default/hypr/bindings/clipboard.lua" >/dev/null ||
|
||||
fail "universal clipboard shortcuts send explicit mods to the focused surface"
|
||||
pass "universal clipboard shortcuts send explicit mods to the focused surface"
|
||||
|
||||
if grep -F 'hl.dsp.send_key_state' "$ROOT/default/hypr/bindings/clipboard.lua" >/dev/null; then
|
||||
if grep -E 'send_key_state\(\{[^}]*window' "$ROOT/default/hypr/bindings/clipboard.lua" >/dev/null; then
|
||||
fail "universal clipboard shortcuts do not target only normal windows"
|
||||
fi
|
||||
pass "universal clipboard shortcuts do not exclude layer-shell fields"
|
||||
|
||||
if grep -F 'wtype -M' "$ROOT/default/hypr/bindings/clipboard.lua" >/dev/null; then
|
||||
fail "universal clipboard shortcuts avoid the virtual keyboard so held SUPER cannot merge in"
|
||||
fi
|
||||
pass "universal clipboard shortcuts avoid virtual keyboard modifier merging"
|
||||
|
||||
removed_home="$tmpdir/removed-home"
|
||||
mkdir -p "$removed_home/.local/state/omarchy"
|
||||
touch "$removed_home/.local/state/omarchy/preinstalls-removed"
|
||||
|
||||
Reference in New Issue
Block a user