xoria256 terminal color scheme
I have grown fond of Vim’s xoria256 color
scheme recently.
It features “finely tuned soft gamma” using 256 colors on a dark
background, and claims to appear the same in both graphical and terminal
Vim; although I found the latter to be slightly muted (particularly 8
units less in byte value in at most two color channels) according to
xmag
and gcolor2
.
I ported it to the terminal last night (see screenshots below) and was pleased with the result: it felt balanced, colorful, and easy on my eyes.
To use this color scheme in hterm, open the nassh extension’s settings page, open Chrome Developer Tools, and then run the following snippet in the console:
term_.prefs_.set("background-color", "#1c1c1c");
term_.prefs_.set("foreground-color", "#d0d0d0");
term_.prefs_.set("cursor-color", "rgba(255,175,0, 0.5)"); /* #ffaf00 */
term_.prefs_.set("color-palette-overrides", ["#121212", "#d78787", "#afd787",
"#f7f7af", "#87afd7", "#d7afd7", "#afd7d7", "#e6e6e6", "#0a0a0a", "#df8787",
"#afdf87", "#ffffaf", "#87afdf", "#dfafdf", "#afdfdf", "#eeeeee"]);
To use this color scheme in Rxvt or XTerm, save the following snippet to a file
such as ~/.Xdefaults
and then run xrdb -merge
on that file to apply it. Any
terminals launched thereafter will use this color scheme, but not existing ones.
!black.normal : xoria256.LineNr.guibg
!black.bright : black.normal.rgb - 8
#define _color0 #121212
#define _color8 #0a0a0a
!red.normal : red.bright.r - 8
!red.bright : xoria256.Special.guifg
#define _color1 #d78787
#define _color9 #df8787
!green.normal : green.bright.g - 8
!green.bright : xoria256.PreProc.guifg
#define _color2 #afd787
#define _color10 #afdf87
!yellow.normal : yellow.bright.rg - 8
!yellow.bright : xoria256.Special.guifg
#define _color3 #f7f7af
#define _color11 #ffffaf
!blue.normal : blue.bright.b - 8
!blue.bright : xoria256.Statement.guifg
#define _color4 #87afd7
#define _color12 #87afdf
!magenta.normal : magenta.bright.rb - 8
!magenta.bright : xoria256.Identifier.guifg
#define _color5 #d7afd7
#define _color13 #dfafdf
!cyan.normal : cyan.bright.gb - 8
!cyan.bright : green.bright + blue.bright
#define _color6 #afd7d7
#define _color14 #afdfdf
!white.normal : white.bright.rgb - 8
!white.bright : xoria256.Folded.guifg
#define _color7 #e6e6e6
#define _color15 #eeeeee
!bold : xoria256.Type.guifg
!underline : xoria256.htmlValue.guifg
#define _colorBD #afafdf
#define _colorUL #dfdfaf
!foreground : xoria256.Normal.guifg
!background : xoria256.Normal.guibg
!cursorColor : xoria256.Cursor.guibg
#define _foreground #d0d0d0
#define _background #1c1c1c
#define _cursorColor #ffaf00
URxvt*color0 : _color0
URxvt*color1 : _color1
URxvt*color2 : _color2
URxvt*color3 : _color3
URxvt*color4 : _color4
URxvt*color5 : _color5
URxvt*color6 : _color6
URxvt*color7 : _color7
URxvt*color8 : _color8
URxvt*color9 : _color9
URxvt*color10 : _color10
URxvt*color11 : _color11
URxvt*color12 : _color12
URxvt*color13 : _color13
URxvt*color14 : _color14
URxvt*color15 : _color15
URxvt*colorBD : _colorBD
URxvt*colorIT : _colorIT
URxvt*colorUL : _colorUL
URxvt*foreground : _foreground
URxvt*background : _background
URxvt*cursorColor : _cursorColor
XTerm*color0 : _color0
XTerm*color1 : _color1
XTerm*color2 : _color2
XTerm*color3 : _color3
XTerm*color4 : _color4
XTerm*color5 : _color5
XTerm*color6 : _color6
XTerm*color7 : _color7
XTerm*color8 : _color8
XTerm*color9 : _color9
XTerm*color10 : _color10
XTerm*color11 : _color11
XTerm*color12 : _color12
XTerm*color13 : _color13
XTerm*color14 : _color14
XTerm*color15 : _color15
XTerm*colorBD : _colorBD
XTerm*colorIT : _colorIT
XTerm*colorUL : _colorUL
XTerm*foreground : _foreground
XTerm*background : _background
XTerm*cursorColor : _cursorColor
! enable coloring for bold and underlined text
XTerm*vt100.boldColors : False
XTerm*vt100.colorBDMode : True
XTerm*vt100.colorULMode : True
XTerm*vt100.colorRVMode : False
XTerm*vt100.veryBoldColors : 6