Terminal Emulators

A terminal emulator is a program used to interact directly with your OS via text input. Named as "emulators" because they are a software version of the old fashioned hardware terminals . Most OSes will come with a terminal emulator, Windows includes Windows Terminal and Powershell , macOS includes Terminal . Linux desktop environments generally have their own terminal emulators, for example Xfce Terminal , Gnome Terminal or Konsole (for KDE).

This page mainly discusses Linux terminal emulators. Terminal emulators from one distro can be installed on another, and there are a variety of "third party" options to choose from as well.

Alacritty

Alacritty is a terminal emulator written in Rust, designed for speed and easy customisability.

Configuration

To change the default configuration, edit the config file (~/.config/alacritty/alacritty.yml). If this config file doesn't exist, the default one (normally located at /usr/share/doc/alacritty/example/alacritty.yml) can be copied to the config folder, or one can be created.

Note: Alacritty recently changed from using yml to toml for config. I will include both types here incase an older version is being used.

Useful Config Tips

To change cursor from block to beam:

yml

cursor:
  style:
    shape: Beam

toml

[cursor.style]
shape = "Beam"

To change default window size on opening:

yml

window:
  dimensions:
    columns: 100
    lines: 25

toml

[window.dimensions]
columns = 100
lines = 25

By default, links are clickable without holding down ctrl. This can be annoying, to enable clicking links only when holding control, use:

yml

hints:
  enabled:
  - regex: "(mailto:|gemini:|gopher:|https:|http:|news:|file:|git:|ssh:|ftp:)\
            [^\u0000-\u001F\u007F-\u009F<>\"\\s{-}\\^⟨⟩`]+"
    command: xdg-open
    post_processing: true
    mouse:
      enabled: true
      mods: Control

toml

[[hints.enabled]]
command = "xdg-open"
post_processing = true
regex = "(mailto:|gemini:|gopher:|https:|http:|news:|file:|git:|ssh:|ftp:)[^\u0000-\u001F\u007F-Ÿ<>\"\\s{-}\\^⟨⟩`]+"

[hints.enabled.mouse]
enabled = true
mods = "Control"

Source for this config trick: https://mitjafelicijan.com/alacritty-open-links-with-modifier.html

Usage

Vi mode

Troubleshooting

Wayland Titlebar

In order to get a titlebar on Wayland, it is neccessary to set the WAYLAND_DISPLAY environmental variable to empty. This can be done in the same command that launches Alacritty:

env -u WAYLAND_DISPLAY alacritty

Ueberzug Issues

Ueberzug is a program to display images "in" any terminal emulator, It works by calculating the position a window should be in, then opening the image in a seperate borderless window and "locking" it to the terminal. Ueberzug is used in a variety of programs, for example ranger file manager , and my own GoTube YouTube terminal client .
By default, Alacritty will "pad" the window only on the right and the bottom. This padding occurs when the window size is not an exact multiple of the cell size. Ueberzug does not detect this, and thus the images will be misaligned. Enabling "Dynamic Padding" solves this issue by making alaceritty pad evenly on all sides.

To enable dynamic padding, add the following to alacritty.toml

yml

window:
  dynamic_padding: true

toml

[window]
dynamic_padding = true

Xfce Terminal

Xfce Terminal comes by default in the Xfce4 Desktop Environment .

Cool Retro Term

Cool Retro Term is a terminal emulator designed to look like a CRT display, written using the QT5 UI library .