aboutsummaryrefslogtreecommitdiff
path: root/runtime
diff options
context:
space:
mode:
authorJonathan de Boyne Pollard <J.deBoynePollard-newsgroups@NTLWorld.com>2017-06-05 22:47:44 +0100
committerJonathan de Boyne Pollard <J.deBoynePollard-newsgroups@NTLWorld.com>2017-06-05 22:47:44 +0100
commitb22a61cdbba68ae88a58dd39f288a7bb13c5558d (patch)
tree2c5a51be423ed6d8d6d8047aa61244a8817d04e4 /runtime
parent054b03e07ac8c27f49afba7225a20214697a3720 (diff)
downloadrneovim-b22a61cdbba68ae88a58dd39f288a7bb13c5558d.tar.gz
rneovim-b22a61cdbba68ae88a58dd39f288a7bb13c5558d.tar.bz2
rneovim-b22a61cdbba68ae88a58dd39f288a7bb13c5558d.zip
tui: Recognize "Tc" terminfo capability.
This is a new convention pioneered by tmux. It does not do much for nvim; since nvim always looks to see whether it should be making up "setrgbf" and "setrgbb" capabilities. But it is a way for terminfo to force this, irrespective of the hardwired list in the code, for more terminal types. On the gripping hand, updating terminfo descriptions to actually have "setrgbf" and "setrgbb" capabilities so that nvim never has to try to invent them in the first place, is as good if not better an approach for overriding what is baked into the code.
Diffstat (limited to 'runtime')
-rw-r--r--runtime/doc/term.txt24
1 files changed, 19 insertions, 5 deletions
diff --git a/runtime/doc/term.txt b/runtime/doc/term.txt
index 2a6b09a9ff..951947d865 100644
--- a/runtime/doc/term.txt
+++ b/runtime/doc/term.txt
@@ -134,11 +134,25 @@ support it. It uses the same |terminfo| extensions that were proposed by
RĂ¼diger Sonderfeld in 2013 for this: "setrgbf" and "setrgbb". If your
terminfo definition specifies these, then nothing more is required.
-If your terminfo definition is missing them, then Nvim will on a wide range of
-terminals resort to using the ISO 8613-6:1994/ITU T.416:1993 control sequences
-for setting RGB colours. This includes the "rxvt", "linux", "st", and "iterm"
-terminal types, or when Konsole, genuine Xterm, or a terminal emulator that
-sets the COLORTERM environment variable to "truecolor" is detected.
+If your terminfo definition is missing them, then Nvim will decide whether to
+add them to your terminfo definition, using the ISO 8613-6:1994/ITU T.416:1993
+control sequences for setting RGB colours, but modified to use semicolons
+instead of colons unless the terminal is known to follow the standard.
+(Semicolons cause ambiguities that the standard avoided by specifying colons
+as a sub-parameter delimiter. A historical misunderstanding meant that many
+terminal emulators ended up using semicolons for many years, though.)
+
+A new convention, pioneered in 2016 by tmux, is the "Tc" terminfo extension.
+If your terminal's terminfo definition has this flag, Nvim will add
+constructed "setrgbf" and "setrgbb" capabilities as if they had been in the
+terminfo definition.
+
+If your terminal's terminfo definition does not (yet) have this flag, Nvim
+will fall back to looking at the TERM and other environment variables. For
+the "rxvt", "linux", "st", and "iterm" terminal types, or when Konsole,
+genuine Xterm, or a terminal emulator that sets the COLORTERM environment
+variable to "truecolor" is detected, it will also add constructed "setrgbf"
+and "setrgbb" capabilities.
*xterm-resize*
Nvim can resize the terminal display on some terminals that implement an