Setup and configure xterm as your default terminal emulator

In order to set xterm as default terminal emulator for Ubuntu/Unity or IceWM and to make it a bit nicer (appearance and scrolling behaviour), I will give some short tips here.

First we need to edit the $HOME/.Xresources file:

! Adjusting the font
xterm*faceName: Monospace
xterm*faceSize: 11
 
! Changing foreground/background color
xterm*background: #2B1520
xterm*foreground: #FFFFFF
 
! Adding a scroll-bar on the right side
xterm*scrollBar: true
xterm*rightScrollBar:true
 
! prevent jumping back to the last line with new output
xterm*scrollTtyOutput: false
 
! add keyboard shortcuts to jump to beginning/end
xterm*vt100.translations: #override \n\
 Shift <Key>Home: scroll-forw(10000000000) \n\
 Shift <Key>End: scroll-back(10000000000)

In order to activate our changes, we need to load them:

xrdb -merge ~/.Xresources

If you don’t execute this, your changes in .Xresources will have absolutely no effect.

Opening a terminal (we will change the default to xterm in a minute) and starting xterm should show the effect of our changed .Xresources.

To better control the scrolling, remember the following shortcuts:

Shortcut Function
CTRL-s stop auto-scrolling
CTRL-q continue auto-scrolling
SHIFT-up/down scroll up down
SHIFT-home/enter Jump to start/end of screen

Klicking with the left/right mouse button on the scrollbar lets you scroll down/up, respectively, and draging the scrollbar is possible using the middle mouse button.

In order to start the xterm by pressing CTRL-ALT-T, we need to set the keybord shortcut and default terminal emulator.

In IceWM we simply edit the configuration file for the keyboard shortcut ($HOME/.icewm/keys) adding the following line:

key "Alt+Ctrl+t" xterm

Hitting CTRL-ALT-T should now start the xterm with our new default settings (if not, restart IceWM).

To set your default terminal in UNITY, simply enter

gsettings set org.gnome.desktop.default-applications.terminal exec 'xterm'

in your shell, making xterm your default terminal emulator. If you set CTRL-ALT-T as the key-combination for All Settings->Keyboard->Shortcuts->Launchers=>Launch terminal (search for keyboard in Unity search), hitting the key combination should launch your xterm as your default terminal emulator with the new settings.

I hope that helps!

PS: in some guides you find that you should change the default terminal emulator by calling 

sudo update-alternatives --config x-terminal-emulator

and selecting xterm as your default terminal. Unfortunately, this did not work for me on an Ubuntu 14.4 machine, as it startet the root terminal, not loading the configurations we set up earlier – might be different for other machines though, so you might want to give it a try, if the aforementioned method does not work.