Skip to content

Instantly share code, notes, and snippets.

@pfsmorigo
Created May 8, 2012 13:45
Show Gist options
  • Save pfsmorigo/2635132 to your computer and use it in GitHub Desktop.
Save pfsmorigo/2635132 to your computer and use it in GitHub Desktop.
i3 config
# This file has been auto-generated by i3-config-wizard(1).
# It will not be overwritten, so edit it as you like.
#
# Should you change your keyboard layout somewhen, delete
# this file and re-run i3-config-wizard(1).
#
# i3 config file (v4)
#
# Please see http://i3wm.org/docs/userguide.html for a complete reference!
set $mod Mod4
set $alt Mod1
set $resize_value 2
# colors
set $background background #000000
set $statusline statusline #ffffff
set $barcolor1 focused_workspace #ffffff #285577
set $barcolor2 active_workspace #ffffff #333333
set $barcolor3 inactive_workspace #888888 #222222
set $barcolor4 urgent_workspace #ffffff #900000
## class border backgr. text
client.focused #2B6473 #2B6473 #ffffff
client.focused_inactive #004050 #004050 #ffffff
client.unfocused #004050 #004050 #cccccc
client.urgent #900000 #900000 #ffffff
client.background #342826
# font for window titles. ISO 10646 = Unicode
#font -misc-fixed-medium-r-normal--13-120-75-75-C-70-iso10646-1
font -xos4-terminus-medium-r-normal--12-120-72-72-c-60-iso10646-1
# Use Mouse+$mod to drag floating windows to their wanted position
floating_modifier $mod
# start a terminal
bindsym $mod+Return exec /usr/local/bin/urxvt -e sh -c "/usr/bin/screen -AOxRR main"
# kill focused window
bindsym $mod+Shift+Q kill
# start dmenu (a program launcher)
bindsym $mod+d exec dmenu_run -nb '#000000' -nf '#ffffff' -sb '#000000' -sf '#1793d0' -p 'Run: ' -fn '-xos4-terminus-medium-r-normal--12-120-72-72-c-60-iso8859-1'
# change focus
#bindsym $mod+j focus left
#bindsym $mod+k focus down
#bindsym $mod+l focus up
#bindsym $mod+semicolon focus right
bindsym $mod+h focus left
bindsym $mod+j focus down
bindsym $mod+k focus up
bindsym $mod+l focus right
# 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
#bindsym $mod+Shift+J move left
#bindsym $mod+Shift+K move down
#bindsym $mod+Shift+L move up
#bindsym $mod+Shift+colon move right
bindsym $mod+Shift+H move left
bindsym $mod+Shift+J move down
bindsym $mod+Shift+K move up
bindsym $mod+Shift+L move right
# 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
bindsym $mod+Shift+V split h
# split in vertical orientation
bindsym $mod+v split v
# enter fullscreen mode for the focused container
bindsym $mod+f fullscreen
# change container layout (stacked, tabbed, default)
bindsym $mod+s layout stacking
bindsym $mod+w layout tabbed
bindsym $mod+e layout default
# 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
#bindcode $mod+d focus child
# focus last urgent
bindsym $mod+Escape [urgent="last"] focus
# switch to workspace
bindsym $mod+1 workspace 1
bindsym $mod+2 workspace 2
bindsym $mod+3 workspace 3
bindsym $mod+4 workspace 4
bindsym $mod+5 workspace 5
bindsym $mod+6 workspace 6
bindsym $mod+7 workspace 7
bindsym $mod+8 workspace 8
bindsym $mod+9 workspace 9
bindsym $mod+0 workspace 10
# switch between the current and the previously focused one
bindsym $mod+b workspace back_and_forth
# move focused container to workspace
bindsym $mod+Shift+grave move workspace 0
bindsym $mod+Shift+exclam move workspace 1
bindsym $mod+Shift+at move workspace 2
bindsym $mod+Shift+numbersign move workspace 3
bindsym $mod+Shift+dollar move workspace 4
bindsym $mod+Shift+percent move workspace 5
bindsym $mod+Shift+dead_circumflex move workspace 6
#bindsym $mod+Shift+asciicircum move workspace 6
bindsym $mod+Shift+ampersand move workspace 7
bindsym $mod+Shift+asterisk move workspace 8
bindsym $mod+Shift+parenleft move workspace 9
bindsym $mod+Shift+parenright move workspace 10
# 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 exit
# resize window (you can also use the mouse for that)
mode "resize" {
# These bindings trigger as soon as1 you enter the resize mode
# They resize the border in the direction you pressed, e.g.
# when pressing left, the window is resized so that it has
# more space on its left
#bindsym j resize shrink left $resize_value px or $resize_value ppt
#bindsym Shift+J resize grow left $resize_value px or $resize_value ppt
bindsym h resize shrink left $resize_value px or $resize_value ppt
bindsym Shift+H resize grow left $resize_value px or $resize_value ppt
#bindsym k resize shrink down $resize_value px or $resize_value ppt
#bindsym Shift+K resize grow down $resize_value px or $resize_value ppt
bindsym j resize shrink down $resize_value px or $resize_value ppt
bindsym Shift+J resize grow down $resize_value px or $resize_value ppt
#bindsym l resize shrink up $resize_value px or $resize_value ppt
#bindsym Shift+L resize grow up $resize_value px or $resize_value ppt
bindsym k resize shrink up $resize_value px or $resize_value ppt
bindsym Shift+K resize grow up $resize_value px or $resize_value ppt
#bindsym semicolon resize shrink right $resize_value px or $resize_value ppt
#bindsym Shift+colon resize grow right $resize_value px or $resize_value ppt
bindsym l resize shrink right $resize_value px or $resize_value ppt
bindsym Shift+L resize grow right $resize_value px or $resize_value ppt
# same bindings, but for the arrow keys
bindsym Left resize shrink left $resize_value px or $resize_value ppt
bindsym Shift+Left resize grow left $resize_value px or $resize_value ppt
bindsym Down resize shrink down $resize_value px or $resize_value ppt
bindsym Shift+Down resize grow down $resize_value px or $resize_value ppt
bindsym Up resize shrink up $resize_value px or $resize_value ppt
bindsym Shift+Up resize grow up $resize_value px or $resize_value ppt
bindsym Right resize shrink right $resize_value px or $resize_value ppt
bindsym Shift+Right resize grow right $resize_value px or $resize_value ppt
# back to normal: Enter or Escape
bindsym Return mode "default"
bindsym Escape mode "default"
}
bindsym $mod+r mode "resize"
bindsym $mod+t border normal
bindsym $mod+y border 1pixel
bindsym $mod+u border none
# Workspace settings
workspace 1 output LVDS1
workspace 2 output LVDS1
workspace 3 output LVDS1
# functions control
# key definition at /usr/share/X11/XKeysymDB
bindsym XF86ScreenSaver exec xscreensaver-command -lock
#bindsym XF86Sleep exec
bindsym XF86AudioMute exec amixer set Master toggle
bindsym XF86AudioLowerVolume exec amixer -q set Master 4000- unmute
bindsym XF86AudioRaiseVolume exec amixer -q set Master 4000+ unmute
bindsym $mod+XF86AudioLowerVolume exec amixer -q set PCM 4000- unmute
bindsym $mod+XF86AudioRaiseVolume exec amixer -q set PCM 4000+ unmute
#bindsym XF86MonBrightnessUp exec xbacklight -inc 20
#bindsym XF86MonBrightnessDown exec xbacklight -dec 20
#bindsym $mod+XF86MonBrightnessUp exec xbacklight -set 100
#bindsym $mod+XF86MonBrightnessDown exec xbacklight -set 0
#bindsym XF86AudioPlay exec zenity --info --text "Define Play"
#bindsym XF86AudioStop exec zenity --info --text "Define Stop"
#bindsym XF86AudioPrev exec zenity --info --text "Define Prev"
#bindsym XF86AudioNext exec zenity --info --text "Define Next"
#bindsym XF86AudioRecord exec zenity --info --text "Define Audio Record"
# Other binds
bindsym Print exec gnome-screenshot
bindsym $alt+Print exec gnome-screenshot --window
# Start i3bar to display a workspace bar (plus the system information i3status
# finds out, if available)
bar {
output LVDS1
status_command i3status --config ~/.i3/status-primary.conf | while read C; do echo "$(~/.i3/complement.sh) | $C"; done
# status_command conky -t 'CPU: ${cpu cpu1}% ${cpu cpu2}% ${cpu cpu3}% ${cpu cpu4}% ${cpu cpu5}% ${cpu cpu6}% ${cpu cpu7}% ${cpu cpu8}% - ${cpu cpu0}% | MEM: $mem/$memmax - $memperc% | SWAP: $swap/$swapmax $swapperc% | ${time %a %b %d %T %Z %Y}'
# status_command conky | dzen2 -h ’17’ -w ’1500’ -x ’2340’ -ta ’rm’ -fn ’-xos4-terminus-medium-r-normal--12-120-72-72-c-60-iso8859-1’
tray_output LVDS1
colors {
$barcolor1
$barcolor2
$barcolor3
$barcolor4
}
}
bar {
output HDMI1
status_command i3status --config ~/.i3/status-secundary.conf
# status_command conky -w i3 -c ~/.i3/conkyrc
tray_output none
colors {
$background
$statusline
$barcolor1
$barcolor2
$barcolor3
$barcolor4
}
}
bar {
output VGA1
status_command i3status --config ~/.i3/status-secundary.conf
# status_command conky -w i3 -c ~/.i3/conkyrc
tray_output none
colors {
$background
$statusline
$barcolor1
$barcolor2
$barcolor3
$barcolor4
}
}
# screen
bindsym $mod+F1 [class="URxvt" title="1\*"] focus
bindsym $mod+F2 [class="URxvt" title="2\*"] focus
bindsym $mod+F3 [class="URxvt" title="3\*"] focus
bindsym $mod+F4 [class="URxvt" title="4\*"] focus
bindsym $mod+F5 [class="URxvt" title="5\*"] focus
bindsym $mod+F6 [class="URxvt" title="6\*"] focus
bindsym $mod+F7 [class="URxvt" title="7\*"] focus
bindsym $mod+F8 [class="URxvt" title="8\*"] focus
bindsym $mod+F9 [class="URxvt" title="9\*"] focus
bindsym $mod+F10 [class="URxvt" title="0\*"] focus
# www
bindsym $mod+F11 workspace www
bindsym $mod+Shift+F11 move workspace www
#bindsym $mod+F2 [class="Google-chrome"] focus
assign [class="Opera"] www
assign [class="Firefox"] www
#assign [class="Google-chrome" instance="crx_nckgahadagoaajjgafhacjanaoiihapd"] gtalk
assign [class="Google-chrome"] www
#for_window [class="Google-chrome" instance="crx_nckgahadagoaajjgafhacjanaoiihapd"] floating disable; layout stacking; move right; resize shrink right 31px or 31 ppt
# work
bindsym $mod+F12 workspace work
bindsym $mod+Shift+F12 move workspace work
workspace "work" output LVDS1
for_window [title="NotesLogo"] floating enable; border none; layout tabbed
for_window [title="Alarm"] floating enable
assign [class="Lotus Notes"] work
assign [title="Lotus Notes$"] work
assign [title="NotesLogo"] work
assign [class="Agnclient"] work
# gimp
assign [class="Gimp"] gimp
for_window [title="GIMP Startup"] move workspace gimp
for_window [window_role="gimp-toolbox"] floating disable; layout stacking; move left; resize shrink right 31px or 31 ppt
# others
for_window [class="grub-emu"] floating enable
for_window [title="Event Tester"] floating enable
for_window [title="xfce4-notifyd"] floating enable
for_window [title="xfce4-notifyd"] border none
for_window [class="Key-mon"] floating enable
for_window [class="Key-mon"] border none
for_window [title="VNC authentication [VncAuth]"] floating enable
for_window [title="VNC Viewer: Information"] floating enable
for_window [class="Ibmsaml"] floating enable
for_window [class="Shotwell"] floating enable
for_window [class="XFontSel"] floating enable
for_window [class="Blueman-manager"] floating enable
# Start some util apps
exec --no-startup-id /usr/bin/xscreensaver # XScreensaver
exec --no-startup-id /usr/bin/nm-applet --sm-disable # Network Manager
exec --no-startup-id /usr/bin/screen -AOxRR main # Screen
#exec --no-startup-id /usr/bin/screen -dmR # Screen
exec --no-startup-id /usr/bin/xfce4-power-manager # Power Manager
#exec --no-startup-id /usr/bin/gnome-power-manager # Power Manager
#exec --no-startup-id /usr/libexec/gnome-settings-daemon # GNOME Settings Daemon
#exec --no-startup-id /usr/bin/gnome-volume-control-applet # Volume Control
exec --no-startup-id /usr/bin/blueman-applet # Bluetooth Manager
#exec --no-startup-id /usr/bin/nautilus # Nautilus
#exec --no-startup-id /usr/bin/system-config-printer-applet # Print Queue Applet
#exec --no-startup-id /usr/bin/savtray # Symantec AntiVirus
exec --no-startup-id /usr/bin/dropbox start -i # Dropbox
exec --no-startup-id /usr/bin/thunar --daemon # Thunar
exec --no-startup-id /usr/local/bin/clipit # ClipIt
## autostart file support
##exec ~/.i3/startup
#
### Background wallpaper
#exec nitrogen --restore
#
### Keyboard indicator/switcher for tray
#exec fbxkb
#exec pgrep stalonetray > /dev/null || stalonetray -bg '#303030' -f 0 --max-geometry 5x1 --geometry 5x1-0+0 --grow-gravity W --icon-gravity E -i 16 --kludges force_icons_size --no-shrink true --scrollbars horizontal --skip-taskbar true --sticky true --window-layer bottom
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment