aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJan Edmund Lazo <jan.lazo@mail.utoronto.ca>2020-01-05 22:51:49 -0500
committerJan Edmund Lazo <jan.lazo@mail.utoronto.ca>2020-01-06 00:18:02 -0500
commit3c764aabb5d4be71a5ea0d50bf8dae0a7285677f (patch)
treeac378578c34bdf175816d8e4939eb0364eb746d7 /src
parent1aacab49ea0e5cff94bd89595737b6af677f4490 (diff)
downloadrneovim-3c764aabb5d4be71a5ea0d50bf8dae0a7285677f.tar.gz
rneovim-3c764aabb5d4be71a5ea0d50bf8dae0a7285677f.tar.bz2
rneovim-3c764aabb5d4be71a5ea0d50bf8dae0a7285677f.zip
vim-patch:8.1.1308: the Normal highlight is not defined when compiled with GUI
Problem: The Normal highlight is not defined when compiled with GUI. Solution: Always define Normal. (Christian Brabandt, closes vim/vim#4072) https://github.com/vim/vim/commit/f90b6e03a983b62b66564fc449e32724d6456769
Diffstat (limited to 'src')
-rw-r--r--src/nvim/syntax.c3
-rw-r--r--src/nvim/testdir/test_highlight.vim7
2 files changed, 8 insertions, 2 deletions
diff --git a/src/nvim/syntax.c b/src/nvim/syntax.c
index 61ee225eba..bcf133afda 100644
--- a/src/nvim/syntax.c
+++ b/src/nvim/syntax.c
@@ -5959,6 +5959,7 @@ static const char *highlight_init_both[] = {
"IncSearch cterm=reverse gui=reverse",
"ModeMsg cterm=bold gui=bold",
"NonText ctermfg=Blue gui=bold guifg=Blue",
+ "Normal cterm=NONE gui=NONE",
"PmenuSbar ctermbg=Grey guibg=Grey",
"StatusLine cterm=reverse,bold gui=reverse,bold",
"StatusLineNC cterm=reverse gui=reverse",
@@ -6010,7 +6011,6 @@ static const char *highlight_init_light[] = {
"Title ctermfg=DarkMagenta gui=bold guifg=Magenta",
"Visual guibg=LightGrey",
"WarningMsg ctermfg=DarkRed guifg=Red",
- "Normal gui=NONE",
NULL
};
@@ -6044,7 +6044,6 @@ static const char *highlight_init_dark[] = {
"Title ctermfg=LightMagenta gui=bold guifg=Magenta",
"Visual guibg=DarkGrey",
"WarningMsg ctermfg=LightRed guifg=Red",
- "Normal gui=NONE",
NULL
};
diff --git a/src/nvim/testdir/test_highlight.vim b/src/nvim/testdir/test_highlight.vim
index d94eb7c3a2..b9aeff0907 100644
--- a/src/nvim/testdir/test_highlight.vim
+++ b/src/nvim/testdir/test_highlight.vim
@@ -591,3 +591,10 @@ func Test_cursorline_with_visualmode()
call StopVimInTerminal(buf)
call delete('Xtest_cursorline_with_visualmode')
endfunc
+
+func Test_1_highlight_Normalgroup_exists()
+ " This test must come before the Test_cursorline test, as it appears this
+ " defines the Normal highlighting group anyway.
+ let hlNormal = HighlightArgs('Normal')
+ call assert_match('hi Normal\s*clear', hlNormal)
+endfunc