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
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
|
# sway configuration file
# man sway(5)
# ================================================================================
# output device configuration
# man sway-output(5)
# ================================================================================
# force_xinerama yes
# fake-outputs 3840x1080+0+0
include /home/max/.local/share/base16/base16-sway/themes/base16-tomorrow-night.config
include config_exec
output LVDS-1 {
# pos 0 420
pos 0 0
# res 1920x1080
# background ~/.local/share/backgrounds/02-procrastination-hd1080.png center $base01
background ~/.local/share/backgrounds/osb3unzg9j941-1280.png stretch $base01
dpms on
}
input * xkb_layout "us"
input * xkb_variant "altgr-intl"
# input * xkb_options "grp:win_space_toggle"
# input "MANUFACTURER1 Keyboard" xkb_model "pc101"
# finally keyboard configuration in sway :)
# input 1:1:AT_Translated_Set_2_keyboard {
# xkb_layout us,de
# xkb_variant intl
# # xkb_options grp:alt_shift_toggle
# }
# output DP-1 {
# pos 1920 0
# res 1920x1080
# background ~/.local/share/backgrounds/IMG_5625.JPG fill
# # transform 270
# dpms on
# }
# ================================================================================
# Workspace settings
# ================================================================================
workspace 1 output VGA1
workspace_layout tabbed
# customize workspace names
set $WS0 0:π
set $WS1 1:β
set $WS2 2:β
set $WS3 3:β
set $WS4 4:β
set $WS5 5:β
set $WS6 6:β
set $WS7 7:β
set $WS8 8:β
set $WS9 9:β
workspace $WS0 output XWAYLAND1 HDMI-1 DP-1 VGA-1
workspace $WS1 output primary
workspace $WS9 output XWAYLAND1 HDMI-1 DP-1 VGA-1
bindsym Mod4+BackSpace exec i3-msg move workspace to output right
# switch to workspace
bindsym Mod4+0 workspace $WS0
bindsym Mod4+1 workspace $WS1
bindsym Mod4+2 workspace $WS2
bindsym Mod4+3 workspace $WS3
bindsym Mod4+4 workspace $WS4
bindsym Mod4+5 workspace $WS5
bindsym Mod4+6 workspace $WS6
bindsym Mod4+7 workspace $WS7
bindsym Mod4+8 workspace $WS8
bindsym Mod4+9 workspace $WS9
# move focused container to workspace
bindsym Mod4+Shift+0 move container to workspace $WS0
bindsym Mod4+Shift+1 move container to workspace $WS1
bindsym Mod4+Shift+2 move container to workspace $WS2
bindsym Mod4+Shift+3 move container to workspace $WS3
bindsym Mod4+Shift+4 move container to workspace $WS4
bindsym Mod4+Shift+5 move container to workspace $WS5
bindsym Mod4+Shift+6 move container to workspace $WS6
bindsym Mod4+Shift+7 move container to workspace $WS7
bindsym Mod4+Shift+8 move container to workspace $WS8
bindsym Mod4+Shift+9 move container to workspace $WS9
# ================================================================================
# base16 Xressource depenend color configuration
# with default values from base16-tomorrow-night
# ================================================================================
xwayland enable
# hide_edge_borders both
title_align left
# gaps inner 6
# smart_gaps on
# smart_borders no_gaps
# focus_follows_mouse no
# mouse_warping none
# we basically want to configure our font with ~/.config/fontconfig/* and can
# configure what is called monospace that way. It is more portable that way.
font pango:sans 9
# font pango:FuraCode Nerd Font Mono Medium 11
# font pango:monospace 9
# font pango:GoMono Nerd Font 9
# font pango:FuraCode Nerd Font Mono 9
# font pango:Code New Roman Nerd Font 9
include /home/max/.config/base16/base16-sway/themes/base16-tomorrow.config
# main variables ssource default
# d variable default
set $background $base01
set $foreground $base05
set $cursorColor $foreground
# set_from_resource $foreground base16.cursor $cursorColor
# set_from_resource $foreground base16.cursor $base05
# Basic bar configuration using the Base16 variables.
bar {
# status_command i3status --config ~/.config/i3/i3status.conf
font pango:monospace 9
status_command i3status --config ~/.config/i3/i3status.conf
# swaybar_command swaybar
tray_padding 2
tray_output DP-1
mode dock
strip_workspace_numbers yes
# separator_symbol "|"
separator_symbol " "
colors {
background #000000cc
separator $foreground
statusline $foreground
focused_workspace $background $background $base05
active_workspace $background $background $cursorColor
inactive_workspace $background $background $base03
urgent_workspace $background $background $base08
binding_mode $background $background $foreground
}
}
# Basic color configuration using the Base16 variables for windows and borders.
# Property Name Border BG Text Indicator Child Border
client.focused $base05 $base0D $base00 $base0D $base0D
client.focused_inactive $base01 $base01 $base05 $base03 $base01
client.unfocused $base01 $base00 $base05 $base01 $base01
client.urgent $base08 $base08 $base00 $base08 $base08
client.placeholder $base00 $base00 $base05 $base00 $base00
client.background $background
# ================================================================================
# windows assignments and special treatment, e.g. icons
# ================================================================================
assign [class="^Pidgin"] $WS0
assign [class="^Hexchat"] $WS0
assign [class="(?i)pidgin"] $WS0
assign [class="^Thunderbird$"] $WS0
assign [title="(?i)weechat"] $WS0
# for_window [class="^.*"] border normal 3
# for_window [title="^.*Thunderbird"] border pixel 0
# for_window [title="^.*Chromium"] border pixel 0
# for_window [class="Gvim"] border pixel 0
for_window [title="(?i)Evolution"] title_format "π§ %title"
for_window [app_id="firefox"] title_format "ο© %title"
for_window [app_id="firefox"] border pixel 5
for_window [class="(?i)chromium"] title_format "ο¨ %title"
for_window [class="(?i)hexchat"] title_format "ο¦ %title"
for_window [class="(?i)pidgin"] title_format "π₯ %title"
for_window [app_id="thunar"] title_format "ποΈ %title"
for_window [app_id="keepassxc"] title_format "π %title"
for_window [class="(?i).*terminal?"] title_format "ο %title"
for_window [class="(?i).*termite?"] title_format "ο %title"
for_window [class="(?i)xfce4-appfinder"] title_format "οΊ %title"
for_window [class="(?i)thunderbird"] title_format "ο %title"
for_window [title="(?i)weechat"] title_format "ο¦ %title"
for_window [title="YouTube"] title_format "ο
§ %title"
for_window [title="ξ
"] title_format "%title"
for_window [title="ο "] title_format "%title"
for_window [title="ο "] border pixel 0
for_window [app_id=".*terminal"] border pixel 0
# for_window [class="(?i)xfce4-terminal"] border pixel 0
# for_window [class="(?i)xfce4-appfinder"] border pixel 0
# for_window [title="^.*\|"] border pixel 4
# for_window [title="^HexChat.*"] border pixel 0
# for_window [title="^.*"] exec pkill -SIGRTMIN+11 i3blocks
# for_window [title="^.*"] exec pkill -SIGRTMIN+11 i3blocks
# for_window [title="cairo-dock"] floating enable ; border none
# for_window[class="Plank"] floating enable,move absolute center
# for_window [class=".*"] title_format "β %title"
# for_window [con_id="__focused__"] title_format "<u>%title</u>"
# ================================================================================
# Keyboard mappings
# Mod1 ctrl
# Mod4 windows key
# ================================================================================
set $mod Mod4
bindsym $mod+j "mark --toggle a"
bindsym Pause exec grim -t png "/tmp/$(date '+%Y-%m-%d %H:%M:%S').png"
# Use Mouse+$mod to drag floating windows to their wanted position
floating_modifier $mod
# restart sway or reload config
bindsym $mod+Shift+c reload
bindsym $mod+Shift+r restart
# kill focused window
bindsym $mod+Shift+q kill
bindsym Mod1+F4 kill
bindsym $mod+F2 exec i3-input -F 'rename workspace to "%s"' -P 'New name: '
bindsym Control+Mod1+Left workspace prev_on_output
bindsym Control+Mod1+Right workspace next_on_output
# 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
bindsym $mod+Tab focus output right
bindsym $mod+Shift+Tab focus output left
bindsym mod1+Tab focus right
bindsym mod1+Shift+Tab focus left
bindsym $mod+Next focus child
bindsym $mod+Left focus left
bindsym $mod+Right focus right
bindsym $mod+Down focus down
bindsym $mod+Up focus up
bindsym $mod+Prior focus parent
bindsym $mod+a focus parent
# alternatively, you can use the cursor keys:
bindsym $mod+Shift+Left move left ; exec pkill -SIGRTMIN+11 i3blocks
bindsym $mod+Shift+Down move down ; exec pkill -SIGRTMIN+11 i3blocks
bindsym $mod+Shift+Up move up ; exec pkill -SIGRTMIN+11 i3blocks
bindsym $mod+Shift+Right move right ; exec pkill -SIGRTMIN+11 i3blocks
# change container layout (stacked, tabbed, toggle split)
bindsym $mod+s layout stacking
bindsym $mod+w layout tabbed
bindsym $mod+q layout toggle split
bindsym $mod+x layout toggle all
bindsym $mod+v split toggle
bindsym $mod+space split toggle
# enter fullscreen mode for the focused container
bindsym $mod+f fullscreen toggle
bindsym $mod+g fullscreen toggle global
# toggle tiling / floating
bindsym $mod+Shift+space floating toggle
bindsym $mod+m move scratchpad
bindsym $mod+Shift+m scratchpad show ; resize set 1920 920 ; move position center
# start a terminal
# bindsym $mod+Return exec i3-sensible-terminal
# bindsym $mod+Return exec "killall rofi ; rofi -show drun -show-icons"
bindsym $mod+Return exec dmenu_run
bindsym Mod1+F2 exec "killall rofi ; rofi -show drun -bg #222222 -fg #888888 -hlbg #285577 -hlfg #ffffff -show-icons -5"
bindsym $mod+t exec xfce4-terminal
bindsym $mod+y exec gnome-terminal
bindsym $mod+e exec thunar
bindsym $mod+l exec swaylock -K -f -F -c "#000000" --text-color '#ffffff' --indicator-radius 200 --indicator-thickness 10
bindsym $mod+d exec i3-dmenu-desktop
# Pulse Audio controls
bindsym $mod+F10 exec pactl set-sink-mute @DEFAULT_SINK@ toggle
bindsym $mod+F11 exec pactl set-sink-volume @DEFAULT_SINK@ -5%
bindsym $mod+F12 exec pactl set-sink-volume @DEFAULT_SINK@ +5%
bindsym XF86AudioRaiseVolume exec pactl set-sink-volume @DEFAULT_SINK@ +5%
bindsym XF86AudioLowerVolume exec pactl set-sink-volume @DEFAULT_SINK@ -5%
bindsym XF86AudioMute exec pactl set-sink-mute @DEFAULT_SINK@ toggle
# change focus between tiling / floating windows
# bindsym $mod+space focus mode_toggle
# focus the child container
#bindsym $mod+d focus child
# 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'"
# bindsym $mod+Shift+e exec "sway-nag 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'"
bindsym $mod+Shift+e exec swaynag --font "monospace 8" --background 000000 --button-background 000000 --button-border-size 1 --border aaaaaa -b yes "swaymsg exit" -s 'no' -m 'Do you really want to quit sway?'
# split in horizontal orientation
# bindsym $mod+h split h
# split in vertical orientation
# bindsym $mod+v split v
# resize window (you can also use the mouse for that)
bindsym $mod+r mode "resize"
mode "resize" {
# These bindings trigger as soon as you enter the resize mode
# Pressing left will shrink the windowβs width.
# Pressing right will grow the windowβs width.
# Pressing up will shrink the windowβs height.
# Pressing down will grow the windowβs height.
bindsym $mod+h resize shrink width 4 px or 4 ppt
bindsym $mod+j resize grow height 4 px or 4 ppt
bindsym $mod+k resize shrink height 4 px or 4 ppt
bindsym $mod+l resize grow width 4 px or 4 ppt
# same bindings, but for the arrow keys
bindsym Left resize shrink width 4 px or 4 ppt
bindsym Up resize grow height 4 px or 4 ppt
bindsym Down resize shrink height 4 px or 4 ppt
bindsym Right resize grow width 4 px or 4 ppt
# back to normal: Enter or Escape
bindsym Return mode "default"
bindsym Escape mode "default"
}
set $mode_brightness "display brightness π
π"
bindsym $mod+b mode $mode_brightness
mode $mode_brightness {
bindsym Up exec xrandr-brightness .1
bindsym Down exec xrandr-brightness -.1
bindsym Return mode "default"
bindsym Escape mode "default"
}
# Press $mod+o followed by either f, t, Escape or Return to launch firefox,
# thunderbird or return to the default mode, respectively.
set $mode_launcher Launch: [f]irefox [t]hunderbird
bindsym $mod+o mode "$mode_launcher"
mode "$mode_launcher" {
bindsym f exec firefox
bindsym t exec thunderbird
bindsym Escape mode "default"
bindsym Return mode "default"
}
# bindsym $mod+d exec --no-startup-id j4-dmenu-desktop
# exec xrandr --dpi 95.48 --output LVDS-1 --mode 1024x768 && xrandr --output LVDS-1 --mode 1280x800
# bindcode 156
# ================================================================================
# Execute (autostart) further applications
#! exec: execute when starting
#! exec_always: execute when starting or restarting
# ================================================================================
# input 16700:8467:Dell_KB216_Wired_Keyboard_Consumer_Control {
# xkb_layout "us"
# xkb_variant "altgr-intl,nodeadkeys"
# xkb_options "keypad:pointerkeys,grp_led:caps,grp:caps_toggle,terminate:ctrl_alt_bksp"
# xkb_model "pc105"
# xkb_numlock "enable"
# repeat_delay 100
# repeat_rate 330
# }
# vim: iskeyword+=\$,\-,\#,(,) nospell ft=tcl
|