From 8e12c5c029dd5d9a2a7debc33995d8a8836a7164 Mon Sep 17 00:00:00 2001 From: Sean Whitton Date: Mon, 31 May 2021 21:03:51 -0700 Subject: add cursor warping to sway workspace cycling bindings --- .config/sway/config | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/.config/sway/config b/.config/sway/config index 77f065d9..93f30755 100644 --- a/.config/sway/config +++ b/.config/sway/config @@ -264,12 +264,18 @@ bindsym Mod1+Ctrl+i exec pkill -u $USER -f --signal USR1 i3status-wrapper, kill # Cycle through all workspaces on monitor. Unlike C-i j and C-i [0-9]+, these # move the container *and* switch view to the other workspace, because there -# are more like Mod4+Ctrl+j/k than they are like the C-i bindings -bindsym Mod4+comma workspace prev_on_output -bindsym Mod4+period workspace next_on_output -bindsym Mod4+Ctrl+comma move container to workspace prev_on_output, \ +# are more like Mod4+Ctrl+j/k than they are like the C-i bindings. +# +# Warp the cursor to a point on the screen which is hopefully a titlebar. +# This means that cycling through workspaces does not abruptly stop because, +# e.g., a VNC client has grabbed the keyboard upon entry to the workspace. +bindsym Mod4+comma seat - cursor set 0 0, workspace prev_on_output +bindsym Mod4+period seat - cursor set 0 0, workspace next_on_output +bindsym Mod4+Ctrl+comma seat - cursor set 0 0, \ + move container to workspace prev_on_output, \ workspace prev_on_output -bindsym Mod4+Ctrl+period move container to workspace next_on_output, \ +bindsym Mod4+Ctrl+period seat - cursor set 0 0, \ + move container to workspace next_on_output, \ workspace next_on_output bindsym Mod4+i focus output left -- cgit v1.2.3