Skip to content

Commit

Permalink
Always enable 16 colors with TERM=xterm
Browse files Browse the repository at this point in the history
See #52.
  • Loading branch information
magiblot committed Apr 11, 2021
1 parent 290ccba commit 287fc13
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions source/platform/termdisp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,10 @@ TermCap TerminalDisplay::getCapabilities()
termcap.quirks |= qfBoldIsBright;
if (TermIO::isLinuxConsole())
termcap.quirks |= qfBlinkIsBright | qfNoItalic | qfNoUnderline;
else if (getEnv<TStringView>("TERM") == "xterm")
// Let's assume all terminals disguising themselves as 'xterm'
// support at least 16 colors.
termcap.colors = Indexed16;
}
}
return termcap;
Expand Down

0 comments on commit 287fc13

Please sign in to comment.