LinuxCommandLibrary

xterm

Open a new terminal window

TLDR

Open the terminal with a title of Example

$ xterm -T [Example]
copy

Open the terminal in fullscreen mode
$ xterm -fullscreen
copy

Open the terminal with a dark blue background and yellow foreground (font color)
$ xterm -bg [darkblue] -fg [yellow]
copy

Open the terminal with 100 characters per line and 35 lines, in screen position x=200px, y=20px
$ xterm -geometry [100]x[35]+[200]+[20]
copy

Open the terminal using a Serif font and a font size equal to 20
$ xterm -fa ['Serif'] -fs [20]
copy

SYNOPSIS

xterm [
-toolkitoption ...] [
-option ...] [
arguments ...]

PARAMETERS

-geometry geometry
    Sets the initial size and position of the xterm window (e.g., 80x24+0+0).

-font font / -fn font
    Specifies the font to be used for displaying text within the terminal.

-background color / -bg color
    Sets the background color of the terminal window.

-foreground color / -fg color
    Sets the foreground (text) color of the terminal window.

-name name
    Specifies the application name for X resource lookups, affecting customizations.

-title title
    Sets the window title string displayed in the window manager's title bar.

-e command [arguments]
    Executes the specified command inside the xterm window instead of a shell.

-hold
    Causes xterm to remain open after the command specified with -e exits.

-sb
    Enables the scrollbar for the terminal window.

-sl number
    Specifies the number of lines to save in the scrollback buffer.

-tn name
    Specifies the terminal type name to be set in the TERM environment variable (e.g., xterm-256color).

-xrm resourcestring
    Specifies an X resource string to be merged with the defaults, allowing fine-tuned customization.

DESCRIPTION

xterm is the standard terminal emulator for the
X Window System, providing a command-line interface within a
graphical environment. Originally developed at
MIT as part of Project Athena in 1984, it is one of the oldest
and most mature terminal emulators available. xterm supports
DEC
VT102 and Tektronix 4014 emulation, offering robust capabilities
for interacting with shell programs and other text-based applications.

Known for its extensive configurability, xterm allows
users to customize nearly every aspect, from fonts and colors
to key bindings and scrolling behavior, primarily through
X resources. Its venerable age also means it has served as a
reference implementation, influencing the design and behavior
of many modern terminal emulators. Despite newer, feature-rich
alternatives, xterm remains a staple for its stability,
reliability, and adherence to established terminal standards.

CAVEATS

xterm's extensive configuration options, primarily
through X resources, can be overwhelmingly complex for new
users. While highly customizable, its default appearance and
feature set (e.g., no native tab support, older font rendering)
might feel dated compared to modern terminal emulators.
Truecolor support and certain advanced graphics features may
require specific patches or configurations not available out-of-the-box.

X RESOURCES

xterm is extensively configured via X resources,
which are parameters loaded from files like
~/.Xresources, ~/.Xdefaults, or set via
xrdb. This mechanism allows fine-grained control over
colors, fonts, key bindings, scrollback, and many other
behaviors, offering a level of customization not always apparent
from command-line options alone.

VT102 AND TEKTRONIX 4014 EMULATION

A key feature of xterm is its ability to
emulate two historically significant terminals: the
DEC
VT102 and the
Tektronix 4014. VT102 emulation provides standard text-based
interaction, while Tektronix 4014 emulation offers support for
vector graphics, a feature less commonly used today but
historically important for certain scientific and engineering
applications.

HISTORY

xterm was originally developed by
Mark Vandevoorde and
Tony Della Fera at
Digital Equipment Corporation (DEC) for the
X Window System, as part of
MIT's
Project Athena. It was first released in 1984 as a core
component of the inaugural X Window System distribution.
Over the decades, xterm has been maintained and continually
updated by various contributors, becoming a stable and reliable
fixture in Unix-like environments. Its long history and adherence
to established terminal standards have made it a de facto
reference implementation, influencing the design and behavior
of countless subsequent terminal emulators.

SEE ALSO

gnome-terminal(1), konsole(1), urxvt(1), alacritty(1), bash(1), X(7), xrdb(1)

Copied to clipboard