This repository has been archived by the owner on Dec 11, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 65
/
Copy pathconfig
342 lines (271 loc) · 11.8 KB
/
config
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
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
# Please see http://i3wm.org/docs/userguide.html for a complete reference!
# setting mod variable to windows key
set $mod Mod4
# https://i3wm.org/docs/userguide.html#_focus_wrapping
force_focus_wrapping yes
# default workspace layout
workspace_layout stacked
# Assume you are on workspace "1: www" and switch to "2: IM" using mod+2
# because somebody sent you a message. You don’t need to remember
# where you came from now, you can just press $mod+2 again to switch back to "1: www".
workspace_auto_back_and_forth yes
# turn on mouse following
focus_follows_mouse yes
# Use Mouse+$mod to drag floating windows to their wanted position
floating_modifier $mod
# start a terminal
bindsym $mod+Return exec alacritty
# kill focused window
bindsym F4 kill
# move focused window
bindsym $mod+Shift+h move left
bindsym $mod+Shift+j move down
bindsym $mod+Shift+k move up
bindsym $mod+Shift+l move right
# resize window (you can also use the mouse for that)
mode "resize" {
# back to normal: Enter or Escape
bindsym Return mode "default"
bindsym Escape mode "default"
bindsym Left resize shrink width 5 px or 5 ppt
bindsym Down resize shrink height 5 px or 5 ppt
bindsym Up resize grow height 5 px or 5 ppt
bindsym Right resize grow width 5 px or 5 ppt
bindsym h resize shrink width 1 px or 1 ppt
bindsym j resize shrink height 1 px or 1 ppt
bindsym k resize grow height 1 px or 1 ppt
bindsym l resize grow width 1 px or 1 ppt
}
# focus the parent container
bindsym $mod+a focus parent
# focus the child container
bindsym $mod+d focus child
# change container layout
bindsym $mod+e layout toggle all
# enter fullscreen mode for the focused container
bindsym $mod+f fullscreen
# change focus
bindsym $mod+h focus left
bindsym $mod+j focus down
bindsym $mod+k focus up
bindsym $mod+l focus right
# split in horizontal orientation
bindsym $mod+t split h
# Resize mode
bindsym $mod+r mode "resize"
# toggle touchpad
bindsym $mod+s exec ~/.i3/touchpad_toggle.sh
# small window for videos
bindsym $mod+u fullscreen disable; floating enable; resize set 422 240; sticky enable; move position 870 25
# split in vertical orientation
bindsym $mod+y split v
# Toggle border
bindsym $mod+x border toggle
# Show the first scratchpad window
bindsym $mod+z scratchpad show
# Lock the system
bindsym $mod+q exec i3lock -i ~/.i3/i3-lock-screen.png -t -f
# toggle tiling / floating
bindsym $mod+Shift+space floating toggle
# change focus between tiling / floating windows
bindsym $mod+space focus mode_toggle
# switch to workspace
bindsym $mod+KP_1 workspace number 1
bindsym $mod+KP_2 workspace number 2
bindsym $mod+KP_3 workspace number 3
bindsym $mod+KP_4 workspace number 4
bindsym $mod+KP_5 workspace number 5
bindsym $mod+KP_6 workspace number 6
bindsym $mod+KP_7 workspace number 7
bindsym $mod+KP_8 workspace number 8
bindsym $mod+KP_9 workspace number 9
bindsym $mod+KP_0 workspace number 0
bindsym $mod+1 workspace number 1
bindsym $mod+2 workspace number 2
bindsym $mod+3 workspace number 3
bindsym $mod+4 workspace number 4
bindsym $mod+5 workspace number 5
bindsym $mod+6 workspace number 6
bindsym $mod+7 workspace number 7
bindsym $mod+8 workspace number 8
bindsym $mod+9 workspace number 9
bindsym $mod+0 workspace number 0
# move focused container to workspace
bindsym $mod+Shift+KP_1 move container to workspace number 1
bindsym $mod+Shift+KP_2 move container to workspace number 2
bindsym $mod+Shift+KP_3 move container to workspace number 3
bindsym $mod+Shift+KP_4 move container to workspace number 4
bindsym $mod+Shift+KP_5 move container to workspace number 5
bindsym $mod+Shift+KP_6 move container to workspace number 6
bindsym $mod+Shift+KP_7 move container to workspace number 7
bindsym $mod+Shift+KP_8 move container to workspace number 8
bindsym $mod+Shift+KP_9 move container to workspace number 8
bindsym $mod+Shift+KP_0 move container to workspace number 8
bindsym $mod+Shift+1 move container to workspace number 1
bindsym $mod+Shift+2 move container to workspace number 2
bindsym $mod+Shift+3 move container to workspace number 3
bindsym $mod+Shift+4 move container to workspace number 4
bindsym $mod+Shift+5 move container to workspace number 5
bindsym $mod+Shift+6 move container to workspace number 6
bindsym $mod+Shift+7 move container to workspace number 7
bindsym $mod+Shift+8 move container to workspace number 8
bindsym $mod+Shift+9 move container to workspace number 9
bindsym $mod+Shift+0 move container to workspace number 0
# restart i3 inplace (preserves your layout/session, can be used to upgrade i3)
bindsym $mod+Shift+r restart
# exit i3 (logs you out of your X session)
bindsym $mod+Shift+e exec "i3-nagbar -t warning -m 'You pressed the exit shortcut. Do you really want to exit i3? This will end your X session.' -b 'Yes, exit i3' 'i3-msg exit'"
mode "mouse" {
# set your three speeds here
set $slow 1
set $quick 10
set $fast 50
# Mouse movement (slow/fine-tuned) -- vim keybindings
bindsym h exec xdotool mousemove_relative -- -$slow 0
bindsym j exec xdotool mousemove_relative 0 $slow
bindsym k exec xdotool mousemove_relative -- 0 -$slow
bindsym l exec xdotool mousemove_relative $slow 0
# Mouse movement (slow/fine-tuned) -- arrow keys
bindsym Left exec xdotool mousemove_relative -- -$slow 0
bindsym Down exec xdotool mousemove_relative 0 $slow
bindsym Up exec xdotool mousemove_relative -- 0 -$slow
bindsym Right exec xdotool mousemove_relative $slow 0
# Mouse movement (quicker) -- vim keybindings
bindsym Shift+h exec xdotool mousemove_relative -- -$quick 0
bindsym Shift+j exec xdotool mousemove_relative 0 $quick
bindsym Shift+k exec xdotool mousemove_relative -- 0 -$quick
bindsym Shift+l exec xdotool mousemove_relative $quick 0
# Mouse movement (quicker) -- arrow keys
bindsym Shift+Left exec xdotool mousemove_relative -- -$quick 0
bindsym Shift+Down exec xdotool mousemove_relative 0 $quick
bindsym Shift+Up exec xdotool mousemove_relative -- 0 -$quick
bindsym Shift+Right exec xdotool mousemove_relative $quick 0
# Mouse movement (fast) -- vim keybindings
bindsym Shift+$mod2+h exec xdotool mousemove_relative -- -$fast 0
bindsym Shift+$mod2+j exec xdotool mousemove_relative 0 $fast
bindsym Shift+$mod2+k exec xdotool mousemove_relative -- 0 -$fast
bindsym Shift+$mod2+l exec xdotool mousemove_relative $fast 0
# Mouse movement (fast) -- arrow keys
bindsym Shift+$mod2+Left exec xdotool mousemove_relative -- -$fast 0
bindsym Shift+$mod2+Down exec xdotool mousemove_relative 0 $fast
bindsym Shift+$mod2+Up exec xdotool mousemove_relative -- 0 -$fast
bindsym Shift+$mod2+Right exec xdotool mousemove_relative $fast 0
# Mouse movement (special down-right)
bindsym m exec xdotool mousemove_relative 10 10
# Left Click
bindsym f exec xdotool click 1
# Middle Click
bindsym d exec xdotool click 2
# Right Click
bindsym s exec xdotool click 3
# Left Click-and-drag
bindsym Shift+f exec xdotool mousedown 1
# Middle Click-and-drag
bindsym Shift+d exec xdotool mousedown 2
# Right Click-and-drag
bindsym Shift+s exec xdotool mousedown 3
# Left Drag release
bindsym $mod2+f exec xdotool mouseup 1
# Middle Drag release
bindsym $mod2+d exec xdotool mouseup 2
# Right Drag release
bindsym $mod2+s exec xdotool mouseup 3
# return to normal keybindings -- IMPORTANT!!
bindsym Escape mode "default"
}
# this serves as the exhaustive collection of things one can do with workspaces
mode "workspace" {
bindsym Left workspace prev_on_output
bindsym Right workspace next_on_ouput
bindsym Down workspace prev
bindsym Up workspace next
bindsym Tab layout toggle all
bindsym r exec i3-input -F 'rename workspace to "%s"' -P 'New name: '
bindsym ',' move workspace to output left
bindsym '.' move workspace to output right
# back to normal: Enter or Escape
bindsym Return mode "default"
bindsym Escape mode "default"
}
# Font for window titles. Will also be used by the bar unless a different font
# is used in the bar {} block below.
# This font is widely installed, provides lots of unicode glyphs, right-to-left
# text rendering and scalability on retina/hidpi displays (thanks to pango).
# font pango:DejaVu Sans Mono 8
font pango:Source Code Pro 7
# window (client) colors
# class border backgr. text indicator
client.focused #000000 #0088CC #ffffff #dddddd
client.focused_inactive #000000 #333333 #888888 #292d2e
client.unfocused #000000 #333333 #888888 #292d2e
client.urgent #2f343a #900000 #ffffff #900000
# Start i3bar to display a workspace bar (plus the system information i3status
# finds out, if available)
bar {
font pango:Source Code Pro 10, Awesome 10
status_command i3blocks -c ~/.i3/i3blocks.conf
tray_output primary
position top
colors {
# colorclass border background text
background #222222
statusline #dddddd
separator #666666
focused_workspace #0088CC #0088CC #ffffff
active_workspace #333333 #333333 #ffffff
inactive_workspace #333333 #333333 #888888
urgent_workspace #2f343a #900000 #ffffff
}
}
# Make the currently focused window a scratchpad
bindsym $mod+Shift+z move scratchpad
# Hides vertical and horizontal borders when there's only one window.
# hide_edge_borders both
hide_edge_borders none
# window border size
new_window pixel 1
# multi display workflow scripts
bindsym $mod+Shift+p exec python3 ~/.i3/i3_wm_multi_disp_scripts/create_new_project.py
bindsym $mod+p exec python3 ~/.i3/i3_wm_multi_disp_scripts/switch_to_next_project.py
bindsym $mod+Shift+Tab exec python3 ~/.i3/i3_wm_multi_disp_scripts/move_workspaces_in_project_to_next_output.py
bindsym $mod+Control+Tab exec python3 ~/.i3/i3_wm_multi_disp_scripts/move_current_container_to_next_workspace_in_project.py
bindsym $mod+o exec python3 ~/.i3/i3_wm_multi_disp_scripts/rename_project.py
bindsym F8 exec python3 ~/.i3/i3_wm_multi_disp_scripts/bring_container_to_current_workspace.py
bindsym $mod+Tab exec ~/.i3/i3_wm_multi_disp_scripts/switcher.sh
# rofi bindings
bindsym F9 exec "rofi -show-icons -modi combi -show combi -combi-modi run,drun"
bindsym F12 exec rofi -show-icons -show window
# volume
bindsym XF86AudioLowerVolume exec ~/.i3/volume_decrease.sh
bindsym XF86AudioRaiseVolume exec ~/.i3/volume_increase.sh
bindsym XF86AudioMute exec ~/.i3/volume_mute.sh
# music
bindsym XF86AudioPlay exec playerctl 'play-pause'
bindsym XF86AudioNext exec playerctl next
bindsym XF86AudioPrev exec playerctl previous
# brightness
bindsym XF86MonBrightnessDown exec ~/.i3/brightness_decrease.sh
bindsym XF86MonBrightnessUp exec ~/.i3/brightness_increase.sh
# create initial workspaces
exec --no-startup-id python3 ~/.i3/i3_wm_multi_disp_scripts/create_new_project.py main
# start applications
exec --no-startup-id dunst
exec --no-startup-id nm-applet
exec --no-startup-id pasystray
exec --no-startup-id dropbox start
exec --no-startup-id google-chrome
exec --no-startup-id numlockx on
exec --no-startup-id alacritty
exec --no-startup-id nemo
exec --no-startup-id xbindkeys -f ~/.xbindkeysrc
popup_during_fullscreen leave_fullscreen
show_marks yes
# Disable floating for nemo windows
for_window [class="Nemo" instance="^desktop_window$"] floating disable
# chrome extension popups
for_window [instance="^crx.*$" window_role="pop-up"] floating enable
for_window [instance="^crx.*$" window_role="pop-up"] sticky enable
# Prepend title with program name
for_window [class=".*"] title_format "%class - %title"
# Solid wallpaper
exec --no-startup-id xsetroot -solid "#333333"