5

I would like to set in my terminal emulator (i.e. gnome-terminal) the color of the tabs like in the osx's terminal emulator. Is there this feature in any of the linux terminal emulator plethora?

EDIT: below a picture to better explain the desired result.

enter image description here

hairesis
  • 151
  • 3

1 Answers1

0

I don't know what OS/X's terminal emulator does with colour on tabs, but if using GNU screen in xterm, you could add something like:

hardstatus string '%D %d %M - %c - %h (%n)^G^[]11;TekHVC:%n10/80/20'

To your ~/.screenrc to have a different background colour in every screen window/tab/pane (however you want to call them).

screen displays the hard status in the xterm title bar by outputting something like:

\e]2;blah\a

Above we set blah to include \a\e]11;TekHVC:%n10/80/20 where %n is expanded to the window number so for the first window, it becomes:

\e]2;...\a\e]11;TekHVC:010/80/20\a

\e]11;...\a is the xterm escape sequence to set the background colour. It supports various colour specifications, those supported by XParseColor from the X libraries. The TekHVC:Hue/Value/Chroma one, where Hue takes values from 0 to 360 (and wraps) allows us to select a different colour for each window (10, 110, 210, 310, 410 (aka 50), 150, 250...)

Stéphane Chazelas
  • 522,931
  • 91
  • 1,010
  • 1,501