rc

config

1
# Logo key. Use Mod1 for Alt.
2
set $mod Mod4
3
# Home row direction keys, like vim
4
set $left h
5
set $down j
6
set $up k
7
set $right l
8
# Your preferred terminal emulator
9
set $term urxvt
10
# Your preferred application launcher
11
set $menu rofi -show run 
12
13
14
# start a terminal
15
bindsym $mod+Return exec $term
16
17
# kill focused window
18
bindsym $mod+Shift+q kill
19
20
# start your launcher
21
bindsym $mod+d exec $menu
22
23
# Start GNU Emacs
24
bindsym $mod+m exec emacsclient -nc -s gnuemacs
25
26
# Mouse+$mod to drag floating windows
27
floating_modifier $mod
28
29
# Lock screen
30
bindsym $mod+i exec i3lock-wrapper
31
32
# reload the configuration file
33
bindsym $mod+Shift+c reload
34
# restart i3 inplace (preserves your layout/session, can be used to upgrade i3)
35
bindsym $mod+Shift+r restart
36
# exit i3 (logs you out of your X session)
37
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'"
38
39
# Managing outputs
40
output eDP-1 {
41
    # My current system doesn't support HiDPI. If I get such a system in the
42
    # future, the following lines can "activate" that.
43
    #scale 2
44
    #pos 0 0 res 3840x2160
45
    pos 0 0 res 1920x1080
46
    # Only thing that this lacks compared to Feh is that this can't deal with
47
    # directories, oh well.
48
    #bg ~/.wallpapers/* stretch
49
    bg ~/.wallpapers/generalp.png stretch
50
}
51
# xkb_layout Sets keyboard to qwerty, just to be sure
52
# xkb_model: Fallback model for now, I don't know mine for sure
53
# Makes every button exponentially more useful
54
# Because who really uses capslock
55
input 1:1:AT_Translated_Set_2_keyboard {
56
    xkb_layout us
57
    xkb_model pc105
58
    xkb_variant altgr-intl
59
    xkb_options caps:swapescape
60
    }
61
#
62
# Moving around:
63
#
64
    # Move your focus around
65
    bindsym $mod+$left focus left
66
    bindsym $mod+$down focus down
67
    bindsym $mod+$up focus up
68
    bindsym $mod+$right focus right
69
    # or use $mod+[up|down|left|right]
70
    bindsym $mod+Left focus left
71
    bindsym $mod+Down focus down
72
    bindsym $mod+Up focus up
73
    bindsym $mod+Right focus right
74
75
    # _move_ the focused window with the same, but add Shift
76
    bindsym $mod+Shift+$left move left
77
    bindsym $mod+Shift+$down move down
78
    bindsym $mod+Shift+$up move up
79
    bindsym $mod+Shift+$right move right
80
    # ditto, with arrow keys
81
    bindsym $mod+Shift+Left move left
82
    bindsym $mod+Shift+Down move down
83
    bindsym $mod+Shift+Up move up
84
    bindsym $mod+Shift+Right move right
85
#
86
# Workspaces:
87
#
88
    # switch to workspace
89
    bindsym $mod+1 workspace 1
90
    bindsym $mod+2 workspace 2
91
    bindsym $mod+3 workspace 3
92
    bindsym $mod+4 workspace 4
93
    bindsym $mod+5 workspace 5
94
    bindsym $mod+6 workspace 6
95
    bindsym $mod+7 workspace 7
96
    bindsym $mod+8 workspace 8
97
    bindsym $mod+9 workspace 9
98
    bindsym $mod+0 workspace 10
99
    # move focused container to workspace
100
    bindsym $mod+Shift+1 move container to workspace 1
101
    bindsym $mod+Shift+2 move container to workspace 2
102
    bindsym $mod+Shift+3 move container to workspace 3
103
    bindsym $mod+Shift+4 move container to workspace 4
104
    bindsym $mod+Shift+5 move container to workspace 5
105
    bindsym $mod+Shift+6 move container to workspace 6
106
    bindsym $mod+Shift+7 move container to workspace 7
107
    bindsym $mod+Shift+8 move container to workspace 8
108
    bindsym $mod+Shift+9 move container to workspace 9
109
    bindsym $mod+Shift+0 move container to workspace 10
110
    # Note: workspaces can have any name you want, not just numbers.
111
    # We just use 1-10 as the default.
112
#
113
# Layout stuff:
114
#
115
    # You can "split" the current object of your focus with
116
    # $mod+b or $mod+v, for horizontal and vertical splits
117
    # respectively.
118
    bindsym $mod+b split h
119
    bindsym $mod+v split v
120
121
    # Switch the current container between different layout styles
122
    bindsym $mod+s layout stacking
123
    bindsym $mod+w layout tabbed
124
    bindsym $mod+e layout toggle split
125
126
    # Make the current focus fullscreen
127
    bindsym $mod+f fullscreen toggle
128
129
    # Toggle the current focus between tiling and floating mode
130
    bindsym $mod+Shift+space floating toggle
131
132
    # Swap focus between the tiling area and the floating area
133
    bindsym $mod+space focus mode_toggle
134
135
    # move focus to the parent container
136
    bindsym $mod+a focus parent
137
138
# I don't use scratchpad, so they're commented out
139
#bindsym $mod+Shift+minus move scratchpad
140
#bindsym $mod+minus scratchpad show
141
142
# Resizing containers:
143
#
144
mode "resize" {
145
    # left will shrink the containers width
146
    # right will grow the containers width
147
    # up will shrink the containers height
148
    # down will grow the containers height
149
    bindsym $left resize shrink width 10 px or 10 ppt
150
    bindsym $down resize grow height 10 px or 10 ppt
151
    bindsym $up resize shrink height 10 px or 10 ppt
152
    bindsym $right resize grow width 10 px or 10 ppt
153
154
    # ditto, with arrow keys
155
    bindsym Left resize shrink width 10 px or 10 ppt
156
    bindsym Down resize grow height 10 px or 10 ppt
157
    bindsym Up resize shrink height 10 px or 10 ppt
158
    bindsym Right resize grow width 10 px or 10 ppt
159
160
    # return to default mode
161
    bindsym Return mode "default"
162
    bindsym Escape mode "default"
163
}
164
bindsym $mod+r mode "resize"
165
166
# --recursive allows subdirectories to contain wallpapers as well, which is nice
167
# if you want to organize.
168
# --randomize chooses a different wallpaper for each screen (and of course,
169
# randomizes during startup)
170
# --bg-scale scales the wallpaper to fit the screen, so any 16:9 wallpaper is
171
# scaled to fit, instead of staying oversized.
172
#exec_always feh --recursive --randomize --bg-scale ~/.wallpapers/* 
173
exec compton -b
174
175
bar {
176
    swaybar_command waybar
177
    #status_command i3status
178
    font pango:Ubunto 10
179
    tray_padding 5
180
    colors {
181
        background #444444
182
        focused_workspace #F98C0E #F98C0E #333333
183
        active_workspace #19ea12 #19ea12 #FFFFFF
184
        inactive_workspace #232323 #111111 #888888
185
        urgent_workspace #D50000 #D50000 #FFFFFF
186
    }
187
}
188
189
190
# Makes my FN buttons work properly.
191
bindsym XF86AudioRaiseVolume exec amixer -q set Master 5%+ unmute
192
bindsym XF86AudioLowerVolume exec amixer -q set Master 5%- unmute
193
#bindsym XF86AudioToggle exec pactl set-sink-mute $(pacmd list-sinks |awk '/* index:/{print $3}') toggle
194
bindsym XF86AudioMute exec pactl set-sink-mute $(pacmd list-sinks |awk '/* index:/{print $3}') toggle
195
196
bindsym XF86MonBrightnessDown exec light -U 1
197
bindsym XF86MonBrightnessUp exec light -A 1
198
# Printscreen button
199
bindsym Print exec grim /tmp/$(date +'%Y-%m-%d-%H%M%S_grim.png')
200
# Combines grim with slurp for region screenshots
201
bindsym $mod+Print exec grim -g "$(slurp)"/tmp/$(date+'%Y-%m-%d-%H%M%S_grim.png')
202
203
204
# Font settings
205
font pango:Ubuntu Regular 11
206
207
# Border settings
208
hide_edge_borders smart
209
default_border normal
210
211
# Color settings
212
213
client.focused          #F98C0E #F98C0E #ffffff #F98C0E #F98C0E
214
client.focused_inactive #f9be7a #f9be7a #FFFFFF #f9be7a #f9be7a
215
client.unfocused        #444444 #444444 #FFFFFF #444444 #444444
216
client.urgent           #D50000 #D50000 #ffffff #D50000 #D50000
217
#client.placeholder
218
219
# Stops the mouse defining what the active window is.
220
focus_follows_mouse no
221
222
# i3-gaps configuration
223
#
224
# i3-gaps can only work properly if title bars are completely disabled, which the
225
# next line is responsible for.
226
#for_window [class="^.*"] border pixel 5
227
228
#gaps inner 15
229
#gaps outer 5
230
# smart_gaps disables gaps if there is only 1 container on the workspace.
231
#smart_gaps on
232
# smart_borders does the same thing. If set to "on", it will always disable the
233
# border if it's the only container on the workspace. If set to "no-gaps", it
234
# only disables the border if the gap size to the edge of the screen is 0.
235
#smart_borders no_gaps