2020-04-29 15:58:14 +00:00
|
|
|
# Basic binds (inspired from the previous i3 config).
|
|
|
|
super + Return
|
2019-12-23 03:44:56 +00:00
|
|
|
$TERMINAL
|
|
|
|
|
2020-04-29 15:58:14 +00:00
|
|
|
# A dropdown terminal.
|
|
|
|
# Requires tmux and tdrop for this to work.
|
2019-12-23 03:44:56 +00:00
|
|
|
super + shift + Return
|
|
|
|
tdrop -ma -w -4 -y "$PANEL_HEIGHT" -s dropterm $TERMINAL
|
|
|
|
|
|
|
|
super + t
|
2020-05-01 14:45:31 +00:00
|
|
|
toggle-process screenkey
|
2019-12-23 03:44:56 +00:00
|
|
|
|
|
|
|
# Application launcher.
|
|
|
|
super + d
|
2020-09-10 19:12:26 +00:00
|
|
|
rofi -show drun -sidebar-mode -theme themes/fds-mini-sidebar
|
2019-12-23 03:44:56 +00:00
|
|
|
|
|
|
|
# User action shortcuts.
|
|
|
|
super + F10
|
2020-04-29 15:58:14 +00:00
|
|
|
user-prompt "Proceed to shutdown?" "sudo -A shutdown 0"
|
2019-12-23 03:44:56 +00:00
|
|
|
|
|
|
|
super + F11
|
2020-04-29 15:58:14 +00:00
|
|
|
user-prompt "Proceed to reboot?" "sudo -A reboot"
|
2019-12-23 03:44:56 +00:00
|
|
|
|
|
|
|
super + F12
|
2020-09-10 19:12:26 +00:00
|
|
|
user-prompt "Exit from X session?" "pkill bspwm"
|
2019-12-23 03:44:56 +00:00
|
|
|
|
2020-04-29 15:58:14 +00:00
|
|
|
# Screenshot and screencast launcher.
|
2020-05-21 15:16:15 +00:00
|
|
|
super + {_, shift + } Print
|
|
|
|
rofi-screenshot-menu {_, --stop && notify-send "All recording has stopped" || notify-send "There's no active recording process"}
|
2019-12-23 03:44:56 +00:00
|
|
|
|
2020-05-21 15:16:15 +00:00
|
|
|
# A bunch of miscellaneous scripts.
|
|
|
|
super + x ; {a, s, d}
|
|
|
|
set -o pipefail && \
|
|
|
|
{ocr | xclip -in -selection clipboard && notify-send "Image content has been copied on the clipboard.", \
|
|
|
|
parse-barcodes | xclip -selection clipboard && notify-send "Bar code content has been copied.", \
|
|
|
|
colorpicker | xclip -selection clipboard && notify-send "Color copied to clipboard."}
|
2019-12-23 03:44:56 +00:00
|
|
|
|
|
|
|
# Miscellaneous shortcuts.
|
|
|
|
super + shift + m
|
2020-05-01 14:45:31 +00:00
|
|
|
choose-manual-menu
|
2020-01-20 09:18:40 +00:00
|
|
|
|
|
|
|
super + shift + e
|
2020-05-01 14:45:31 +00:00
|
|
|
choose-emoji-menu
|
2020-04-29 15:58:14 +00:00
|
|
|
|
2020-09-10 19:12:26 +00:00
|
|
|
super + shift + c
|
|
|
|
$HOME/.config/emacs/bin/org-capture
|
2020-06-05 15:54:56 +00:00
|
|
|
|
2019-12-23 03:44:56 +00:00
|
|
|
shift + super + r
|
2020-04-29 15:58:14 +00:00
|
|
|
pkill -USR1 sxhkd && notify-send "SXHKD config has successfully reloaded."
|
2019-12-23 03:44:56 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
2020-04-29 15:58:14 +00:00
|
|
|
# The usual application suite shortcuts.
|
|
|
|
# I'm separating them according to the keyboard row (in the QWERTY layout anyway).
|
|
|
|
super + a ; {z, x, c, v, b, n, m}
|
2020-05-21 15:16:15 +00:00
|
|
|
{ $TERMINAL -e nvim, code, inkscape, gimp, blender, kdenlive, lmms }
|
2019-12-23 03:44:56 +00:00
|
|
|
|
2020-04-29 15:58:14 +00:00
|
|
|
super + a ; {f, a, d}
|
|
|
|
{ firefox, $TERMINAL -e lf, krita }
|
2019-12-23 03:44:56 +00:00
|
|
|
|
|
|
|
super + a ; {t, r}
|
|
|
|
{ thunderbird, thunar }
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# bspwm exclusive shortcuts.
|
|
|
|
# Feel free to replace these if you're working with another WM/DE.
|
2020-04-29 15:58:14 +00:00
|
|
|
# Over time, I may replace one of the usual shortcut
|
|
|
|
# with something more generally applied (with `xdotool` for example).
|
|
|
|
|
2020-05-21 15:16:15 +00:00
|
|
|
# Close/Kill the focused window.
|
|
|
|
# Difference between closing a window and killing a window is how the process is killed.
|
|
|
|
# Closing a window only terminates the process for that window while killing a window terminates all of the related process of that window.
|
|
|
|
# For example, try opening two Firefox instance and test how it differs.
|
2020-04-29 15:58:14 +00:00
|
|
|
super + {_, shift +} + q
|
2020-05-21 15:16:15 +00:00
|
|
|
bspc node --{close,kill}
|
2019-12-23 03:44:56 +00:00
|
|
|
|
2020-04-29 15:58:14 +00:00
|
|
|
# Move desktop/node view to the specified desktop.
|
2019-12-23 03:44:56 +00:00
|
|
|
super + {_,shift + }{1-9,0}
|
2020-05-21 15:16:15 +00:00
|
|
|
bspc {desktop --focus,node --to-desktop} '^{1-9,10}'
|
2019-12-23 03:44:56 +00:00
|
|
|
|
2020-04-29 15:58:14 +00:00
|
|
|
# Desktop and node movements.
|
2020-04-04 16:27:13 +00:00
|
|
|
super + {_, shift + } Tab
|
|
|
|
bspc desktop {next, prev} --focus
|
2019-12-23 03:44:56 +00:00
|
|
|
|
2020-05-21 15:16:15 +00:00
|
|
|
# less is <, greater is >
|
|
|
|
super + {less, greater}
|
|
|
|
bspc node --to-desktop {prev,next}
|
|
|
|
|
|
|
|
# Window state 'mode'
|
|
|
|
super + z ; {z,x,c,v}
|
|
|
|
bspc node --state {floating,fullscreen,tiled,pseudo_tiled}
|
|
|
|
|
|
|
|
# Window resize 'mode'
|
|
|
|
super + r : {h,j,k,l}
|
|
|
|
bspc node --resize {left -10 0,bottom 0 10,top 0 -10,right 10 0}
|
|
|
|
|
|
|
|
# grave is `
|
|
|
|
super + grave
|
|
|
|
bspc desktop --focus last.occupied
|
2019-12-23 03:44:56 +00:00
|
|
|
|
|
|
|
super + {Up,Down,Left,Right}
|
|
|
|
bspc node {north,south,west,east} --focus
|
|
|
|
|
|
|
|
super + shift {Up,Down,Left,Right}
|
|
|
|
bspc node {north,south,west,east} --swap focused --follow
|
|
|
|
|