Read more

xterm: Have a black background by default

Arne Hartherz
April 20, 2012Software engineer at makandra GmbH

xterm by default uses black text on white background.

Illustration UI/UX Design

UI/UX Design by makandra brand

We make sure that your target audience has the best possible experience with your digital product. You get:

  • Design tailored to your audience
  • Proven processes customized to your needs
  • An expert team of experienced designers
Read more Show archive.org snapshot

To change that to something like "light gray on black", do a

vim ~/.Xresources

...and put this in there:

xterm*background: black
xterm*foreground: lightgray

Afterwards, feed these changes to your current X session:

xrdb ~/.Xresources

Any subsequent xterm will be colored white on black background.

Hint:

  • While you're at it, you can also set xterm's font in your ~/.Xresources file. Just add xterm*faceName: monospace:pixelsize=14.
  • If you don't want to change your default, use command line arguments: xterm -bg blue -fg yellow
  • Setting xterm*background or xterm*foreground changes all xterm colors, including menus etc. To change it for the terminal area only, set xterm*vt100.background and xterm*vt100.foreground -- unfortunately, -bg and -fg will no longer work properly this way.
Posted by Arne Hartherz to makandra dev (2012-04-20 16:53)