2021-05-14 21:16:34 +02:00
# i3 config file (v4)
#
# Please see https://i3wm.org/docs/userguide.html for a complete reference!
set $mod Mod4
# Font for window titles. Will also be used by the bar unless a different font
# is used in the bar {} block below.
2023-01-20 22:30:45 +01:00
font pango:<% opt.font %> 10
2021-05-14 21:16:34 +02:00
# 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
# The combination of xss-lock, nm-applet and pactl is a popular choice, so
# they are included here as an example. Modify as you see fit.
# xss-lock grabs a logind suspend inhibit lock and will use i3lock to lock the
# screen before suspend. Use loginctl lock-session to lock your screen.
2023-07-28 00:57:43 +02:00
exec --no-startup-id xss-lock --transfer-sleep-lock -- <% opt.commands.screen_lock %>
2021-05-14 21:16:34 +02:00
# NetworkManager is the most popular way to manage wireless networks on Linux,
# and nm-applet is a desktop environment-independent system tray GUI for it.
exec --no-startup-id nm-applet
2022-03-25 22:57:47 +01:00
# layout manager
exec --no-startup-id i3man
2024-06-29 21:36:13 +02:00
# media keys
2024-05-29 15:56:16 +02:00
bindsym XF86AudioRaiseVolume exec <% opt.commands.media.volume_up %>
bindsym XF86AudioLowerVolume exec <% opt.commands.media.volume_down %>
bindsym XF86AudioMute exec <% opt.commands.media.mute_sink %>
bindsym XF86AudioMicMute exec <% opt.commands.media.mute_source %>
2021-05-14 21:16:34 +02:00
2024-05-29 15:56:16 +02:00
bindsym XF86AudioPlay exec <% opt.commands.media.play_pause %>
bindsym XF86AudioStop exec <% opt.commands.media.stop %>
bindsym XF86AudioNext exec <% opt.commands.media.next %>
bindsym XF86AudioPrev exec <% opt.commands.media.prev %>
2021-11-05 18:36:01 +01:00
2024-06-29 21:36:13 +02:00
# Backlight keys
bindsym XF86MonBrightnessUp exec <% opt.commands.backlight_up %>
bindsym XF86MonBrightnessDown exec <% opt.commands.backlight_down %>
2022-07-01 14:12:10 +02:00
# other fancy keys
2023-01-26 21:17:16 +01:00
bindsym XF86Mail exec <% opt.commands.email %>
bindsym XF86Calculator exec <% opt.commands.calculator %>
2023-07-03 19:10:37 +02:00
bindsym XF86Explorer exec <% opt.commands.file_manager %>
bindsym XF86HomePage exec <% opt.commands.browser %>
2022-07-01 14:12:10 +02:00
2021-05-14 21:16:34 +02:00
# Use Mouse+$mod to drag floating windows to their wanted position
floating_modifier $mod
# start a terminal
2023-01-26 08:18:52 +01:00
bindsym $mod+Return exec TERMINAL=<% opt.term.command %> i3-sensible-terminal
2021-05-14 21:16:34 +02:00
2023-01-26 21:17:16 +01:00
# open file manager
bindsym $mod+Ctrl+e exec <% opt.commands.file_manager %>
2022-05-20 23:35:41 +02:00
2023-01-26 21:17:16 +01:00
# open browser
bindsym $mod+Ctrl+b exec <% opt.commands.browser %>
2022-10-16 17:31:15 +02:00
2023-07-18 14:33:49 +02:00
# launch menu
bindsym $mod+Ctrl+m exec launchmenu
2022-10-16 20:31:31 +02:00
# vinput
2022-10-17 18:44:31 +02:00
bindsym $mod+Ctrl+v exec vinput md
for_window [class="vinput-editor"] floating enable
2022-10-16 20:31:31 +02:00
2021-05-14 21:16:34 +02:00
# kill focused window
bindsym $mod+Shift+q kill
2022-05-16 00:56:04 +02:00
# open gpower2
bindsym $mod+Shift+p exec gpower2
2022-04-20 17:08:54 +02:00
2022-08-13 12:00:28 +02:00
# randomize wallpaper
bindsym $mod+Shift+w exec randomwallpaper
2021-05-14 21:16:34 +02:00
# change focus
2021-10-02 19:51:53 +02:00
bindsym $mod+h focus left
bindsym $mod+j focus down
bindsym $mod+k focus up
bindsym $mod+l focus right
2021-05-14 21:16:34 +02:00
# alternatively, you can use the cursor keys:
bindsym $mod+Left focus left
bindsym $mod+Down focus down
bindsym $mod+Up focus up
bindsym $mod+Right focus right
# move focused window
2021-10-02 19:59:52 +02:00
bindsym $mod+Shift+h move left
bindsym $mod+Shift+j move down
bindsym $mod+Shift+k move up
bindsym $mod+Shift+l move right
2021-05-14 21:16:34 +02:00
# alternatively, you can use the cursor keys:
bindsym $mod+Shift+Left move left
bindsym $mod+Shift+Down move down
bindsym $mod+Shift+Up move up
bindsym $mod+Shift+Right move right
# split in horizontal orientation
2021-10-02 19:51:53 +02:00
bindsym $mod+c split h
2021-05-14 21:16:34 +02:00
# split in vertical orientation
bindsym $mod+v split v
# enter fullscreen mode for the focused container
bindsym $mod+f fullscreen toggle
# change container layout (stacked, tabbed, toggle split)
bindsym $mod+s layout stacking
bindsym $mod+w layout tabbed
bindsym $mod+e layout toggle split
# toggle tiling / floating
bindsym $mod+Shift+space floating toggle
# change focus between tiling / floating windows
bindsym $mod+space focus mode_toggle
# focus the parent container
bindsym $mod+a focus parent
# focus the child container
2021-08-09 20:41:46 +02:00
bindsym $mod+d focus child
# Make the currently focused window a scratchpad
bindsym $mod+Shift+minus move scratchpad
# Show the first scratchpad window
bindsym $mod+minus scratchpad show
2021-05-14 21:16:34 +02:00
2022-05-24 22:43:35 +02:00
# Lock screen
2023-07-28 00:57:43 +02:00
bindsym $mod+Ctrl+l exec <% opt.commands.screen_lock %>
2022-05-24 22:43:35 +02:00
2021-05-14 21:16:34 +02:00
# Define names for default workspaces for which we configure key bindings later on.
# We use variables to avoid repeating the names in multiple places.
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"
set $ws10 "10"
# switch to workspace
bindsym $mod+1 workspace number $ws1
bindsym $mod+2 workspace number $ws2
bindsym $mod+3 workspace number $ws3
bindsym $mod+4 workspace number $ws4
bindsym $mod+5 workspace number $ws5
bindsym $mod+6 workspace number $ws6
bindsym $mod+7 workspace number $ws7
bindsym $mod+8 workspace number $ws8
bindsym $mod+9 workspace number $ws9
bindsym $mod+0 workspace number $ws10
# move focused container to workspace
bindsym $mod+Shift+1 move container to workspace number $ws1
bindsym $mod+Shift+2 move container to workspace number $ws2
bindsym $mod+Shift+3 move container to workspace number $ws3
bindsym $mod+Shift+4 move container to workspace number $ws4
bindsym $mod+Shift+5 move container to workspace number $ws5
bindsym $mod+Shift+6 move container to workspace number $ws6
bindsym $mod+Shift+7 move container to workspace number $ws7
bindsym $mod+Shift+8 move container to workspace number $ws8
bindsym $mod+Shift+9 move container to workspace number $ws9
bindsym $mod+Shift+0 move container to workspace number $ws10
# 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.
2021-10-02 20:51:51 +02:00
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
2021-05-14 21:16:34 +02:00
# 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 or $mod+r
bindsym Return mode "default"
bindsym Caps_Lock mode "default"
bindsym $mod+r mode "default"
}
bindsym $mod+r mode "resize"
2022-10-16 20:31:31 +02:00
# enable icons
2021-06-22 21:04:42 +02:00
for_window [class=".*"] title_window_icon on
2021-05-14 21:16:34 +02:00
# random settings
focus_follows_mouse no
gaps inner 10
gaps outer 10
bindsym $mod+z gaps outer current plus 5
bindsym $mod+Shift+z gaps outer current minus 5
2021-12-30 22:10:53 +01:00
bindsym $mod+u gaps inner current plus 5
bindsym $mod+Shift+u gaps inner current minus 5
2021-05-14 21:16:34 +02:00
# background
2022-08-06 11:14:39 +02:00
exec --no-startup-id randomwallpaper
2021-05-14 21:16:34 +02:00
2021-05-19 15:55:04 +02:00
# compositor
2021-09-07 15:58:37 +02:00
exec picom -f -i 1 -c
2021-05-14 21:24:45 +02:00
2021-05-31 18:29:46 +02:00
# conky
exec conky
2023-09-30 16:06:51 +02:00
<! if opt.commands.notification_daemon.x then !>
2023-06-02 16:29:00 +02:00
# notification daemon
2023-09-30 16:06:51 +02:00
exec <% opt.commands.notification_daemon.x %>
2023-06-02 16:29:00 +02:00
<! end !>
2021-08-27 16:08:09 +02:00
2023-03-06 13:54:33 +01:00
<! if opt.commands.file_manager_daemon then !>
# start file manager daemon
exec <% opt.commands.file_manager_daemon %>
<! end !>
2021-05-14 21:16:34 +02:00
# border toggle
bindsym $mod+b border toggle
2021-06-01 13:12:00 +02:00
# rofi
bindsym Mod1+space exec rofi -show combi
2021-09-07 23:03:45 +02:00
# rofi emoji
bindsym $mod+Mod1+space exec rofi -show emoji
2021-08-08 18:52:39 +02:00
2021-08-04 15:42:57 +02:00
# flameshot
2021-08-06 22:41:03 +02:00
bindsym Print exec flameshot gui
2021-08-04 15:42:57 +02:00
2021-09-05 18:19:46 +02:00
# adjust transparency
bindsym $mod+t exec picom-trans -c -10
bindsym $mod+Shift+t exec picom-trans -c +10
2021-10-11 18:03:41 +02:00
# wired controls
bindsym $mod+Ctrl+space exec wired --drop latest
bindsym $mod+Mod1+Ctrl+space exec wired --drop all
bindsym $mod+Shift+Ctrl+space exec wired --show 1
2021-11-21 21:53:49 +01:00
# auto clicking
2023-03-24 16:23:22 +01:00
bindsym Ctrl+Shift+F11 exec xdotool click --delay 10 --repeat 100 1
bindsym Ctrl+Shift+F12 exec xdotool click --delay 10 --repeat 100 3
2024-05-09 08:28:26 +02:00
# capture current screen and open in nsxiv
bindsym Shift+Print exec shotgun -s - | nsxiv-pipe -e nsxiv-float
for_window [class="nsxiv-float"] floating enable
2021-11-21 21:53:49 +01:00
2023-06-08 23:17:19 +02:00
# catppuccin mocha theme
2024-01-14 18:27:37 +01:00
set $rosewater #<% opt.catppuccin.rosewater %>
set $flamingo #<% opt.catppuccin.flamingo %>
set $pink #<% opt.catppuccin.pink %>
set $mauve #<% opt.catppuccin.mauve %>
set $red #<% opt.catppuccin.red %>
set $maroon #<% opt.catppuccin.maroon %>
set $peach #<% opt.catppuccin.peach %>
set $green #<% opt.catppuccin.green %>
set $teal #<% opt.catppuccin.teal %>
set $sky #<% opt.catppuccin.sky %>
set $sapphire #<% opt.catppuccin.sapphire %>
set $blue #<% opt.catppuccin.blue %>
set $lavender #<% opt.catppuccin.lavender %>
set $text #<% opt.catppuccin.text %>
set $subtext1 #<% opt.catppuccin.subtext1 %>
set $subtext0 #<% opt.catppuccin.subtext0 %>
set $overlay2 #<% opt.catppuccin.overlay2 %>
set $overlay1 #<% opt.catppuccin.overlay1 %>
set $overlay0 #<% opt.catppuccin.overlay0 %>
set $surface2 #<% opt.catppuccin.surface2 %>
set $surface1 #<% opt.catppuccin.surface1 %>
set $surface0 #<% opt.catppuccin.surface0 %>
set $base #<% opt.catppuccin.base %>
set $mantle #<% opt.catppuccin.mantle %>
set $crust #<% opt.catppuccin.crust %>
2023-06-08 23:17:19 +02:00
2023-06-09 09:07:53 +02:00
client.focused $red $surface1 $text $rosewater $red
client.focused_inactive $maroon $base $text $rosewater $maroon
client.unfocused $maroon $base $text $rosewater $maroon
client.urgent $peach $base $peach $overlay0 $peach
client.placeholder $overlay0 $base $text $overlay0 $overlay0
2023-06-08 23:17:19 +02:00
client.background $base
2021-05-14 21:16:34 +02:00
bar {
2023-01-20 22:30:45 +01:00
font pango:<% opt.term_font %> 12
2022-04-16 16:30:04 +02:00
mode hide
2021-08-04 15:46:13 +02:00
position top
2023-05-17 21:42:04 +02:00
status_command i3status
2021-11-05 18:36:01 +01:00
separator_symbol |
2021-05-14 21:16:34 +02:00
colors {
2023-06-08 23:17:19 +02:00
background $mantle
statusline $text
focused_workspace $surface2 $base $text
active_workspace $base $base $text
inactive_workspace $crust $crust $surface1
urgent_workspace $red $red $text
binding_mode $red $red $text
2021-05-14 21:16:34 +02:00
}
}
2023-01-26 21:17:16 +01:00
<% opt.getDeviceConf "i3" %>