-# See https://wiki.hyprland.org/Configuring/Keywords/ for more
+# begin
+# ───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
$suremod = SUPER ALT CTRL
$mainmod = SUPER
-# binds that don't want to get fat-fingered
-bind = $suremod, M, exit,
-bind = $suremod, F, fullscreen,0
-bind = $suremod, Return, exec, konsole # backup terminal app
-bind = $suremod, D, denywindowfromgroup, toggle
-bind = ALT SHIFT, F12, exec, ~/.config/hypr/scripts/gamemode.sh
-
-# Example binds, see https://wiki.hyprland.org/Configuring/Binds/ for more
+# mainmod shortcuts
+# ───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
bind = $mainmod, Return, exec, footclient
bind = $mainmod Shift, Q, killactive,
bind = $mainmod Shift, Return, exec, footclient -w 1280x800 -a popup
bind = $mainmod, P, exec, footclient -w 640x400 -a popup -H hyprpicker #color Pipette
-bind = $mainmod, E, exec, dolphin
+bind = $mainmod, D, exec, dolphin
+bind = $mainmod, E, exec, footclient -a lf lfrun
bind = $mainmod, F, fullscreen,1
bind = $mainmod, V, exec, killall fuzzel || cliphist list | fuzzel -d --config="$HOME"/.config/fuzzel/fuzzel-centered.ini | cliphist decode | wl-copy
bind = $mainmod Shift, V, togglefloating
bind = $mainmod SHIFT, S, layoutmsg, preselect d # dwindle
bind = $mainmod, G, togglegroup
bind = $mainmod SHIFT, G, lockactivegroup, toggle
-bind = ALT, TAB, focuscurrentorlast
bind = $mainmod, TAB, exec, ~/.config/hypr/scripts/windowswitch-rg.sh
bind = $mainmod, grave, exec, ~/.config/hypr/scripts/RofiEmoji.sh
bind = $mainmod, plus, layoutmsg, hy3:makegroup v
bind = $mainmod, minus, layoutmsg, hy3:makegroup h
+bind = $mainmod SHIFT, D, denywindowfromgroup, toggle
+
+# scratchpad
+bind = $mainmod, I, togglespecialworkspace, overlay
+bind = $mainmod SHIFT, I, movetoworkspace, special:overlay
+
+
+# suremod keys (prevent fat-fingering 'em by accident)
+# ───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
+bind = $suremod, M, exit,
+bind = $suremod, F, fullscreen,0
+bind = $suremod, Return, exec, konsole # backup terminal app
+
+# misc keys (mostly redundant, but some habits die hard)
+# ───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
+bind = ALT, TAB, focuscurrentorlast
+bind = ALT SHIFT, F12, exec, ~/.config/hypr/scripts/gamemode.sh
+bind = $mainmod, Print, exec, ~/.config/hypr/scripts/grimblast-sshot-output
+bind = $mainmod SHIFT, Print, exec, ~/.config/hypr/scripts/grimblast-sshot-area
+
+# media keys
+bindl = , XF86AudioRaiseVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%+
+bindl = , XF86AudioLowerVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%-
+bindl = , XF86AudioMute, exec, ~/.config/hypr/scripts/muteorunmute.sh
+bindl = , XF86AudioPlay, exec, playerctl play-pause
+bindl = , XF86AudioNext, exec, playerctl next
+bindl = , XF86AudioPrev, exec, playerctl previous
+bindl = , XF86audiostop, exec, playerctl stop
+
+
+# movement
+# ───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
# Move focus with mainMod + arrow keys
bind = $mainmod, left, movefocus, l
bind = $mainmod, right, movefocus, r
bind = $mainmod, K, movefocus, u
bind = $mainmod, J, movefocus, d
+# move without affecting groups
+bind = $mainmod SHIFT, left, movewindow, l
+bind = $mainmod SHIFT, right, movewindow, r
+bind = $mainmod SHIFT, up, movewindow, u
+bind = $mainmod SHIFT, down, movewindow, d
+bind = $mainmod SHIFT, H, movewindow, l
+bind = $mainmod SHIFT, L, movewindow, r
+bind = $mainmod SHIFT, K, movewindow, u
+bind = $mainmod SHIFT, J, movewindow, d
+
# Move windows or groups with mainMod + Shift + arrow keys
-bind = $mainmod SHIFT, left, movewindoworgroup, l
-bind = $mainmod SHIFT, right, movewindoworgroup, r
-bind = $mainmod SHIFT, up, movewindoworgroup, u
-bind = $mainmod SHIFT, down, movewindoworgroup, d
-bind = $mainmod SHIFT, H, movewindoworgroup, l
-bind = $mainmod SHIFT, L, movewindoworgroup, r
-bind = $mainmod SHIFT, K, movewindoworgroup, u
-bind = $mainmod SHIFT, J, movewindoworgroup, d
-
-# Move windows into groups
-bind = $mainmod ALT, left, moveintogroup, l
-bind = $mainmod ALT, right, moveintogroup, r
-bind = $mainmod ALT, up, moveintogroup, u
-bind = $mainmod ALT, down, moveintogroup, d
-bind = $mainmod ALT, H, moveintogroup, l
-bind = $mainmod ALT, L, moveintogroup, r
-bind = $mainmod ALT, K, moveintogroup, u
-bind = $mainmod ALT, J, moveintogroup, d
-
-# Move windows out of groups
-bind = $mainmod SHIFT ALT, left, moveoutofgroup, l
-bind = $mainmod SHIFT ALT, right, moveoutofgroup, r
-bind = $mainmod SHIFT ALT, up, moveoutofgroup, u
-bind = $mainmod SHIFT ALT, down, moveoutofgroup, d
-bind = $mainmod SHIFT ALT, H, moveoutofgroup, l
-bind = $mainmod SHIFT ALT, L, moveoutofgroup, r
-bind = $mainmod SHIFT ALT, K, moveoutofgroup, u
-bind = $mainmod SHIFT ALT, J, moveoutofgroup, d
-
-# Switch through group windows
+bind = $mainmod CTRL, left, movewindoworgroup, l
+bind = $mainmod CTRL, right, movewindoworgroup, r
+bind = $mainmod CTRL, up, movewindoworgroup, u
+bind = $mainmod CTRL, down, movewindoworgroup, d
+bind = $mainmod CTRL, H, movewindoworgroup, l
+bind = $mainmod CTRL, L, movewindoworgroup, r
+bind = $mainmod CTRL, K, movewindoworgroup, u
+bind = $mainmod CTRL, J, movewindoworgroup, d
+
+# move through group windows
bind = $mainmod, O, changegroupactive, f
bind = $mainmod, U, changegroupactive, b
+
+# workspaces
+# ───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
# Switch workspaces with mainMod + [0-9]
bind = $mainmod, 1, workspace, 1
bind = $mainmod, 2, workspace, 2
bind = $mainmod, mouse_down, workspace, e+1
bind = $mainmod, mouse_up, workspace, e-1
-# Move/resize windows with mainMod + LMB/RMB and dragging
-bindm = $mainmod, mouse:272, movewindow
-bindm = $mainmod, mouse:273, resizewindow
-# media keys
-bindl = , XF86AudioRaiseVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%+
-bindl = , XF86AudioLowerVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%-
-bindl = , XF86AudioMute, exec, ~/.config/hypr/scripts/muteorunmute.sh
-bindl = , XF86AudioPlay, exec, playerctl play-pause
-bindl = , XF86AudioNext, exec, playerctl next
-bindl = , XF86AudioPrev, exec, playerctl previous
-bindl = , XF86audiostop, exec, playerctl stop
+# submaps
+# ───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
+bind = ALT SHIFT, R, submap, resize
+# will switch to a submap called resize
-# printscr
-bind = $mainmod, Print, exec, grim -g "$(slurp)" - | swappy -f -
-bind = $suremod, Print, exec, grim "$HOME/Bilder/scrot-"$(date +"%Y%m%d--%H%M%S")""
+# will start a submap called "resize"
+submap = resize
-# 'scratchpad
-bind = $mainmod, I, togglespecialworkspace, overlay
-bind = $mainmod SHIFT, I, movetoworkspacesilent, special:overlay
+# sets repeatable binds for resizing the active window
+binde = , right, resizeactive, 10 0
+binde = , left, resizeactive, -10 0
+binde = , up, resizeactive, 0 -10
+binde = , down, resizeactive, 0 10
+binde = , l, resizeactive, 10 0
+binde = , h, resizeactive, -10 0
+binde = , k, resizeactive, 0 -10
+binde = , j, resizeactive, 0 10
+
+# use reset to go back to the global submap
+bind = , catchall, submap, reset
+
+# will reset the submap, which will return to the global submap
+submap = reset
+
+
+# mouse binds
+# ───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
+# Move/resize windows with mainMod + LMB/RMB and dragging
+bindm = $mainmod, mouse:272, movewindow
+bindm = $mainmod, mouse:273, resizewindow