{"id":6951,"date":"2020-09-27T21:22:33","date_gmt":"2020-09-27T18:22:33","guid":{"rendered":"https:\/\/kifarunix.com\/?p=6951"},"modified":"2024-03-14T22:53:34","modified_gmt":"2024-03-14T19:53:34","slug":"install-and-setup-i3-windows-manager-on-ubuntu-20-04","status":"publish","type":"post","link":"https:\/\/kifarunix.com\/install-and-setup-i3-windows-manager-on-ubuntu-20-04\/","title":{"rendered":"Install and Setup i3 Windows Manager on Ubuntu 20.04"},"content":{"rendered":"\n
Welcome to our tutorial on how to install i3 windows manager on Ubuntu 20.04. i3 is a tiling window manager<\/a> for X11. “A tiling window manager<\/strong> is a window manager with an organization of the screen into mutually non-overlapping frames, as opposed to the more popular approach of coordinate-based stacking of overlapping objects (windows) that tries to fully emulate the desktop metaphor.”<\/em><\/p>\n\n\n\n To begin with, run system package update.<\/p>\n\n\n\n i3 windows manager can be installed via the There are other tools that are needed to use the i3 window manager efficiently. These include;<\/p>\n\n\n\n These packages are installed along with the i3 meta package.<\/p>\n\n\n\n The current stable version of i3 is 4.18.2. However, if you can check the version provided by the default Ubuntu repos, you realize it is not up-to-date.<\/p>\n\n\n\n To ensure we install and latest version and to ensure seamless updates\/upgrades, create i3-wm repos;<\/p>\n\n\n\n Update your package sources lists.<\/p>\n\n\n\n You should now be able to install latest version of i3-wm by running the command below;<\/p>\n\n\n\n Once the installation is done, you can now proceed to configure i3-wm on Ubuntu 20.04.<\/p>\n\n\n\n First, log out of your system and log in again. While logging in, be sure to select i3 session as your login screen.<\/p>\n\n\n Upon successfully logging in, you are then prompted on whether to:<\/p>\n\n\n\n In this setup, we will go with the first option of having to auto generate the i3-wm configuration file. We will later modify it to suit our needs. Therefore, press ENTER<\/strong> and continue.<\/p>\n\n\n\n Next, you need to define the i3-wm modifier key ($mod). You have two options here: you can use the Write the changes by pressing ENTER<\/strong>.<\/p>\n\n\n\n And you should now be welcomed by black screen with some status bar at the bottom that resembles the one shown in the screenshot below;<\/p>\n\n\n\n Now that it is installed with the basic configuration setup, there are a few key combinations that can be used to perform some basic tasks;<\/p>\n\n\n\n Note that $mod represents the modifier key you selected. Either Alt or Win key. It is Win key on our setup<\/strong>.<\/p>\n\n\n\n Next, we want to make i3 appealing and easy to use. You can customize i3-wm by modifying the Below is our sample i3 wm configuration;<\/p>\n\n\n\n The above configuration gives us such a window;<\/p>\n\n\n\n A number of packages are requires for the above display and various shortcuts defined in the configuration file above;<\/p>\n\n\n\n Install ybacklight for controlling the screen brightness if xbacklight doesn’t work;<\/p>\n\n\n\n Install Shutter for screenshots;<\/p>\n\n\n\n As defined the i3 configuration above, log out script, which gives such an logout interface shown below upon pressing Create the i3 binary scripts directory and install the logout script.<\/p>\n\n\n\n NB: The script is a modified version of the logout script provided on the Jmutai dotfiles<\/a> github repository.Be sure to make the script executable;<\/p>\n\n\n\n The rofi can be used to search for and locate files and folders within your system. Below is the rofi finder script we use;<\/p>\n\n\n\n The rofi finder can be launched, as per our config, by pressing Note that the script uses You can as well configure rofi to launch your system applications with i3-dmenu-desktop. Below is the script used in this guide to launch system apps;<\/p>\n\n\n\n The i3 configuration for rofi app launcher is;<\/p>\n\n\n\n The shortcut for launching the rofi app launcher as per our config is, To customize the rofi window, use Enable Print Screen using shutter<\/p>\n\n\n\n Killing a focussed windows;<\/p>\n\n\n\n Changing Focus between different windows in a Workspace (see the respective key shortcuts);<\/p>\n\n\n\n Splitting a Window vertically ($mod+v<\/strong>) or horizontally ($mod+h<\/strong>);<\/p>\n\n\n\n Set a window in a full screen mode ($mod+f<\/strong>);<\/p>\n\n\n\n Set a window to tiling or floating mode ( Changing the focus of the parent or child window;<\/p>\n\n\n\n Setting Icons for different Workspaces;<\/p>\n\n\n\n Note we also bind various applications to their respective workspaces;<\/p>\n\n\n\n First off, let us set a wallpaper. i3 wallpaper can be set using This should automatically change your wallpaper. To ensure that the wallpaper is set always when you login to your i3 session, edit the ~\/.config\/i3\/config<\/strong> and set the correct path to your wallpaper image;<\/p>\n\n\n\n i3blocks<\/a> is an alternative to i3status. i3blocks is available on the default Ubuntu 20.04 repos. Install i3blocks and it by running the command below;<\/p>\n\n\n\n Next, configure i3 to use i3blocks instead of i3status by replacing the i3 This should change the i3 status bar. You as well need i3blocks blocklets. “A blocklet is the configuration of a single block, part of the status line”<\/em>. You can find a comprehensive list of blocklets in the blocklets page<\/a>. In my setup, most of the scripts are taken from vivien blocklets<\/a>.<\/p>\n\n\n\nInstalling i3 Windows Manager on Ubuntu 20.04<\/h2>\n\n\n\n
Run System Update<\/h3>\n\n\n\n
apt update<\/code><\/pre>\n\n\n\n
Install i3 on Ubuntu 20.04<\/a><\/h3>\n\n\n\n
i3<\/code> package which is available on the default Ubuntu 20.04 repos.<\/p>\n\n\n\n
apt show i3<\/code><\/pre>\n\n\n\n
\nPackage: i3\nVersion: 4.17.1-1\nPriority: optional\nSection: universe\/x11\nSource: i3-wm\nOrigin: Ubuntu\nMaintainer: Ubuntu Developers
\n
i3 window manager<\/strong><\/code>: The i3-wm itself<\/li>\n\n\n\n
i3lock<\/strong><\/code> screen locker<\/li>\n\n\n\n
i3status<\/strong><\/code> for system information<\/li>\n\n\n\n
suckless-tools<\/code><\/strong> for dmenu<\/li>\n<\/ul>\n\n\n\n
Install i3 WM from Ubuntu\/Debian Repos<\/h4>\n\n\n\n
wget -O- https:\/\/baltocdn.com\/i3-window-manager\/signing.asc | gpg --dearmor > \/etc\/apt\/trusted.gpg.d\/i3wm-signing.gpg<\/code><\/pre>\n\n\n\n
apt install apt-transport-https --yes<\/code><\/pre>\n\n\n\n
echo \"deb https:\/\/baltocdn.com\/i3-window-manager\/i3\/i3-autobuild\/ all main\" | sudo tee \/etc\/apt\/sources.list.d\/i3-autobuild.list<\/code><\/pre>\n\n\n\n
apt update<\/code><\/pre>\n\n\n\n
apt install i3<\/code><\/pre>\n\n\n\n
Configuring i3 Windows Manager on Ubuntu 20.04<\/a><\/h3>\n\n\n\n
<\/figure><\/div>\n\n\n
\n
~\/.config\/i3\/config<\/strong><\/code> or <\/li>\n\n\n\n
<\/figure><\/div>\n\n\n
Windows logo key<\/strong><\/code> or the
Alt key<\/strong><\/code>. In this setup, we will use the popular $mod key, the
Windows logo key<\/code><\/em> as our i3-wm modifier, and is selected by default. Use the arrow up or down keys to select the $mod<\/strong> keys.<\/p>\n\n\n
<\/figure><\/div>\n\n\n
<\/figure>\n\n\n\n
Basic Usage of i3<\/h4>\n\n\n\n
\n
$mod + ENTER<\/strong><\/code>.<\/li>\n\n\n\n
$mod + d<\/code><\/strong>. This opens up a menu at the top of the screen where you can put keywords to search for specific app.<\/li>\n\n\n\n
$mod + f<\/strong><\/code>.<\/li>\n\n\n\n
$mod + Shift + q<\/strong><\/code><\/li>\n\n\n\n
$mod + Shift + r<\/strong><\/code>.<\/li>\n\n\n\n
$mod + Shift + e<\/strong><\/code>.<\/li>\n<\/ul>\n\n\n\n
Customizing i3 on Ubuntu 20.04<\/h4>\n\n\n\n
~\/.config\/i3\/config<\/strong><\/code> file.<\/p>\n\n\n\n
# Please see http:\/\/i3wm.org\/docs\/userguide.html for a complete reference!\n#\n\nset_from_resource $darkred color1 #000000\nset_from_resource $red color9 #000000\nset_from_resource $darkgreen color2 #000000\nset_from_resource $green color10 #000000\nset_from_resource $darkyellow color3 #000000\nset_from_resource $yellow color11 #000000\nset_from_resource $darkblue color4 #000000\nset_from_resource $blue color12 #000000\nset_from_resource $darkmagenta color5 #000000\nset_from_resource $magenta color13 #000000\nset_from_resource $darkcyan color6 #000000\nset_from_resource $cyan color14 #000000\nset_from_resource $darkwhite color7 #000000\nset_from_resource $white color15 #000000\n\n# Use custom colors for black\n set $black #282828\n set $darkblack #1d2021\n set $transparent #00000000\n\nset $mod Mod4\nset $mod1 Mod1\nset $terminator terminator\n\n\n# Font for window titles. Will also be used by the bar unless a different font\n# is used in the bar {} block below.\nfont pango:monospace 12\n\n# This font is widely installed, provides lots of unicode glyphs, right-to-left\n# text rendering and scalability on retina\/hidpi displays (thanks to pango).\n\nfont pango:DejaVu Sans Mono 12\n#font pango:Meslo LG L Regular Nerd Font Complete 15\n\n# Use Mouse+$mod to drag floating windows to their wanted position\nfloating_modifier $mod\n\n# start a terminator by pressing Mod key + x or ENTER\nbindsym $mod+Return exec $terminator\nbindsym $mod+x exec $terminator\n\n# Custom bindsyms\nbindsym $mod+p exec ~\/.config\/i3\/bin\/logout\nbindsym $mod+l exec i3lock -i \/home\/koromicha\/Pictures\/linuxtux.png\nbindsym $mod+c exec google-chrome\nbindsym $mod+r mode \"resize\"\nbindsym $mod+Shift+f exec \/home\/koromicha\/.config\/i3\/bin\/rofifinder\n\n\n# Enable Print Screen\n#bindsym --release $mod+Print exec gnome-screenshot -i\nbindsym --release $mod+Print exec shutter -s\n\n# kill focused window\nbindsym $mod+q kill\n\n# start dmenu (a program launcher)\nbindsym $mod+d exec --no-startup-id ~\/.config\/i3\/bin\/rofi_app_launcher\n\n\n# change focus\nbindsym $mod+j focus left\nbindsym $mod+k focus down\n# bindsym $mod+l focus up\nbindsym $mod+semicolon focus right\n\n# alternatively, you can use the cursor keys:\nbindsym $mod+Left focus left\nbindsym $mod+Down focus down\nbindsym $mod+Up focus up\nbindsym $mod+Right focus right\n\n# move focused window\nbindsym $mod+Shift+j move left\nbindsym $mod+Shift+k move down\nbindsym $mod+Shift+l move up\nbindsym $mod+Shift+semicolon move right\n\n# alternatively, you can use the cursor keys:\nbindsym $mod+Shift+Left move left\nbindsym $mod+Shift+Down move down\nbindsym $mod+Shift+Up move up\nbindsym $mod+Shift+Right move right\n\n\n# split in horizontal orientation\nbindsym $mod+h split h\n\n# split in vertical orientation\nbindsym $mod+v split v\n\n# enter fullscreen mode for the focused container\nbindsym $mod+f fullscreen toggle\n\n# change container layout (stacked, tabbed, toggle split)\nbindsym $mod+s layout stacking\n#bindsym $mod+w layout tabbed\nbindsym $mod+t layout tabbed\nbindsym $mod+e layout toggle split\n\n# toggle tiling \/ floating\nbindsym $mod+Shift+space floating toggle\n\n# change focus between tiling \/ floating windows\nbindsym $mod+space focus mode_toggle\n\n# focus the parent container\nbindsym $mod+a focus parent\n# focus the child container\nbindsym $mod+z focus child\n\n# Workspace Variables\nset $ws1 \"1:<\/i> \"\n#set $ws2 \"2:<\/i> \"\nset $ws2 \"2:<\/i> \"\nset $ws3 \"3:<\/i> \"\nset $ws4 \"4:<\/i> \"\nset $ws5 \"5:<\/i> \"\nset $ws6 \"6:<\/i>\"\nset $ws7 \"7:<\/i>\"\nset $ws8 \"8:<\/i> \"\nset $ws9 \"9:<\/i> \"\n\n\n# switch to workspace\nbindsym $mod+1 workspace $ws1\nbindsym $mod+2 workspace $ws2\nbindsym $mod+3 workspace $ws3\nbindsym $mod+4 workspace $ws4\nbindsym $mod+5 workspace $ws5\nbindsym $mod+6 workspace $ws6\nbindsym $mod+7 workspace $ws7\nbindsym $mod+8 workspace $ws8\nbindsym $mod+9 workspace $ws9\nbindsym $mod+0 workspace $ws10\n\n# move focused container to workspace\nbindsym $mod+Shift+1 move container to workspace $ws1\nbindsym $mod+Shift+2 move container to workspace $ws2\nbindsym $mod+Shift+3 move container to workspace $ws3\nbindsym $mod+Shift+4 move container to workspace $ws4\nbindsym $mod+Shift+5 move container to workspace $ws5\nbindsym $mod+Shift+6 move container to workspace $ws6\nbindsym $mod+Shift+7 move container to workspace $ws7\nbindsym $mod+Shift+8 move container to workspace $ws8\nbindsym $mod+Shift+9 move container to workspace $ws9\nbindsym $mod+Shift+0 move container to workspace $ws10\n\n# reload the configuration file\nbindsym $mod+Shift+c reload\n# restart i3 inplace\nbindsym $mod+Shift+r restart\n# exit i3 (logs you out of your X session)\nbindsym $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'\"\n\n# resize window (you can also use the mouse for that)\nmode \"resize\" {\n # These bindings trigger as soon as you enter the resize mode\n\n # Pressing left will shrink the window\u2019s width.\n # Pressing right will grow the window\u2019s width.\n # Pressing up will shrink the window\u2019s height.\n # Pressing down will grow the window\u2019s height.\n bindsym j resize shrink width 10 px or 10 ppt\n bindsym k resize grow height 10 px or 10 ppt\n bindsym l resize shrink height 10 px or 10 ppt\n bindsym semicolon resize grow width 10 px or 10 ppt\n\n # same bindings, but for the arrow keys\n bindsym Left resize shrink width 10 px or 10 ppt\n bindsym Up resize grow height 10 px or 10 ppt\n bindsym Down resize shrink height 10 px or 10 ppt\n bindsym Right resize grow width 10 px or 10 ppt\n\n # back to normal: Enter or Escape\n bindsym Return mode \"default\"\n bindsym Escape mode \"default\"\n}\n#\n# Pulse Audio controls\n# run pactl list sinks\n#bindsym XF86AudioRaiseVolume exec --no-startup-id pactl set-sink-volume 0 +5% #increase sound volume\n#bindsym XF86AudioLowerVolume exec --no-startup-id pactl set-sink-volume 0 -5% #decrease sound volume#\n#bindsym XF86AudioMute exec --no-startup-id pactl set-sink-mute 1 toggle # mute sound\n\n# Amixer\n\nbindsym XF86AudioRaiseVolume exec --no-startup-id amixer -D pulse sset Master 5%+ #increase sound volume\nbindsym XF86AudioLowerVolume exec --no-startup-id amixer -D pulse sset Master 5%- #decrease sound volume#\nbindsym XF86AudioMute exec --no-startup-id amixer -q set Master toggle # mute sound\n\n# Sreen brightness controls\n# enable passwordless sudo for ybacklight. echo \"koromicha ALL=NOPASSWD: \/usr\/bin\/ybacklight\" > \/etc\/sudoers.d\/ybacklight\nbindsym XF86MonBrightnessUp exec sudo ybacklight -inc 5 # increase screen brightness\nbindsym XF86MonBrightnessDown exec sudo ybacklight -dec 5 # decrease screen brightness\n\n# i3blocks\nbar {\n status_command i3blocks\n position top\n font pango:Hack, FontAwesome 11\n\n colors {\n separator #081419\n background #253941\n #statusline #839496\n focused_workspace #fdf6e3 #6c71c4 #fdf6e3\n active_workspace #fdf6e3 #6c71c4 #fdf6e3\n inactive_workspace #002b36 #586e75 #002b36\n urgent_workspace #d33682 #d33682 #fdf6e3\n\n statusline $white\n separator $transparent\n }\n}\n\n\nset $m1 #808080 \nset $m2 #FFF0E0\n\n# Startup programs\nexec --no-startup-id dunst \nexec_always compton &;\nexec --no-startup-id clipit &; \nexec_always feh --bg-scale \/home\/koromicha\/Pictures\/linux-wallpaper.jpg\nexec_always --no-startup-id nm-applet\n\n\n# Bind App to workspace\n# Check class by using xprop command\nassign [class=\"chromium\"] $ws2\nassign [class=\"Firefox\"] $ws2\nassign [class=\"Atom\"] $ws3\nassign [class=\"Foxit Reader\"] $ws3\nassign [class=\"Pcmanfm\"] $ws4\nassign [class=\"VirtualBox\"] $ws5\nassign [class=\"Virt-manager\"] $ws5\nassign [class=\"Skype\"] $ws6\nassign [class=\"mpv\"] $ws9\nassign [class=\"vlc\"] $ws9\nassign [class=\"Thunderbird\"] $ws7\nassign [class=\"(?i)libreoffice-startcenter\"] $ws8\nassign [class=\"(?i)soffice\"] $ws8\nassign [class=\"(?i)libreoffice\"] $ws8\n\n\n# Assign to certain workspace\nassign [window_role=\"browser\"] $ws2\n\n# Press $mod+o followed by either f, s, l, m, v, k, d, t, Esc or Return {ENTER),\n# to launch FoxiReader, Skype, lxappearance, thunderbird, VirtualBox,\n# KVM Virt-manager, spectacle, pcmanfm file manager, \n# or return to the default mode, respectively.\nset $mode_launcher Launcher\nbindsym $mod+o mode \"$mode_launcher\"\n\nmode \"$mode_launcher\" {\n bindsym f exec FoxitReader \n bindsym s exec skypeforlinux\n bindsym l exec lxappearance \n bindsym m exec thunderbird \n bindsym v exec VirtualBox \n bindsym k exec virt-manager \n bindsym d exec spectacle \n bindsym t exec \"pcmanfm \/home\/koromicha\"\n\n bindsym Esc mode \"default\"\n bindsym Return mode \"default\"\n}\n\n# Shutdown, Reboot, Lock Screen, and Logout \n\nset $power_mode \"power\"\nbindsym $mod+Shift+q mode $power_mode\nmode $power_mode {\n bindsym p exec systemctl poweroff\n bindsym r exec systemctl reboot \n bindsym l exec i3lock -i \/home\/koromicha\/Pictures\/linuxtux.png, mode \"default\"\n bindsym q exec --no-startup-id i3-msg exit, mode \"default\"\n bindsym h exec sudo systemctl hibernate \n bindsym s exec sudo systemctl suspend\n bindsym Return mode \"default\"\n bindsym Escape mode \"default\"\n}\n\n# Floating windows\nfor_window [window_role=\"task_dialog|bubble|page-info|Preferences|pop-up\"] floating enable\nfor_window [window_role=\"Open Files\"] floating enable sticky\nfor_window [window_role=\"File Operation Progress\"] floating enable sticky\nfor_window [class=\"qBittorrent\" window_role=\"pop-up\"] floating enable\nfor_window [window_type=\"dialog\"] floating enable\nfor_window [window_type=\"menu\"] floating enable\n\n# Sticky window\nfor_window [instance=\"file_progress\"] sticky enable\nfor_window [class=\"info|Mate-color-select|gcolor2|timesup|QtPass|GtkFileChooserDialog\"] sticky enable\n\n# Focus window settings\nno_focus [window_role=\"pop-up\"]\nfocus_on_window_activation focus\n<\/code><\/pre>\n\n\n\n
<\/figure>\n\n\n\n
What is needed for the above<\/h3>\n\n\n\n
Install Requires packages<\/h4>\n\n\n\n
apt install feh fonts-font-awesome rofi pulseaudio-utils xbacklight alsa-tools clipit gcc git terminator locate pcmanfm acpi libnotify-bin htop<\/code><\/pre>\n\n\n\n
git clone https:\/\/github.com\/szekelyszilv\/ybacklight.git\ncd ybacklight\/src\ngcc ybacklight.c -o \/usr\/bin\/ybacklight<\/code><\/pre>\n\n\n\n
sudo add-apt-repository -y -u ppa:linuxuprising\/shutter\napt install shutter<\/code><\/pre>\n\n\n\n
Install i3 Logout Script<\/h4>\n\n\n\n
$mod+p<\/code><\/strong> key combination, is installed under,
~\/.config\/i3\/bin\/logout<\/strong><\/code>.<\/p>\n\n\n
<\/figure><\/div>\n\n\n
mkdir ~\/.config\/i3\/bin\/\nvim ~\/.config\/i3\/bin\/logout<\/code><\/pre>\n\n\n\n
#!\/usr\/bin\/env bash\n# Manage logout with rofi\noption=`echo -e \"suspend\\nlock screen\\nlogout\\nreboot\\npoweroff\\nKill user $USER\" | rofi -width 600 -dmenu -p system:`\ncase $option in\n suspend)\n sudo \/usr\/bin\/systemctl syspend\n ;;\n 'lock screen')\n i3lock -i \/home\/koromicha\/Pictures\/linuxtux.png\n ;;\n logout)\n i3-nagbar -t warning -m 'Are you sure you want to exit i3? This will end your X session.' -b 'Yes, exit i3' 'i3-msg exit'\n ;;\n reboot)\n \/usr\/bin\/systemctl reboot\n ;;\n poweroff)\n \/usr\/bin\/systemctl poweroff\n ;;\n 'kill user $USER')\n loginctl kill-user $USER\n ;;\nesac\n<\/code><\/pre>\n\n\n\n
chmod +x ~\/.config\/i3\/bin\/logout<\/code><\/pre>\n\n\n\n
Search and Locate Files using Rofi<\/h4>\n\n\n\n
vim ~\/.config\/i3\/bin\/rofifinder<\/code><\/pre>\n\n\n\n
#!\/bin\/bash\nxdg-open \"$(locate -i \/ | rofi -threads 0 -width 100 -dmenu -i -p \"Find\")\"<\/code><\/pre>\n\n\n\n
$mod+Shift+f<\/strong><\/code> key combination. This is how it looks like;<\/p>\n\n\n\n
<\/figure>\n\n\n\n
locate<\/code> command. There install it, if not already install, and update the mlocate database;<\/p>\n\n\n\n
apt install mlocate && updatedb<\/code><\/pre>\n\n\n\n
Launching System Apps using Rofi<\/h4>\n\n\n\n
vim ~\/.config\/i3\/bin\/rofi_app_launcher<\/code><\/pre>\n\n\n\n
#!\/usr\/bin\/env bash\n# Run rofi app launcher\ni3-dmenu-desktop --dmenu=\"rofi -dmenu -i -p 'apps'\"<\/code><\/pre>\n\n\n\n
chmod +x ~\/.config\/i3\/bin\/rofi_app_launcher<\/code><\/pre>\n\n\n\n
# start dmenu (a program launcher)\nbindsym $mod+d exec --no-startup-id ~\/.config\/i3\/bin\/rofi_app_launcher<\/code><\/pre>\n\n\n\n
$mod+d<\/code><\/strong>. See sample launch menu screen;<\/p>\n\n\n
<\/figure><\/div>\n\n\n
rofi-theme-selector<\/strong><\/code>.<\/p>\n\n\n\n
Other customizations;<\/h4>\n\n\n\n
# Enable Print Screen\n#bindsym --release $mod+Print exec gnome-screenshot -i\nbindsym --release $mod+Print exec shutter -s<\/code><\/pre>\n\n\n\n
# kill focused window\nbindsym $mod+q kill<\/code><\/pre>\n\n\n\n
# change focus\nbindsym $mod+j focus left\nbindsym $mod+k focus down\n# bindsym $mod+l focus up\nbindsym $mod+semicolon focus right\n\n# alternatively, you can use the cursor keys:\nbindsym $mod+Left focus left\nbindsym $mod+Down focus down\nbindsym $mod+Up focus up\nbindsym $mod+Right focus right\n\n# move focused window\nbindsym $mod+Shift+j move left\nbindsym $mod+Shift+k move down\nbindsym $mod+Shift+l move up\nbindsym $mod+Shift+semicolon move right\n\n# alternatively, you can use the cursor keys:\nbindsym $mod+Shift+Left move left\nbindsym $mod+Shift+Down move down\nbindsym $mod+Shift+Up move up\nbindsym $mod+Shift+Right move right\n<\/code><\/pre>\n\n\n\n
# split in horizontal orientation\nbindsym $mod+h split h\n\n# split in vertical orientation\nbindsym $mod+v split v<\/code><\/pre>\n\n\n\n
# enter fullscreen mode for the focused container\nbindsym $mod+f fullscreen toggle<\/code><\/pre>\n\n\n\n
$mod+Shift+space<\/code><\/strong>);<\/p>\n\n\n\n
# toggle tiling \/ floating\nbindsym $mod+Shift+space floating toggle<\/code><\/pre>\n\n\n\n
# focus the parent container\nbindsym $mod+a focus parent\n# focus the child container\nbindsym $mod+z focus child<\/code><\/pre>\n\n\n\n
# Workspace Variables\nset $ws1 \"1:<\/i> \"\n#set $ws2 \"2:<\/i> \"\nset $ws2 \"2:<\/i> \"\nset $ws3 \"3:<\/i> \"\nset $ws4 \"4:<\/i> \"\nset $ws5 \"5:<\/i> \"\nset $ws6 \"6:<\/i>\"\nset $ws7 \"7:<\/i>\"\nset $ws8 \"8:<\/i> \"\n<\/code><\/pre>\n\n\n
<\/figure><\/div>\n\n\n
# Bind App to workspace\n# Check class by using xprop command\nassign [class=\"chromium\"] $ws2\nassign [class=\"Firefox\"] $ws2\nassign [class=\"Atom\"] $ws3\nassign [class=\"Foxit Reader\"] $ws3\nassign [class=\"Pcmanfm\"] $ws4\nassign [class=\"VirtualBox\"] $ws5\nassign [class=\"Virt-manager\"] $ws5\nassign [class=\"Skype\"] $ws6\nassign [class=\"mpv\"] $ws9\nassign [class=\"vlc\"] $ws9\nassign [class=\"Thunderbird\"] $ws7\nassign [class=\"(?i)libreoffice-startcenter\"] $ws8\nassign [class=\"(?i)soffice\"] $ws8\nassign [class=\"(?i)libreoffice\"] $ws8\n\n\n# Assign to certain workspace\nassign [window_role=\"browser\"] $ws2\n<\/code><\/pre>\n\n\n\n
Set i3 Wallpaper<\/h5>\n\n\n\n
feh<\/code>, a light-weight, configurable and versatile image viewer. Run the command on terminal.<\/p>\n\n\n\n
feh --bg-scale \/path\/to\/wallpaper.jpg<\/strong><\/code><\/pre>\n\n\n\n
exec_always feh --bg-scale \/path\/to\/wallpaper.jpg<\/strong><\/code><\/pre>\n\n\n\n
Configure i3blocks<\/h4>\n\n\n\n
apt install i3blocks<\/code><\/pre>\n\n\n\n
bar {}<\/code> section with the configs below;<\/p>\n\n\n\n
# i3blocks\nbar {\n status_command i3blocks\n position top\n font pango:Hack, FontAwesome 11\n\n colors {\n separator #081419\n background #253941\n #statusline #839496\n focused_workspace #fdf6e3 #6c71c4 #fdf6e3\n active_workspace #fdf6e3 #6c71c4 #fdf6e3\n inactive_workspace #002b36 #586e75 #002b36\n urgent_workspace #d33682 #d33682 #fdf6e3\n\n statusline $white\n separator $transparent\n }\n}\n<\/code><\/pre>\n\n\n\n