Saturday, November 21, 2015

Xubuntu with i3 Tiling Windows Walkthrough

Also look up Manjaro i3. Manjaro is an Arch Linux distro.
See the Lubuntu version of this here.

The idea of this setup is to achieve the best of both worlds from convenient desktop features and essential i3 features. This walkthrough assumes that you are already familiar with using i3, but you do not have to be in order to complete it. An altered default i3 config file is part of the walkthrough, which adapts default i3 keystrokes to XFCE components. (New and replaced sections of the config file are designated in the file.)

  • Use the familiar i3 keystrokes and config file for window tiling.
  • Utilize normal application names instead of binaries'. (dmenu still available)
  • Desktop notifications/indicators (not typically easy to find for i3)
  • Fixes the administrator authentication problem when using i3 in Ubuntu.
    • Software Center
    • Updater
    • Users and Groups
  • Elegant color scheme and icons

As usual, i3 is brought to you by the letter i and by the number 3 . . . and by Dexter.

For this guide, you will need to enter terminal commands, but you should not expect to remember them. Conversely, you will always want to understand the i3 config file. The last step will be to create a link to the i3 configuration file on you XFCE panel - to provide a visual reminder that it is central to your user experience, and conveniently available to open and edit.

The i3 site provides the best source about editing the configuration file.

I. Install Xubuntu on your system

Install the Xubuntu desktop in another Ubuntu variant by entering the following in a terminal:

(The general idea of this walkthrough should work for XFCE and Mint XFCE as well.)


 II. Create a Spare User

Especially if you are already using Xubuntu, creating a spare user account ensures that you can easily return to Xubuntu's default desktop.
  1. Open 'Users and Groups'
  2. Click button: 'Add'
  3. Type in your current admin password
  4. Enter a Name title
  5. Enter the official username
  6. Click button: 'OK'
  7. Enter the new user's password
  8. Click button: 'OK'
  9. Click 'Change...', next to 'Account type'
  10. Change the account type to 'Administrator
  11. Click button: 'OK'
  12. Click button: 'Close'
  13. Log out
  14. Select the Xubuntu desktop 
  15. Log in to the new user

III. Install a new background image manager

Xubuntu's desktop settings manager will not work with this setup, but luckily you can install "nitrogen" to change background images. Only remove xfdesktop4 if you (Unfortunately wallch does not work with i3.)

Nitrogen is simple and plays well with i3. It has the ability to set different wallpapers for different monitors or to expand one wallpaper between them.

  1. Open Nitrogen.
  2. Click "Preferences"
  3. Click "Add"
  4. Add any folders you use for background images
    • /usr/share/backgrounds
    • /usr/share/xfce4/backdrop

IV. Install the i3 Window Manager

Enter the following in a terminal to install the i3 window manager:

V. Install i3ipc-GLib and i3 Workspaces Plugin

This is a prerequisite for being able to switch between i3 workspaces in XFCE.

Open a terminal and enter the following:

(The details of this source are found here.)
  • Installing individual sources like this should be done rarely. There is a slight security risk, and it can slow down apt updates 


This wonderful plugin allows you to place an i3-compatible workstation switcher on your XFCE panel.

Open a terminal and enter the following:

(The details of this source are found here.)
  • Installing individual sources like this should be done rarely. There is a slight security risk, and it can slow down apt updates

VI. Deactivate Xubuntu's window manager

  1. Open 'Session and Startup', and go to the 'Session' tab.
  2. Note xfwm4 and xfdesktop. These processes will be replaced by the i3 Window Manager.
  3. For xfwm4, click 'Immediately' and change it to the  'Never' option.
  4. For xfdesktop, click 'Immediately' and change it to the 'Never' option.
  5. Click the button: 'Save Session'.
  6. Go to the 'Application Autostart' tab to activate the i3 window manager in the next stage.

Note that you leave the xfce4-panel and Xfsettingsd as they are.

VII. Activate the i3 window manager

  1.  In the 'Session and Startup' window, make sure you are in the 'Application Autostart' tab.
  2. Click the button 'Add' to add i3 to the list of startup applications.
  3. Fill out the form:
    • Name: i3 (or whatever you want to call i3)
    • Description: Tiling Window Manager (or whatever you want)
    • Command: i3 (must be "i3", as below)
  4. Click the button: OK
  5. You should scroll down to the bottom of the list and verify that i3 is listed and checked.
    • (Yes, the intimidating terminal command to start i3 is . . . i3.)
  6. Click the button: Close

VIII. Remove non-i3 Keyboard Shortcuts

Disabling the shortcuts here is about letting i3 take over in this regard, utilizing the i3 config file. Although my general philosophy is to avoid getting technical wherever possible (ie: avoid using a config file when a GUI is available), managing keyboard shortcuts through the i3 config file is inevitable if you want to use i3 at all. For the sake of peace-of-mind, as well as avoiding strange conflicts, I say avoid using 2 different applications for managing keyboard shortcuts. In this guide, ALL keyboard shortcuts are defined by the i3 config, rather than some here and some there. bleh.

  1. Open the 'Keyboard' dialogue.
  2. Go to the 'Application Shortcuts' tab as above.
  3. Remove all keyboard shortcuts
    • You can shift-select all of them and click the button: 'Remove
  4. Click the button: Close

IX. Paste i3 config

Let's get down to brass tacks and just do this thing.
  1. Create a directory in your user's home directory named '.i3'
    • The file path will be like: /home/<yourusername>/.i3/
  2. Create a new file in the .i3 directory named 'config'
    • the file path will be like: /home/<yourusername>/.i3/config
  3. Open the config file in a text editor and save the following in the file:

The i3 site provides the best source for editing the configuration file.

Here is the magic moment when you can restart your computer and log in with i3 as your window manager.

i3 cheat sheet

The mod key is the 'super key', also called the 'windows key' (left of the space-bar.)

mod+Enter opens a terminal
mod+d opens Xubuntu's whisker menu (in place of the dmenu)
mod+Shift+d opens the dmenu
mod+Shift+q closes the current window tile
mod+r initiates resize-tile mode
mod+1, mod+2, etc. (1-0) switches to a different workspace
mod+Shift+1, mod+Shift+2, etc. (1-0) moves the current window tile to a different workspace
mod+Shift+` (` is left of '1') Moves a window tile to the scratch-pad workspace
mod+` Reveals/hides the scratch-pad workspace
mod+Shift+e initiates Xubuntu's session logout dialogue

X. Configure the XFCE Panel

  1. Right-click the XFCE Panel at the top of the screen.
  2. Select the menu option 'Panel >' and then 'Panel Preferences'
    • The panel preferences dialogue should open
    • This looks different in Xubuntu 16.04.
  3. Click on the plus button to add the i3 workspaces plugin you installed earlier.
  4. Use the arrows to place the i3 workspaces plugin where you want it on the panel.
  5. Click the gear button, and configure the i3 workspaces plugin with colors that will show up on the panel.
    • I like to incorporate the i3 window color, which is #285577
  6. Remove the 'Window Buttons' from the panel items by selecting it and clicking the minus button.
  7. You can change the icon on the 'Whisker Menu' so that it is not an infantile mouse icon.
  8. Add or remove any application launchers to the panel.

XI. Create a launcher for i3's config file

  1. In the XFCE Panel items list, add a launcher next to the clock in order to create convenient access to the i3 config file.
  2. Edit the launcher details to be as below
    • Click the icon to change it. (The icon above is included with xubuntu-desktop)
    • Name: i3 Config
    • Command: mousepad config
    • Working Directory: /home/<yourusername>/.i3

The i3 site provides the best source about editing the configuration file.

Sunday, September 6, 2015

Install Minecraft in Ubuntu

Lubuntu 15.10, i3 Window Manager, ASUS G74sx-DH71

Install Oracle Java (Minecraft site suggests this version)me.)

  1. sudo apt-get purge openjdk-\*
  2. sudo add-apt-repository ppa:webupd8team/java 
  3. sudo apt-get update 
  4. sudo apt-get install oracle-java8-installer

Download Minecraft

Minecraft Download page


 Install Minecraft

  1. Navigate to the download folder in the command line
    • cd /home/<user directory>/Downloads
  2. java -jar Minecraft.jar

Create Custom Minecraft launcher script

(good for dmenu in i3 window manager)
  1. cd /usr/local/bin
  2. sudo touch minecraft
  3. sudo chmod +x minecraft
  4. sudo chown <username> minecraft
  5. sudo chgrp <username> minecraft
  6. sudo echo "#!/bin/bash" > minecraft
  7. sudo echo "java -jar /home/<user_directory>/.minecraft/launcher.jar" > minecraft

Sunday, April 5, 2015

The Mint Skyrim Guide

Running Cinnamon Mint 17
This should work for any Ubuntu-based system that can run PlayOnLinux and has an NVIDIA card.
  1. Install NVIDIA Drivers and restart
    1. Open 'Driver Manager' >>  Select version >> Apply Changes
    2. restart
  2. Install PlayOnLinux
    1. Open 'Software Manager' >> Search and Install 'PlayOnLinux'
  3. Set ptrace_scope to '0'

    • echo "0" | sudo tee /proc/sys/kernel/yama/ptrace_scope

    Open PlayOnLinux

    1. Tools >> Manage Wine Versions >> x86 >> version 1.7.8
    2. Configure >> New
      1. name it "skyrim"
    3. Configure >> 'skyrim' drive >> 'Wine' tab
      • Configure Wine >> Applications >> Windows Version >> 'Windows 7' >> 'OK'
    4. Configure >> 'skyrim' drive >> 'Display' tab
      • GLSL Support > default
      • Direct Draw Renderer > opengl
      • Video memory size > (maximum allowed)
      • Offscreen redering mode > fb0
      • Render target mode lock > default
      • Multisampling > default
      • Strict Draw Ordering > default
    5.  Configure >> 'skyrim' drive >> 'Install Components' tab
      1. Microsoft Core Fonts
      2. xact
      3. tahoma
      4. vcrun2008
      5. d3dx9
      6. d3dx10
      7. Steam
  4. Log in to Steam and Install Skyrim from Steam
    • while you are waiting for Skyrim to download, adjust settings in Steam
      •  In the top menu: Steam >> Settings >> in-game >> deactivate steam overlay
  5. PlayOnLinux >> Configure >> 'skyrim' drive >> 'General' tab
    1. 'Debug flags' > "-no-dwrite
    2. 'Make a new shortcut . . .'
      • TESV >> "Skyrim"
      • skyrim launcher >> "Skyrim Options"
      • steam >> "Steam" or "Skyrim Steam"

  • Skyrim's launcher options 
  • disable vertical sync in NVIDIA's settings
  • bookmark the skyrim installation folder
    • disable vertical sync in Skyrim's settings
    • workaround for the opaque water problem

  • More Specific Skyrim Tweaks
  • SKSE and Mods
    • workshop mods
    • nexus mods
  • mod for the opaque water problem

SteamOS with wine?

Saturday, April 4, 2015

Make a simple TiddlyWiki 'app' using Firefox

(Doing this in Cinnamon/i3wm, in Mint 17)
This will set up a dedicated app feel for TiddlyWiki. (and of course, this could be done for any web app, site, or offline stuff you want.
  1. Install Firefox
  2. Set up your TiddlyWiki
  3. Create a distinct Firefox profile
  4. Set up extensions: TiddlyFox and Toolbar Autohide
  5. Set your TiddlyWiki as the home page 
  6. Create a launcher/script to open your 'app'
    • (firefox -P tiddlywiki --no-remote /<path>/<tiddlyfile>.htm)

TiddlyWiki IS:
  • A PIM (Personal Information Manager)
  • A wiki
    • text formatting requires wiki markup similar to MediaWiki markup
  • An offline webpage
    • The TiddlyWiki is completely contained within a single html file
    • It is programmed in JavaScript