caelestia/hypr/hyprland/keybinds.conf
2025-09-26 10:12:10 +01:00

191 lines
8.7 KiB
Text

exec = hyprctl dispatch submap global
submap = global
# ## Shell keybinds
# Launcher
bindi = Super, Super_L, global, caelestia:launcher
bindin = Super, catchall, global, caelestia:launcherInterrupt
bindin = Super, mouse:272, global, caelestia:launcherInterrupt
bindin = Super, mouse:273, global, caelestia:launcherInterrupt
bindin = Super, mouse:274, global, caelestia:launcherInterrupt
bindin = Super, mouse:275, global, caelestia:launcherInterrupt
bindin = Super, mouse:276, global, caelestia:launcherInterrupt
bindin = Super, mouse:277, global, caelestia:launcherInterrupt
bindin = Super, mouse_up, global, caelestia:launcherInterrupt
bindin = Super, mouse_down, global, caelestia:launcherInterrupt
# Misc
bind = $kbSession, global, caelestia:session
bindl = $kbClearNotifs, global, caelestia:clearNotifs
bind = $kbShowPanels, global, caelestia:showall
bind = $kbLock, global, caelestia:lock
# Restore lock
bindl = $kbRestoreLock, exec, caelestia shell -d
bindl = $kbRestoreLock, global, caelestia:lock
# Brightness
bindl = , XF86MonBrightnessUp, global, caelestia:brightnessUp
bindl = , XF86MonBrightnessDown, global, caelestia:brightnessDown
# Media
bindl = Ctrl+Super, Space, global, caelestia:mediaToggle
bindl = , XF86AudioPlay, global, caelestia:mediaToggle
bindl = , XF86AudioPause, global, caelestia:mediaToggle
bindl = Ctrl+Super, Equal, global, caelestia:mediaNext
bindl = , XF86AudioNext, global, caelestia:mediaNext
bindl = Ctrl+Super, Minus, global, caelestia:mediaPrev
bindl = , XF86AudioPrev, global, caelestia:mediaPrev
bindl = , XF86AudioStop, global, caelestia:mediaStop
# Kill/restart
bindr = Ctrl+Super+Shift, R, exec, qs -c caelestia kill
bindr = Ctrl+Super+Alt, R, exec, qs -c caelestia kill; caelestia shell -d
# Go to workspace #
$wsaction = ~/.config/hypr/scripts/wsaction.fish
bind = $kbGoToWs, 1, exec, $wsaction workspace 1
bind = $kbGoToWs, 2, exec, $wsaction workspace 2
bind = $kbGoToWs, 3, exec, $wsaction workspace 3
bind = $kbGoToWs, 4, exec, $wsaction workspace 4
bind = $kbGoToWs, 5, exec, $wsaction workspace 5
bind = $kbGoToWs, 6, exec, $wsaction workspace 6
bind = $kbGoToWs, 7, exec, $wsaction workspace 7
bind = $kbGoToWs, 8, exec, $wsaction workspace 8
bind = $kbGoToWs, 9, exec, $wsaction workspace 9
bind = $kbGoToWs, 0, exec, $wsaction workspace 10
# Go to workspace group #
bind = $kbGoToWsGroup, 1, exec, $wsaction -g workspace 1
bind = $kbGoToWsGroup, 2, exec, $wsaction -g workspace 2
bind = $kbGoToWsGroup, 3, exec, $wsaction -g workspace 3
bind = $kbGoToWsGroup, 4, exec, $wsaction -g workspace 4
bind = $kbGoToWsGroup, 5, exec, $wsaction -g workspace 5
bind = $kbGoToWsGroup, 6, exec, $wsaction -g workspace 6
bind = $kbGoToWsGroup, 7, exec, $wsaction -g workspace 7
bind = $kbGoToWsGroup, 8, exec, $wsaction -g workspace 8
bind = $kbGoToWsGroup, 9, exec, $wsaction -g workspace 9
bind = $kbGoToWsGroup, 0, exec, $wsaction -g workspace 10
# Go to workspace -1/+1
bind = Super, mouse_down, workspace, -1
bind = Super, mouse_up, workspace, +1
binde = $kbPrevWs, workspace, -1
binde = $kbNextWs, workspace, +1
binde = Super, Page_Up, workspace, -1
binde = Super, Page_Down, workspace, +1
# Go to workspace group -1/+1
bind = Ctrl+Super, mouse_down, workspace, -10
bind = Ctrl+Super, mouse_up, workspace, +10
# Toggle special workspace
bind = $kbToggleSpecialWs, exec, caelestia toggle specialws
# Move window to workspace #
bind = $kbMoveWinToWs, 1, exec, $wsaction movetoworkspace 1
bind = $kbMoveWinToWs, 2, exec, $wsaction movetoworkspace 2
bind = $kbMoveWinToWs, 3, exec, $wsaction movetoworkspace 3
bind = $kbMoveWinToWs, 4, exec, $wsaction movetoworkspace 4
bind = $kbMoveWinToWs, 5, exec, $wsaction movetoworkspace 5
bind = $kbMoveWinToWs, 6, exec, $wsaction movetoworkspace 6
bind = $kbMoveWinToWs, 7, exec, $wsaction movetoworkspace 7
bind = $kbMoveWinToWs, 8, exec, $wsaction movetoworkspace 8
bind = $kbMoveWinToWs, 9, exec, $wsaction movetoworkspace 9
bind = $kbMoveWinToWs, 0, exec, $wsaction movetoworkspace 10
# Move window to workspace group #
bind = $kbMoveWinToWsGroup, 1, exec, $wsaction -g movetoworkspace 1
bind = $kbMoveWinToWsGroup, 2, exec, $wsaction -g movetoworkspace 2
bind = $kbMoveWinToWsGroup, 3, exec, $wsaction -g movetoworkspace 3
bind = $kbMoveWinToWsGroup, 4, exec, $wsaction -g movetoworkspace 4
bind = $kbMoveWinToWsGroup, 5, exec, $wsaction -g movetoworkspace 5
bind = $kbMoveWinToWsGroup, 6, exec, $wsaction -g movetoworkspace 6
bind = $kbMoveWinToWsGroup, 7, exec, $wsaction -g movetoworkspace 7
bind = $kbMoveWinToWsGroup, 8, exec, $wsaction -g movetoworkspace 8
bind = $kbMoveWinToWsGroup, 9, exec, $wsaction -g movetoworkspace 9
bind = $kbMoveWinToWsGroup, 0, exec, $wsaction -g movetoworkspace 10
# Move window to workspace -1/+1
binde = Super+Alt, Page_Up, movetoworkspace, -1
binde = Super+Alt, Page_Down, movetoworkspace, +1
bind = Super+Alt, mouse_down, movetoworkspace, -1
bind = Super+Alt, mouse_up, movetoworkspace, +1
binde = Ctrl+Super+Shift, right, movetoworkspace, +1
binde = Ctrl+Super+Shift, left, movetoworkspace, -1
# Move window to/from special workspace
bind = Ctrl+Super+Shift, up, movetoworkspace, special:special
bind = Ctrl+Super+Shift, down, movetoworkspace, e+0
bind = Super+Alt, S, movetoworkspace, special:special
# Window groups
binde = $kbWindowGroupCycleNext, cyclenext, activewindow
binde = $kbWindowGroupCycleNext, cyclenext, prev, activewindow
binde = Ctrl+Alt, Tab, changegroupactive, f
binde = Ctrl+Shift+Alt, Tab, changegroupactive, b
bind = $kbToggleGroup, togglegroup
bind = $kbUngroup, moveoutofgroup
bind = Super+Shift, Comma, lockactivegroup, toggle
# Window actions
bind = Super, left, movefocus, l
bind = Super, right, movefocus, r
bind = Super, up, movefocus, u
bind = Super, down, movefocus, d
bind = Super+Shift, left, movewindow, l
bind = Super+Shift, right, movewindow, r
bind = Super+Shift, up, movewindow, u
bind = Super+Shift, down, movewindow, d
binde = Super, Minus, splitratio, -0.1
binde = Super, Equal, splitratio, 0.1
bindm = Super, mouse:272, movewindow
bindm = $kbMoveWindow, movewindow
bindm = Super, mouse:273, resizewindow
bindm = $kbResizeWindow, resizewindow
bind = Ctrl+Super, Backslash, centerwindow, 1
bind = Ctrl+Super+Alt, Backslash, resizeactive, exact 55% 70%
bind = Ctrl+Super+Alt, Backslash, centerwindow, 1
bind = $kbWindowPip, exec, caelestia resizer pip # Move window to picture-in-picture mode
bind = $kbPinWindow, pin
bind = $kbWindowFullscreen, fullscreen, 0
bind = $kbWindowBorderedFullscreen, fullscreen, 1 # Fullscreen with borders
bind = $kbToggleWindowFloating, togglefloating,
bind = $kbCloseWindow, killactive,
bind = Super, J, togglesplit
# Special workspace toggles
bind = $kbSystemMonitor, exec, caelestia toggle sysmon
bind = $kbMusic, exec, caelestia toggle music
bind = $kbCommunication, exec, caelestia toggle communication
bind = $kbTodo, exec, caelestia toggle todo
# Apps
bind = $kbTerminal, exec, app2unit -- $terminal
bind = $kbBrowser, exec, app2unit -- $browser
bind = $kbEditor, exec, app2unit -- $editor
bind = Super, G, exec, app2unit -- github-desktop
bind = $kbFileExplorer, exec, app2unit -- $fileExplorer
bind = Super+Alt, E, exec, app2unit -- nemo
bind = Ctrl+Alt, Escape, exec, app2unit -- qps
bind = Ctrl+Alt, V, exec, app2unit -- pavucontrol
# Utilities
bindl = , Print, exec, caelestia screenshot # Full screen capture > clipboard
bind = Super+Shift, S, global, caelestia:screenshotFreeze # Capture region (freeze)
bind = Super+Shift+Alt, S, global, caelestia:screenshot # Capture region
bind = Super+Alt, R, exec, caelestia record -s # Record screen with sound
bind = Ctrl+Alt, R, exec, caelestia record # Record screen
bind = Super+Shift+Alt, R, exec, caelestia record -r # Record region
bind = Super+Shift, C, exec, hyprpicker -a # Colour picker
# Volume
bindl = , XF86AudioMute, exec, wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle
bindl = Super+Shift, M, exec, wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle
bindle = , XF86AudioRaiseVolume, exec, wpctl set-mute @DEFAULT_AUDIO_SINK@ 0; wpctl set-volume -l 1 @DEFAULT_AUDIO_SINK@ $volumeStep%+
bindle = , XF86AudioLowerVolume, exec, wpctl set-mute @DEFAULT_AUDIO_SINK@ 0; wpctl set-volume @DEFAULT_AUDIO_SINK@ $volumeStep%-
# Sleep
bind = Super+Shift, L, exec, systemctl suspend-then-hibernate
# Clipboard and emoji picker
bind = Super, V, exec, pkill fuzzel || caelestia clipboard
bind = Super+Alt, V, exec, pkill fuzzel || caelestia clipboard -d
bind = Super, Period, exec, pkill fuzzel || caelestia emoji -p
bindl = Ctrl+Shift+Alt, V, exec, sleep 0.5s && ydotool type -d 1 "$(cliphist list | head -1 | cliphist decode)" # Alternate paste
# Testing
bindl = Super+Alt, f12, exec, notify-send -u low -i dialog-information-symbolic 'Test notification' "Here's a really long message to test truncation and wrapping\nYou can middle click or flick this notification to dismiss it!" -a 'Shell' -A "Test1=I got it!" -A "Test2=Another action"