08338d92e4dd6ecfde0803efe4eeb95ed6eca666
[~bandali/configs] / sxhkd / .config / sxhkd / sxhkdrc
1 #
2 # wm independent hotkeys
3 #
4
5 # terminal emulator
6 #super + {_,shift} + Return
7 # urxvt{_, -name tiled}
8
9 super + {_,shift} + Return
10 termite{_, --name=tiled}
11
12 # program launcher
13 super + space
14 rofi -show run
15
16 super + alt + space
17 xfce4-popup-whiskermenu
18
19 # window finder
20 super + backslash
21 rofi -show window
22
23 # password manager
24 super + shift + space
25 rofi-pass
26
27 # firefox
28 #super + r
29 # firefox
30
31 # chromium
32 #super + c
33 # chromium -incognito
34
35 # emacs
36 super + e
37 emacs
38
39 # make sxhkd reload its configuration files:
40 super + Escape
41 pkill -USR1 -x sxhkd
42
43 # volume {up,down}
44 XF86Audio{Raise,Lower}Volume
45 pamixer --allow-boost --{in,de}crease 5
46
47 # mute
48 XF86AudioMute
49 pamixer --toggle-mute
50
51 # playback control
52 XF86Audio{Play,Prev,Next}
53 mpc {toggle,prev,next}
54
55 # lock the screen
56 super + shift + q
57 light-locker-command -l
58
59 # Toggle keyboard layout
60 XF86LaunchA
61 toggle-layout
62
63 # Toggle Xfce presentation mode
64 XF86LaunchB
65 toggle-presentation-mode
66
67 # monitor brightness
68 XF86MonBrightness{Up,Down}
69 light -s mba6x_backlight -{A,U} 5
70
71 # keyboard brightness
72 #XF86KbdBrightness{Up,Down}
73 # kbdlight {up,down}
74
75 #
76 # bspwm hotkeys
77 #
78
79 # quit bspwm normally
80 super + alt + Escape
81 bspc quit
82
83 # close and kill
84 super + {w,q}
85 bspc node -{c,k}
86
87 # alternate between the tiled and monocle layout
88 super + m
89 bspc desktop -l next
90
91 # if the current node is automatic, send it to the last manual, otherwise pull the last leaf
92 super + y
93 bspc query -N -n focused.automatic && bspc node -n last.!automatic || bspc node last.leaf -n focused
94
95 # swap the current node and the biggest node
96 super + g
97 bspc node -s biggest
98
99 #
100 # state/flags
101 #
102
103 # set the window state
104 super + {t,shift + t,s,f}
105 bspc node -t {tiled,pseudo_tiled,floating,fullscreen}
106
107 # set the node flags
108 super + ctrl + {x,y,z}
109 bspc node -g {locked,sticky,private}
110
111 #
112 # focus/swap
113 #
114
115 # focus the node in the given direction
116 super + {_,shift + }{h,j,k,l}
117 bspc node -{f,s} {west,south,north,east}
118
119 # focus the node for the given path jump
120 super + {p,b,comma,period}
121 bspc node -f @{parent,brother,first,second}
122
123 # focus the next/previous node in the current desktop
124 super + {_,shift + }c
125 bspc node -f {next,prev}.local
126
127 # focus the next/previous desktop in the current monitor
128 super + bracket{left,right}
129 bspc desktop -f {prev,next}.local
130
131 # send to next/prev desktop
132 super + shift + bracket{left,right}
133 bspc node -d {prev,next}
134
135 # focus the last node/desktop
136 super + {grave,Tab}
137 bspc {node,desktop} -f last
138
139 # focus the older or newer node in the focus history
140 super + {o,i}
141 bspc wm -h off; \
142 bspc node {older,newer} -f; \
143 bspc wm -h on
144
145 # focus or send to the given desktop
146 super + {_,shift + }{1-9,0}
147 bspc {desktop -f,node -d} '^{1-9,10}'
148
149 #
150 # preselect
151 #
152
153 # preselect the direction
154 super + ctrl + {h,j,k,l}
155 bspc node -p {west,south,north,east}
156
157 # preselect the ratio
158 super + ctrl + {1-9}
159 bspc node -o 0.{1-9}
160
161 # cancel the preselection for the focused node
162 super + ctrl + space
163 bspc node -p cancel
164
165 # cancel the preselection for the focused desktop
166 super + ctrl + shift + space
167 bspc query -N -d | xargs -I id -n 1 bspc node id -p cancel
168
169 #
170 # move/resize
171 #
172
173 # expand a window by moving one of its side outward
174 super + alt + {h,j,k,l}
175 bspc node -z {left -20 0,bottom 0 20,top 0 -20,right 20 0}
176
177 # contract a window by moving one of its side inward
178 super + alt + shift + {h,j,k,l}
179 bspc node -z {right -20 0,top 0 20,bottom 0 -20,left 20 0}
180
181 # move a floating window
182 super + {Left,Down,Up,Right}
183 bspc node -v {-20 0,0 20,0 -20,20 0}