blob: 838c78e1e57693052e2651bb67f794f9ddc0dd64 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
|
# vim: ft=i3config
# Basics {{{
bindsym $mod+Return exec swx -a $term
bindsym $mod+Shift+Return exec $floating_term
bindsym $mod+b exec pkill -USR1 waybar
bindsym $mod+w exec $firefox
bindsym $mod+Shift+w exec $firefox --private-window
# kill focused window
bindsym $mod+Shift+q kill
# start your launcher
bindsym $mod+d exec $run_menu
bindsym $mod+Shift+d exec $menu
bindsym $mod+o exec fs
# Drag floating windows by holding down $mod and left mouse button.
# Resize them with right mouse button + $mod.
# Despite the name, also works for non-floating windows.
# Change normal to inverse to use left mouse button for resizing and right
# mouse button for dragging.
floating_modifier $mod normal
# reload the configuration file
bindsym $mod+Shift+c reload
# exit sway (logs you out of your wayland session)
bindsym $mod+Shift+e exec swaynag \
-t warning \
-m 'exit: what now?' \
-b 'exit' 'swaymsg exit' \
-b 'poweroff' 'daos poweroff' \
-b 'reboot' 'doas reboot'
bindsym $mod+Shift+backspace exec lock
bindsym Print exec grimshot copy output
bindsym $mod+Shift+s mode "screengrab"
mode "screengrab" {
bindsym a exec grimshot save screen; mode "default"
bindsym o exec grimshot save output; mode "default"
bindsym s exec grimshot save area; mode "default"
bindsym c exec grimshot copy area; mode "default"
bindsym p exec colorpick; mode "default"
bindsym Escape mode "default"
}
bindsym $mod+Shift+b border toggle
bindsym $mod+Shift+r output - transform 90 clockwise
bindsym $mod+Shift+a exec soundswitch
# }}}
# Moving around {{{
# Move your focus around
bindsym $mod+$left focus left
bindsym $mod+$down focus down
bindsym $mod+$up focus up
bindsym $mod+$right focus right
# or use $mod+[up|down|left|right]
# _move_ the focused window with the same, but add Shift
bindsym $mod+Shift+$left move left
bindsym $mod+Shift+$down move down
bindsym $mod+Shift+$up move up
bindsym $mod+Shift+$right move right
bindsym $mod+Next focus child
bindsym $mod+Prior focus parent
bindsym $mod+Escape [urgent="latest"] focus
# }}}
# Workspaces {{{
# Note: workspaces can have any name you want, not just numbers.
# We just use 1-10 as the default.
bindsym $mod+Shift+comma workspace prev
bindsym $mod+Shift+period workspace next
# switch to workspace
bindsym $mod+1 workspace $ws1
bindsym $mod+2 workspace $ws2
bindsym $mod+3 workspace $ws3
bindsym $mod+4 workspace $ws4
bindsym $mod+5 workspace $ws5
bindsym $mod+6 workspace $ws6
bindsym $mod+7 workspace $ws7
bindsym $mod+8 workspace $ws8
bindsym $mod+9 workspace $ws9
bindsym $mod+0 workspace $ws0
bindsym $mod+Ctrl+m workspace $wsMusic
bindsym $mod+Ctrl+v workspace $wsVideo
bindsym $mod+Ctrl+g workspace $wsGame
bindsym $mod+Tab workspace back_and_forth
# move focused container to workspace
bindsym $mod+Shift+1 move container to workspace $ws1
bindsym $mod+Shift+2 move container to workspace $ws2
bindsym $mod+Shift+3 move container to workspace $ws3
bindsym $mod+Shift+4 move container to workspace $ws4
bindsym $mod+Shift+5 move container to workspace $ws5
bindsym $mod+Shift+6 move container to workspace $ws6
bindsym $mod+Shift+7 move container to workspace $ws7
bindsym $mod+Shift+8 move container to workspace $ws8
bindsym $mod+Shift+9 move container to workspace $ws9
bindsym $mod+Shift+0 move container to workspace $ws0
# move focused workspce to output
bindsym $mod+Ctrl+$left move workspace to output left
bindsym $mod+Ctrl+$down move workspace to output down
bindsym $mod+Ctrl+$up move workspace to output up
bindsym $mod+Ctrl+$right move workspace to output right
# }}}
# Layout stuff {{{
bindsym $mod+Minus splitv
bindsym $mod+Backslash splith
# bindsym $mod+Bracketleft splitv
# bindsym $mod+Bracketright splith
bindsym $mod+g layout toggle split
mode "swap" {
bindsym $left move left ; focus right ; mode "default"
bindsym $down move down ; focus up ; mode "default"
bindsym $up move up ; focus down ; mode "default"
bindsym $right move right ; focus left ; mode "default"
# return to default mode
bindsym Return mode "default"
bindsym Escape mode "default"
}
bindsym $mod+i mode "swap"
# Make the current focus fullscreen
bindsym $mod+f fullscreen
bindsym $mod+Shift+f fullscreen global
# Hide the topbar (also gets you more space)
bindsym $mod+Shift+t bar mode toggle topbar; default_border pixel
# Swap focus between the tiling area and the floating area
bindsym $mod+space focus mode_toggle
# Toggle the current focus between tiling and floating mode
bindsym $mod+Ctrl+space floating toggle
mode "layout" {
# Switch the current container between different layout styles
bindsym s layout stacking; mode "default"
bindsym w layout tabbed; mode "default"
bindsym e layout splitv; mode "default"
# move focus to the parent container
bindsym p focus parent
bindsym Shift+p focus child
# make a sticky container
bindsym t sticky toggle; mode "default"; exec notify-send "container sticky'd"
bindsym Shift+t \
floating enable; \
sticky enable; \
exec sh -c 'centercon -w 0.3 tr && swaymsg move left 10px && swaymsg move down 10px && swaymsg focus mode_toggle'; \
mode "default"
# make a centered container
bindsym c exec centercon 1.0; mode "default"
bindsym Shift+c exec centercon -w 0.5; mode "default"
# return to default mode
bindsym Return mode "default"
bindsym Escape mode "default"
}
bindsym $mod+y mode "layout"
# }}}
# Scratchpad {{{
# Sway has a "scratchpad", which is a bag of holding for windows.
# You can send windows there and get them back later.
# Move the currently focused window to the scratchpad
bindsym $mod+Ctrl+backspace move scratchpad
# Show the next scratchpad window or hide the focused scratchpad window.
# If there are multiple scratchpad windows, this command cycles through them.
bindsym $mod+backspace scratchpad show
# }}}
# Resizing containers {{{
mode "resize" {
set $rate 25
bindsym $left resize shrink width $rate
bindsym $down resize grow height $rate
bindsym $up resize shrink height $rate
bindsym $right resize grow width $rate
bindsym Shift+$down resize shrink width $rate; resize shrink height $rate
bindsym Shift+$up resize grow width $rate; resize grow height $rate
# return to default mode
bindsym Return mode "default"
bindsym Escape mode "default"
}
bindsym $mod+r mode "resize"
# }}}
# Gaps {{{
mode "gaps" {
bindsym r gaps outer all set 0; gaps inner all set 0
set $gapRate 5
bindsym $up gaps inner all plus $gapRate
bindsym $down gaps inner all minus $gapRate
# return to default mode
bindsym Return mode "default"
bindsym Escape mode "default"
}
bindsym $mod+Shift+g mode "gaps"
# }}}
# Misc {{{
bindsym $mod+Shift+x mark --toggle "x"
bindsym $mod+x [con_mark="x"] focus
bindsym $mod+Ctrl+x swap container with mark "x"
# Media volume controls
bindsym XF86AudioMute exec soundswitch -m
bindsym XF86AudioMicMute exec soundswitch -M
bindsym XF86AudioLowerVolume exec soundswitch -v
bindsym XF86AudioRaiseVolume exec soundswitch -V
# Sreen brightness controls
bindsym XF86MonBrightnessUp exec light -A 5
bindsym XF86MonBrightnessDown exec light -U 5
# Media player controls
bindsym XF86AudioPlay exec playerctl -p playerctld play-pause
bindsym XF86AudioNext exec playerctl -p playerctld next
bindsym XF86AudioPrev exec playerctl -p playerctld previous
bindsym XF86WakeUp exec true
# switch video mode
bindsym XF86Display exec sh -c 'killall kanshi; exec kanshi'
# config
bindsym XF86Tools exec true
# keyboard
bindsym XF86Keyboard exec light -S 0
# bookmarks
bindsym XF86Favorites exec light -S 100
# }}}
|