diff options
author | Christian Brabandt <cb@256bit.org> | 2024-02-05 10:30:01 +0100 |
---|---|---|
committer | Christian Brabandt <cb@256bit.org> | 2024-02-05 10:34:26 +0100 |
commit | 0f4054feb66ea55414f97add63b3070d7d7b5295 (patch) | |
tree | 4b632c5a1ef083d216d8fe3daf35f201748bb1f2 /runtime/doc/syntax.txt | |
parent | de7f5bde6c598d4da4ce5b30328eb458962ba60a (diff) |
runtime(colors): color names in the v:colornames dict should be lower cased
Vim will lookup color names from the v:colornames dictionary by its
lower case color name. So when sourcing the v:colornames dictionary,
make sure to convert upper case color names to lower case.
Also, while at it, mention in the documentation, that the dictionary
should contain lower case names only.
fixes: #13976
Signed-off-by: Christian Brabandt <cb@256bit.org>
Diffstat (limited to 'runtime/doc/syntax.txt')
-rw-r--r-- | runtime/doc/syntax.txt | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/runtime/doc/syntax.txt b/runtime/doc/syntax.txt index c4f59aee1b..1c9f6f2b58 100644 --- a/runtime/doc/syntax.txt +++ b/runtime/doc/syntax.txt @@ -1,4 +1,4 @@ -*syntax.txt* For Vim version 9.1. Last change: 2024 Jan 24 +*syntax.txt* For Vim version 9.1. Last change: 2024 Feb 05 VIM REFERENCE MANUAL by Bram Moolenaar @@ -5265,7 +5265,8 @@ ctermul={color-nr} *highlight-ctermul* "cterm=" argument AFTER the "ctermfg=" or "ctermbg=" argument. Or use a number instead of a color name. - The case of the color names is ignored. + The case of the color names is ignored, however Vim will use lower + case color names when reading from the |v:colornames| dictionary. Note that for 16 color ansi style terminals (including xterms), the numbers in the NR-8 column is used. Here '*' means 'add 8' so that Blue is 12, DarkGray is 8 etc. @@ -5384,8 +5385,8 @@ guisp={color-name} *highlight-guisp* :highlight Comment guifg=#11f0c3 guibg=#ff00ff < If you are authoring a color scheme and use the same hexadecimal value - repeatedly, you can define a name for it in |v:colornames|. For - example: > + repeatedly, you can define a (lower case) name for it in |v:colornames|. + For example: > # provide a default value for this color but allow the user to # override it. |