aboutsummaryrefslogtreecommitdiffstats
path: root/i3/config
blob: 74f4480225c7aee743d6f58c75e0c835848d6a1f (plain)
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
set $mod Mod4

#font pango:visitor tt2 brk 10
font pango:Source Code Pro 9

floating_modifier $mod
bindsym $mod+Return exec termite
bindsym $mod+Shift+q kill
bindsym $mod+d exec --no-startup-id "/usr/bin/j4-dmenu-desktop --dmenu='dmenu -i -fn DejaVu\ Sans\ Mono\ 9' --term=/usr/bin/termite"
bindsym $mod+Shift+d exec --no-startup-id beze

# change focus
bindsym $mod+h focus left
bindsym $mod+j focus down
bindsym $mod+k focus up
bindsym $mod+l focus right

# 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+w split h
bindsym $mod+v split v

bindsym $mod+f fullscreen
bindsym $mod+s layout stacking
bindsym $mod+t layout tabbed
bindsym $mod+e layout toggle split
bindsym $mod+Shift+space floating toggle
# change focus between tiling / floating windows
bindsym $mod+space focus mode_toggle

bindsym $mod+a focus parent
bindsym $mod+c focus child

set $workspace1 1:I
set $workspace2 2:II
set $workspace3 3:III
set $workspace4 4:IV
set $workspace5 5:V
set $workspace6 6:VI
set $workspace7 7:VII
set $workspace8 8:VIII
set $workspace9 9:IX
set $workspace0 10:X

# switch to workspace
bindsym $mod+1 workspace $workspace1
bindsym $mod+2 workspace $workspace2
bindsym $mod+3 workspace $workspace3
bindsym $mod+4 workspace $workspace4
bindsym $mod+5 workspace $workspace5
bindsym $mod+6 workspace $workspace6
bindsym $mod+7 workspace $workspace7
bindsym $mod+8 workspace $workspace8
bindsym $mod+9 workspace $workspace9
bindsym $mod+0 workspace $workspace0

# move focused container to workspace
bindsym $mod+Shift+1 move container to workspace $workspace1
bindsym $mod+Shift+2 move container to workspace $workspace2
bindsym $mod+Shift+3 move container to workspace $workspace3
bindsym $mod+Shift+4 move container to workspace $workspace4
bindsym $mod+Shift+5 move container to workspace $workspace5
bindsym $mod+Shift+6 move container to workspace $workspace6
bindsym $mod+Shift+7 move container to workspace $workspace7
bindsym $mod+Shift+8 move container to workspace $workspace8
bindsym $mod+Shift+9 move container to workspace $workspace9
bindsym $mod+Shift+0 move container to workspace $workspace0

bindsym $mod+m exec i3-input -F 'mark %s' sl1 -P 'Mark: '
bindsym $mod+g exec i3-input -F '[con_mark="%s"] focus' -l 1 -P 'Go to: '

# reload the configuration file
bindsym $mod+Shift+c reload
# 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'"

# resize window (you can also use the mouse for that)
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 h resize shrink width 10 px or 10 ppt
	bindsym j resize grow height 10 px or 10 ppt
	bindsym k resize shrink height 10 px or 10 ppt
	bindsym l resize grow width 10 px or 10 ppt

# same bindings, but for the arrow keys
	bindsym Left resize shrink width 10 px or 10 ppt
	bindsym Down resize grow height 10 px or 10 ppt
	bindsym Up resize shrink height 10 px or 10 ppt
	bindsym Right resize grow width 10 px or 10 ppt

# back to normal: Enter or Escape
	bindsym Return mode "default"
	bindsym Escape mode "default"
}

bindsym $mod+r mode "resize"

# Start i3bar to display a workspace bar (plus the system information i3status
# finds out, if available)
#bar {
#	status_command i3status
#}

# i3bar
bar {
	tray_output primary
	status_command    ~/.local/venv/bin/python ~/.config/i3/bar.py
	position          bottom
	workspace_buttons yes
	strip_workspace_numbers yes
	colors {
		#class              border   backgr.  text
		background          #101010
		statusline          #ffffff
		urgent_workspace    #303030  #202020  #bd3267
		active_workspace    #5f5f5f  #101010  #101010
		inactive_workspace  #101010  #101010  #5f5f5f
		focused_workspace   #2e3436  #2a2a2a  #FFFFFF
	}
}


for_window [class="Gifview"] floating enable


bindsym $mod+Shift+g exec --no-startup-id setxkbmap us
bindsym $mod+Shift+u exec --no-startup-id setxkbmap dvorak


bindsym XF86MonBrightnessUp     exec --no-startup-id xbacklight -inc 10
bindsym XF86MonBrightnessDown   exec --no-startup-id xbacklight -dec 10

# control ncmpcpp / mpd from media keys
bindsym XF86AudioPlay exec --no-startup-id mpc toggle
bindsym XF86AudioStop exec --no-startup-id mpc stop
bindsym XF86AudioNext exec --no-startup-id mpc next
bindsym XF86AudioPrev exec --no-startup-id mpc prev


# control PulseAudio from media keys
bindsym XF86AudioMute exec volumecontrol mute
bindsym XF86AudioMicMute exec volumecontrol mute-mic
bindsym XF86AudioLowerVolume exec volumecontrol lower
bindsym XF86AudioRaiseVolume exec volumecontrol raise


bindsym XF86Tools exec loginctl lock-session

new_window 1pixel
bindsym $mod+b border normal
bindsym $mod+p border 1pixel
bindsym $mod+n border none


# Make the currently focused window a scratchpad
bindsym $mod+Shift+minus move scratchpad

# Show the first scratchpad window
bindsym $mod+minus scratchpad show

# TrackPoint scrolling
exec setup-trackpoint

# Autostart all .desktop files with dex
exec --no-startup-id dex -s $HOME/.config/autostart -a -e i3