mirror of
https://github.com/zoriya/vim.git
synced 2025-12-19 13:45:18 +00:00
patch 8.0.0941: existing color schemes don't like StatusLineTerm
Problem: Existing color schemes don't work well with StatusLineTerm.
Solution: Don't use "reverse", use fg and bg colors. Also add
StatusLineTermNC.
This commit is contained in:
@@ -364,6 +364,7 @@ EXTERN int highlight_user[9]; /* User[1-9] attributes */
|
|||||||
EXTERN int highlight_stlnc[9]; /* On top of user */
|
EXTERN int highlight_stlnc[9]; /* On top of user */
|
||||||
# ifdef FEAT_TERMINAL
|
# ifdef FEAT_TERMINAL
|
||||||
EXTERN int highlight_stlterm[9]; /* On top of user */
|
EXTERN int highlight_stlterm[9]; /* On top of user */
|
||||||
|
EXTERN int highlight_stltermnc[9]; /* On top of user */
|
||||||
# endif
|
# endif
|
||||||
# endif
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -481,7 +481,7 @@ struct vimoption
|
|||||||
|| defined(FEAT_INS_EXPAND) || defined(FEAT_SYN_HL) \
|
|| defined(FEAT_INS_EXPAND) || defined(FEAT_SYN_HL) \
|
||||||
|| defined(FEAT_CONCEAL) || defined(FEAT_QUICKFIX) \
|
|| defined(FEAT_CONCEAL) || defined(FEAT_QUICKFIX) \
|
||||||
|| defined(FEAT_TERMINAL)
|
|| defined(FEAT_TERMINAL)
|
||||||
# define HIGHLIGHT_INIT "8:SpecialKey,~:EndOfBuffer,@:NonText,d:Directory,e:ErrorMsg,i:IncSearch,l:Search,m:MoreMsg,M:ModeMsg,n:LineNr,N:CursorLineNr,r:Question,s:StatusLine,S:StatusLineNC,c:VertSplit,t:Title,v:Visual,V:VisualNOS,w:WarningMsg,W:WildMenu,f:Folded,F:FoldColumn,A:DiffAdd,C:DiffChange,D:DiffDelete,T:DiffText,>:SignColumn,-:Conceal,B:SpellBad,P:SpellCap,R:SpellRare,L:SpellLocal,+:Pmenu,=:PmenuSel,x:PmenuSbar,X:PmenuThumb,*:TabLine,#:TabLineSel,_:TabLineFill,!:CursorColumn,.:CursorLine,o:ColorColumn,q:QuickFixLine,$:StatusLineTerm"
|
# define HIGHLIGHT_INIT "8:SpecialKey,~:EndOfBuffer,@:NonText,d:Directory,e:ErrorMsg,i:IncSearch,l:Search,m:MoreMsg,M:ModeMsg,n:LineNr,N:CursorLineNr,r:Question,s:StatusLine,S:StatusLineNC,c:VertSplit,t:Title,v:Visual,V:VisualNOS,w:WarningMsg,W:WildMenu,f:Folded,F:FoldColumn,A:DiffAdd,C:DiffChange,D:DiffDelete,T:DiffText,>:SignColumn,-:Conceal,B:SpellBad,P:SpellCap,R:SpellRare,L:SpellLocal,+:Pmenu,=:PmenuSel,x:PmenuSbar,X:PmenuThumb,*:TabLine,#:TabLineSel,_:TabLineFill,!:CursorColumn,.:CursorLine,o:ColorColumn,q:QuickFixLine,z:StatusLineTerm,Z:StatusLineTermNC"
|
||||||
#else
|
#else
|
||||||
# define HIGHLIGHT_INIT "8:SpecialKey,@:NonText,d:Directory,e:ErrorMsg,i:IncSearch,l:Search,m:MoreMsg,M:ModeMsg,n:LineNr,N:CursorLineNr,r:Question,s:StatusLine,S:StatusLineNC,t:Title,v:Visual,w:WarningMsg,W:WildMenu,>:SignColumn,*:TabLine,#:TabLineSel,_:TabLineFill"
|
# define HIGHLIGHT_INIT "8:SpecialKey,@:NonText,d:Directory,e:ErrorMsg,i:IncSearch,l:Search,m:MoreMsg,M:ModeMsg,n:LineNr,N:CursorLineNr,r:Question,s:StatusLine,S:StatusLineNC,t:Title,v:Visual,w:WarningMsg,W:WildMenu,>:SignColumn,*:TabLine,#:TabLineSel,_:TabLineFill"
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
10
src/screen.c
10
src/screen.c
@@ -7258,6 +7258,9 @@ win_redr_custom(
|
|||||||
curattr = syn_id2attr(-hltab[n].userhl);
|
curattr = syn_id2attr(-hltab[n].userhl);
|
||||||
#ifdef FEAT_WINDOWS
|
#ifdef FEAT_WINDOWS
|
||||||
# ifdef FEAT_TERMINAL
|
# ifdef FEAT_TERMINAL
|
||||||
|
else if (wp != NULL && wp != curwin && bt_terminal(wp->w_buffer)
|
||||||
|
&& wp->w_status_height != 0)
|
||||||
|
curattr = highlight_stltermnc[hltab[n].userhl - 1];
|
||||||
else if (wp != NULL && bt_terminal(wp->w_buffer)
|
else if (wp != NULL && bt_terminal(wp->w_buffer)
|
||||||
&& wp->w_status_height != 0)
|
&& wp->w_status_height != 0)
|
||||||
curattr = highlight_stlterm[hltab[n].userhl - 1];
|
curattr = highlight_stlterm[hltab[n].userhl - 1];
|
||||||
@@ -10724,11 +10727,16 @@ fillchar_status(int *attr, win_T *wp)
|
|||||||
#ifdef FEAT_TERMINAL
|
#ifdef FEAT_TERMINAL
|
||||||
if (bt_terminal(wp->w_buffer))
|
if (bt_terminal(wp->w_buffer))
|
||||||
{
|
{
|
||||||
*attr = HL_ATTR(HLF_ST);
|
|
||||||
if (wp == curwin)
|
if (wp == curwin)
|
||||||
|
{
|
||||||
|
*attr = HL_ATTR(HLF_ST);
|
||||||
fill = fill_stl;
|
fill = fill_stl;
|
||||||
|
}
|
||||||
else
|
else
|
||||||
|
{
|
||||||
|
*attr = HL_ATTR(HLF_STNC);
|
||||||
fill = fill_stlnc;
|
fill = fill_stlnc;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
354
src/syntax.c
354
src/syntax.c
@@ -6873,230 +6873,237 @@ syntime_report(void)
|
|||||||
#else
|
#else
|
||||||
# define CENT(a, b) a
|
# define CENT(a, b) a
|
||||||
#endif
|
#endif
|
||||||
static char *(highlight_init_both[]) =
|
static char *(highlight_init_both[]) = {
|
||||||
{
|
CENT("ErrorMsg term=standout ctermbg=DarkRed ctermfg=White",
|
||||||
CENT("ErrorMsg term=standout ctermbg=DarkRed ctermfg=White",
|
"ErrorMsg term=standout ctermbg=DarkRed ctermfg=White guibg=Red guifg=White"),
|
||||||
"ErrorMsg term=standout ctermbg=DarkRed ctermfg=White guibg=Red guifg=White"),
|
CENT("IncSearch term=reverse cterm=reverse",
|
||||||
CENT("IncSearch term=reverse cterm=reverse",
|
"IncSearch term=reverse cterm=reverse gui=reverse"),
|
||||||
"IncSearch term=reverse cterm=reverse gui=reverse"),
|
CENT("ModeMsg term=bold cterm=bold",
|
||||||
CENT("ModeMsg term=bold cterm=bold",
|
"ModeMsg term=bold cterm=bold gui=bold"),
|
||||||
"ModeMsg term=bold cterm=bold gui=bold"),
|
CENT("NonText term=bold ctermfg=Blue",
|
||||||
CENT("NonText term=bold ctermfg=Blue",
|
"NonText term=bold ctermfg=Blue gui=bold guifg=Blue"),
|
||||||
"NonText term=bold ctermfg=Blue gui=bold guifg=Blue"),
|
CENT("StatusLine term=reverse,bold cterm=reverse,bold",
|
||||||
CENT("StatusLine term=reverse,bold cterm=reverse,bold",
|
"StatusLine term=reverse,bold cterm=reverse,bold gui=reverse,bold"),
|
||||||
"StatusLine term=reverse,bold cterm=reverse,bold gui=reverse,bold"),
|
CENT("StatusLineNC term=reverse cterm=reverse",
|
||||||
CENT("StatusLineNC term=reverse cterm=reverse",
|
"StatusLineNC term=reverse cterm=reverse gui=reverse"),
|
||||||
"StatusLineNC term=reverse cterm=reverse gui=reverse"),
|
"default link EndOfBuffer NonText",
|
||||||
#ifdef FEAT_TERMINAL
|
|
||||||
CENT("StatusLineTerm term=reverse cterm=reverse ctermFg=DarkGreen",
|
|
||||||
"StatusLineTerm term=reverse cterm=reverse ctermFg=DarkGreen gui=reverse guifg=DarkGreen"),
|
|
||||||
#endif
|
|
||||||
"default link EndOfBuffer NonText",
|
|
||||||
#ifdef FEAT_WINDOWS
|
#ifdef FEAT_WINDOWS
|
||||||
CENT("VertSplit term=reverse cterm=reverse",
|
CENT("VertSplit term=reverse cterm=reverse",
|
||||||
"VertSplit term=reverse cterm=reverse gui=reverse"),
|
"VertSplit term=reverse cterm=reverse gui=reverse"),
|
||||||
#endif
|
#endif
|
||||||
#ifdef FEAT_CLIPBOARD
|
#ifdef FEAT_CLIPBOARD
|
||||||
CENT("VisualNOS term=underline,bold cterm=underline,bold",
|
CENT("VisualNOS term=underline,bold cterm=underline,bold",
|
||||||
"VisualNOS term=underline,bold cterm=underline,bold gui=underline,bold"),
|
"VisualNOS term=underline,bold cterm=underline,bold gui=underline,bold"),
|
||||||
#endif
|
#endif
|
||||||
#ifdef FEAT_DIFF
|
#ifdef FEAT_DIFF
|
||||||
CENT("DiffText term=reverse cterm=bold ctermbg=Red",
|
CENT("DiffText term=reverse cterm=bold ctermbg=Red",
|
||||||
"DiffText term=reverse cterm=bold ctermbg=Red gui=bold guibg=Red"),
|
"DiffText term=reverse cterm=bold ctermbg=Red gui=bold guibg=Red"),
|
||||||
#endif
|
#endif
|
||||||
#ifdef FEAT_INS_EXPAND
|
#ifdef FEAT_INS_EXPAND
|
||||||
CENT("PmenuSbar ctermbg=Grey",
|
CENT("PmenuSbar ctermbg=Grey",
|
||||||
"PmenuSbar ctermbg=Grey guibg=Grey"),
|
"PmenuSbar ctermbg=Grey guibg=Grey"),
|
||||||
#endif
|
#endif
|
||||||
#ifdef FEAT_WINDOWS
|
#ifdef FEAT_WINDOWS
|
||||||
CENT("TabLineSel term=bold cterm=bold",
|
CENT("TabLineSel term=bold cterm=bold",
|
||||||
"TabLineSel term=bold cterm=bold gui=bold"),
|
"TabLineSel term=bold cterm=bold gui=bold"),
|
||||||
CENT("TabLineFill term=reverse cterm=reverse",
|
CENT("TabLineFill term=reverse cterm=reverse",
|
||||||
"TabLineFill term=reverse cterm=reverse gui=reverse"),
|
"TabLineFill term=reverse cterm=reverse gui=reverse"),
|
||||||
#endif
|
#endif
|
||||||
#ifdef FEAT_GUI
|
#ifdef FEAT_GUI
|
||||||
"Cursor guibg=fg guifg=bg",
|
"Cursor guibg=fg guifg=bg",
|
||||||
"lCursor guibg=fg guifg=bg", /* should be different, but what? */
|
"lCursor guibg=fg guifg=bg", /* should be different, but what? */
|
||||||
#endif
|
#endif
|
||||||
"default link QuickFixLine Search",
|
"default link QuickFixLine Search",
|
||||||
NULL
|
NULL
|
||||||
};
|
};
|
||||||
|
|
||||||
static char *(highlight_init_light[]) =
|
/* Default colors only used with a light background. */
|
||||||
{
|
static char *(highlight_init_light[]) = {
|
||||||
CENT("Directory term=bold ctermfg=DarkBlue",
|
CENT("Directory term=bold ctermfg=DarkBlue",
|
||||||
"Directory term=bold ctermfg=DarkBlue guifg=Blue"),
|
"Directory term=bold ctermfg=DarkBlue guifg=Blue"),
|
||||||
CENT("LineNr term=underline ctermfg=Brown",
|
CENT("LineNr term=underline ctermfg=Brown",
|
||||||
"LineNr term=underline ctermfg=Brown guifg=Brown"),
|
"LineNr term=underline ctermfg=Brown guifg=Brown"),
|
||||||
CENT("CursorLineNr term=bold ctermfg=Brown",
|
CENT("CursorLineNr term=bold ctermfg=Brown",
|
||||||
"CursorLineNr term=bold ctermfg=Brown gui=bold guifg=Brown"),
|
"CursorLineNr term=bold ctermfg=Brown gui=bold guifg=Brown"),
|
||||||
CENT("MoreMsg term=bold ctermfg=DarkGreen",
|
CENT("MoreMsg term=bold ctermfg=DarkGreen",
|
||||||
"MoreMsg term=bold ctermfg=DarkGreen gui=bold guifg=SeaGreen"),
|
"MoreMsg term=bold ctermfg=DarkGreen gui=bold guifg=SeaGreen"),
|
||||||
CENT("Question term=standout ctermfg=DarkGreen",
|
CENT("Question term=standout ctermfg=DarkGreen",
|
||||||
"Question term=standout ctermfg=DarkGreen gui=bold guifg=SeaGreen"),
|
"Question term=standout ctermfg=DarkGreen gui=bold guifg=SeaGreen"),
|
||||||
CENT("Search term=reverse ctermbg=Yellow ctermfg=NONE",
|
CENT("Search term=reverse ctermbg=Yellow ctermfg=NONE",
|
||||||
"Search term=reverse ctermbg=Yellow ctermfg=NONE guibg=Yellow guifg=NONE"),
|
"Search term=reverse ctermbg=Yellow ctermfg=NONE guibg=Yellow guifg=NONE"),
|
||||||
#ifdef FEAT_SPELL
|
#ifdef FEAT_SPELL
|
||||||
CENT("SpellBad term=reverse ctermbg=LightRed",
|
CENT("SpellBad term=reverse ctermbg=LightRed",
|
||||||
"SpellBad term=reverse ctermbg=LightRed guisp=Red gui=undercurl"),
|
"SpellBad term=reverse ctermbg=LightRed guisp=Red gui=undercurl"),
|
||||||
CENT("SpellCap term=reverse ctermbg=LightBlue",
|
CENT("SpellCap term=reverse ctermbg=LightBlue",
|
||||||
"SpellCap term=reverse ctermbg=LightBlue guisp=Blue gui=undercurl"),
|
"SpellCap term=reverse ctermbg=LightBlue guisp=Blue gui=undercurl"),
|
||||||
CENT("SpellRare term=reverse ctermbg=LightMagenta",
|
CENT("SpellRare term=reverse ctermbg=LightMagenta",
|
||||||
"SpellRare term=reverse ctermbg=LightMagenta guisp=Magenta gui=undercurl"),
|
"SpellRare term=reverse ctermbg=LightMagenta guisp=Magenta gui=undercurl"),
|
||||||
CENT("SpellLocal term=underline ctermbg=Cyan",
|
CENT("SpellLocal term=underline ctermbg=Cyan",
|
||||||
"SpellLocal term=underline ctermbg=Cyan guisp=DarkCyan gui=undercurl"),
|
"SpellLocal term=underline ctermbg=Cyan guisp=DarkCyan gui=undercurl"),
|
||||||
#endif
|
#endif
|
||||||
#ifdef FEAT_INS_EXPAND
|
#ifdef FEAT_INS_EXPAND
|
||||||
CENT("PmenuThumb ctermbg=Black",
|
CENT("PmenuThumb ctermbg=Black",
|
||||||
"PmenuThumb ctermbg=Black guibg=Black"),
|
"PmenuThumb ctermbg=Black guibg=Black"),
|
||||||
CENT("Pmenu ctermbg=LightMagenta ctermfg=Black",
|
CENT("Pmenu ctermbg=LightMagenta ctermfg=Black",
|
||||||
"Pmenu ctermbg=LightMagenta ctermfg=Black guibg=LightMagenta"),
|
"Pmenu ctermbg=LightMagenta ctermfg=Black guibg=LightMagenta"),
|
||||||
CENT("PmenuSel ctermbg=LightGrey ctermfg=Black",
|
CENT("PmenuSel ctermbg=LightGrey ctermfg=Black",
|
||||||
"PmenuSel ctermbg=LightGrey ctermfg=Black guibg=Grey"),
|
"PmenuSel ctermbg=LightGrey ctermfg=Black guibg=Grey"),
|
||||||
#endif
|
#endif
|
||||||
CENT("SpecialKey term=bold ctermfg=DarkBlue",
|
CENT("SpecialKey term=bold ctermfg=DarkBlue",
|
||||||
"SpecialKey term=bold ctermfg=DarkBlue guifg=Blue"),
|
"SpecialKey term=bold ctermfg=DarkBlue guifg=Blue"),
|
||||||
CENT("Title term=bold ctermfg=DarkMagenta",
|
CENT("Title term=bold ctermfg=DarkMagenta",
|
||||||
"Title term=bold ctermfg=DarkMagenta gui=bold guifg=Magenta"),
|
"Title term=bold ctermfg=DarkMagenta gui=bold guifg=Magenta"),
|
||||||
CENT("WarningMsg term=standout ctermfg=DarkRed",
|
CENT("WarningMsg term=standout ctermfg=DarkRed",
|
||||||
"WarningMsg term=standout ctermfg=DarkRed guifg=Red"),
|
"WarningMsg term=standout ctermfg=DarkRed guifg=Red"),
|
||||||
#ifdef FEAT_WILDMENU
|
#ifdef FEAT_WILDMENU
|
||||||
CENT("WildMenu term=standout ctermbg=Yellow ctermfg=Black",
|
CENT("WildMenu term=standout ctermbg=Yellow ctermfg=Black",
|
||||||
"WildMenu term=standout ctermbg=Yellow ctermfg=Black guibg=Yellow guifg=Black"),
|
"WildMenu term=standout ctermbg=Yellow ctermfg=Black guibg=Yellow guifg=Black"),
|
||||||
#endif
|
#endif
|
||||||
#ifdef FEAT_FOLDING
|
#ifdef FEAT_FOLDING
|
||||||
CENT("Folded term=standout ctermbg=Grey ctermfg=DarkBlue",
|
CENT("Folded term=standout ctermbg=Grey ctermfg=DarkBlue",
|
||||||
"Folded term=standout ctermbg=Grey ctermfg=DarkBlue guibg=LightGrey guifg=DarkBlue"),
|
"Folded term=standout ctermbg=Grey ctermfg=DarkBlue guibg=LightGrey guifg=DarkBlue"),
|
||||||
CENT("FoldColumn term=standout ctermbg=Grey ctermfg=DarkBlue",
|
CENT("FoldColumn term=standout ctermbg=Grey ctermfg=DarkBlue",
|
||||||
"FoldColumn term=standout ctermbg=Grey ctermfg=DarkBlue guibg=Grey guifg=DarkBlue"),
|
"FoldColumn term=standout ctermbg=Grey ctermfg=DarkBlue guibg=Grey guifg=DarkBlue"),
|
||||||
#endif
|
#endif
|
||||||
#ifdef FEAT_SIGNS
|
#ifdef FEAT_SIGNS
|
||||||
CENT("SignColumn term=standout ctermbg=Grey ctermfg=DarkBlue",
|
CENT("SignColumn term=standout ctermbg=Grey ctermfg=DarkBlue",
|
||||||
"SignColumn term=standout ctermbg=Grey ctermfg=DarkBlue guibg=Grey guifg=DarkBlue"),
|
"SignColumn term=standout ctermbg=Grey ctermfg=DarkBlue guibg=Grey guifg=DarkBlue"),
|
||||||
#endif
|
#endif
|
||||||
CENT("Visual term=reverse",
|
CENT("Visual term=reverse",
|
||||||
"Visual term=reverse guibg=LightGrey"),
|
"Visual term=reverse guibg=LightGrey"),
|
||||||
#ifdef FEAT_DIFF
|
#ifdef FEAT_DIFF
|
||||||
CENT("DiffAdd term=bold ctermbg=LightBlue",
|
CENT("DiffAdd term=bold ctermbg=LightBlue",
|
||||||
"DiffAdd term=bold ctermbg=LightBlue guibg=LightBlue"),
|
"DiffAdd term=bold ctermbg=LightBlue guibg=LightBlue"),
|
||||||
CENT("DiffChange term=bold ctermbg=LightMagenta",
|
CENT("DiffChange term=bold ctermbg=LightMagenta",
|
||||||
"DiffChange term=bold ctermbg=LightMagenta guibg=LightMagenta"),
|
"DiffChange term=bold ctermbg=LightMagenta guibg=LightMagenta"),
|
||||||
CENT("DiffDelete term=bold ctermfg=Blue ctermbg=LightCyan",
|
CENT("DiffDelete term=bold ctermfg=Blue ctermbg=LightCyan",
|
||||||
"DiffDelete term=bold ctermfg=Blue ctermbg=LightCyan gui=bold guifg=Blue guibg=LightCyan"),
|
"DiffDelete term=bold ctermfg=Blue ctermbg=LightCyan gui=bold guifg=Blue guibg=LightCyan"),
|
||||||
#endif
|
#endif
|
||||||
#ifdef FEAT_WINDOWS
|
#ifdef FEAT_WINDOWS
|
||||||
CENT("TabLine term=underline cterm=underline ctermfg=black ctermbg=LightGrey",
|
CENT("TabLine term=underline cterm=underline ctermfg=black ctermbg=LightGrey",
|
||||||
"TabLine term=underline cterm=underline ctermfg=black ctermbg=LightGrey gui=underline guibg=LightGrey"),
|
"TabLine term=underline cterm=underline ctermfg=black ctermbg=LightGrey gui=underline guibg=LightGrey"),
|
||||||
#endif
|
#endif
|
||||||
#ifdef FEAT_SYN_HL
|
#ifdef FEAT_SYN_HL
|
||||||
CENT("CursorColumn term=reverse ctermbg=LightGrey",
|
CENT("CursorColumn term=reverse ctermbg=LightGrey",
|
||||||
"CursorColumn term=reverse ctermbg=LightGrey guibg=Grey90"),
|
"CursorColumn term=reverse ctermbg=LightGrey guibg=Grey90"),
|
||||||
CENT("CursorLine term=underline cterm=underline",
|
CENT("CursorLine term=underline cterm=underline",
|
||||||
"CursorLine term=underline cterm=underline guibg=Grey90"),
|
"CursorLine term=underline cterm=underline guibg=Grey90"),
|
||||||
CENT("ColorColumn term=reverse ctermbg=LightRed",
|
CENT("ColorColumn term=reverse ctermbg=LightRed",
|
||||||
"ColorColumn term=reverse ctermbg=LightRed guibg=LightRed"),
|
"ColorColumn term=reverse ctermbg=LightRed guibg=LightRed"),
|
||||||
#endif
|
#endif
|
||||||
#ifdef FEAT_CONCEAL
|
#ifdef FEAT_CONCEAL
|
||||||
CENT("Conceal ctermbg=DarkGrey ctermfg=LightGrey",
|
CENT("Conceal ctermbg=DarkGrey ctermfg=LightGrey",
|
||||||
"Conceal ctermbg=DarkGrey ctermfg=LightGrey guibg=DarkGrey guifg=LightGrey"),
|
"Conceal ctermbg=DarkGrey ctermfg=LightGrey guibg=DarkGrey guifg=LightGrey"),
|
||||||
#endif
|
#endif
|
||||||
#ifdef FEAT_AUTOCMD
|
#ifdef FEAT_AUTOCMD
|
||||||
CENT("MatchParen term=reverse ctermbg=Cyan",
|
CENT("MatchParen term=reverse ctermbg=Cyan",
|
||||||
"MatchParen term=reverse ctermbg=Cyan guibg=Cyan"),
|
"MatchParen term=reverse ctermbg=Cyan guibg=Cyan"),
|
||||||
#endif
|
#endif
|
||||||
#ifdef FEAT_GUI
|
#ifdef FEAT_GUI
|
||||||
"Normal gui=NONE",
|
"Normal gui=NONE",
|
||||||
#endif
|
#endif
|
||||||
NULL
|
#ifdef FEAT_TERMINAL
|
||||||
};
|
CENT("StatusLineTerm term=reverse,bold cterm=bold ctermfg=White ctermbg=DarkGreen",
|
||||||
|
"StatusLineTerm term=reverse,bold cterm=bold ctermfg=White ctermbg=DarkGreen gui=bold guifg=bg guibg=DarkGreen"),
|
||||||
|
CENT("StatusLineTermNC term=reverse ctermfg=White ctermbg=DarkGreen",
|
||||||
|
"StatusLineTermNC term=reverse ctermfg=White ctermbg=DarkGreen guifg=bg guibg=DarkGreen"),
|
||||||
|
#endif
|
||||||
|
NULL
|
||||||
|
};
|
||||||
|
|
||||||
static char *(highlight_init_dark[]) =
|
/* Default colors only used with a dark background. */
|
||||||
{
|
static char *(highlight_init_dark[]) = {
|
||||||
CENT("Directory term=bold ctermfg=LightCyan",
|
CENT("Directory term=bold ctermfg=LightCyan",
|
||||||
"Directory term=bold ctermfg=LightCyan guifg=Cyan"),
|
"Directory term=bold ctermfg=LightCyan guifg=Cyan"),
|
||||||
CENT("LineNr term=underline ctermfg=Yellow",
|
CENT("LineNr term=underline ctermfg=Yellow",
|
||||||
"LineNr term=underline ctermfg=Yellow guifg=Yellow"),
|
"LineNr term=underline ctermfg=Yellow guifg=Yellow"),
|
||||||
CENT("CursorLineNr term=bold ctermfg=Yellow",
|
CENT("CursorLineNr term=bold ctermfg=Yellow",
|
||||||
"CursorLineNr term=bold ctermfg=Yellow gui=bold guifg=Yellow"),
|
"CursorLineNr term=bold ctermfg=Yellow gui=bold guifg=Yellow"),
|
||||||
CENT("MoreMsg term=bold ctermfg=LightGreen",
|
CENT("MoreMsg term=bold ctermfg=LightGreen",
|
||||||
"MoreMsg term=bold ctermfg=LightGreen gui=bold guifg=SeaGreen"),
|
"MoreMsg term=bold ctermfg=LightGreen gui=bold guifg=SeaGreen"),
|
||||||
CENT("Question term=standout ctermfg=LightGreen",
|
CENT("Question term=standout ctermfg=LightGreen",
|
||||||
"Question term=standout ctermfg=LightGreen gui=bold guifg=Green"),
|
"Question term=standout ctermfg=LightGreen gui=bold guifg=Green"),
|
||||||
CENT("Search term=reverse ctermbg=Yellow ctermfg=Black",
|
CENT("Search term=reverse ctermbg=Yellow ctermfg=Black",
|
||||||
"Search term=reverse ctermbg=Yellow ctermfg=Black guibg=Yellow guifg=Black"),
|
"Search term=reverse ctermbg=Yellow ctermfg=Black guibg=Yellow guifg=Black"),
|
||||||
CENT("SpecialKey term=bold ctermfg=LightBlue",
|
CENT("SpecialKey term=bold ctermfg=LightBlue",
|
||||||
"SpecialKey term=bold ctermfg=LightBlue guifg=Cyan"),
|
"SpecialKey term=bold ctermfg=LightBlue guifg=Cyan"),
|
||||||
#ifdef FEAT_SPELL
|
#ifdef FEAT_SPELL
|
||||||
CENT("SpellBad term=reverse ctermbg=Red",
|
CENT("SpellBad term=reverse ctermbg=Red",
|
||||||
"SpellBad term=reverse ctermbg=Red guisp=Red gui=undercurl"),
|
"SpellBad term=reverse ctermbg=Red guisp=Red gui=undercurl"),
|
||||||
CENT("SpellCap term=reverse ctermbg=Blue",
|
CENT("SpellCap term=reverse ctermbg=Blue",
|
||||||
"SpellCap term=reverse ctermbg=Blue guisp=Blue gui=undercurl"),
|
"SpellCap term=reverse ctermbg=Blue guisp=Blue gui=undercurl"),
|
||||||
CENT("SpellRare term=reverse ctermbg=Magenta",
|
CENT("SpellRare term=reverse ctermbg=Magenta",
|
||||||
"SpellRare term=reverse ctermbg=Magenta guisp=Magenta gui=undercurl"),
|
"SpellRare term=reverse ctermbg=Magenta guisp=Magenta gui=undercurl"),
|
||||||
CENT("SpellLocal term=underline ctermbg=Cyan",
|
CENT("SpellLocal term=underline ctermbg=Cyan",
|
||||||
"SpellLocal term=underline ctermbg=Cyan guisp=Cyan gui=undercurl"),
|
"SpellLocal term=underline ctermbg=Cyan guisp=Cyan gui=undercurl"),
|
||||||
#endif
|
#endif
|
||||||
#ifdef FEAT_INS_EXPAND
|
#ifdef FEAT_INS_EXPAND
|
||||||
CENT("PmenuThumb ctermbg=White",
|
CENT("PmenuThumb ctermbg=White",
|
||||||
"PmenuThumb ctermbg=White guibg=White"),
|
"PmenuThumb ctermbg=White guibg=White"),
|
||||||
CENT("Pmenu ctermbg=Magenta ctermfg=Black",
|
CENT("Pmenu ctermbg=Magenta ctermfg=Black",
|
||||||
"Pmenu ctermbg=Magenta ctermfg=Black guibg=Magenta"),
|
"Pmenu ctermbg=Magenta ctermfg=Black guibg=Magenta"),
|
||||||
CENT("PmenuSel ctermbg=Black ctermfg=DarkGrey",
|
CENT("PmenuSel ctermbg=Black ctermfg=DarkGrey",
|
||||||
"PmenuSel ctermbg=Black ctermfg=DarkGrey guibg=DarkGrey"),
|
"PmenuSel ctermbg=Black ctermfg=DarkGrey guibg=DarkGrey"),
|
||||||
#endif
|
#endif
|
||||||
CENT("Title term=bold ctermfg=LightMagenta",
|
CENT("Title term=bold ctermfg=LightMagenta",
|
||||||
"Title term=bold ctermfg=LightMagenta gui=bold guifg=Magenta"),
|
"Title term=bold ctermfg=LightMagenta gui=bold guifg=Magenta"),
|
||||||
CENT("WarningMsg term=standout ctermfg=LightRed",
|
CENT("WarningMsg term=standout ctermfg=LightRed",
|
||||||
"WarningMsg term=standout ctermfg=LightRed guifg=Red"),
|
"WarningMsg term=standout ctermfg=LightRed guifg=Red"),
|
||||||
#ifdef FEAT_WILDMENU
|
#ifdef FEAT_WILDMENU
|
||||||
CENT("WildMenu term=standout ctermbg=Yellow ctermfg=Black",
|
CENT("WildMenu term=standout ctermbg=Yellow ctermfg=Black",
|
||||||
"WildMenu term=standout ctermbg=Yellow ctermfg=Black guibg=Yellow guifg=Black"),
|
"WildMenu term=standout ctermbg=Yellow ctermfg=Black guibg=Yellow guifg=Black"),
|
||||||
#endif
|
#endif
|
||||||
#ifdef FEAT_FOLDING
|
#ifdef FEAT_FOLDING
|
||||||
CENT("Folded term=standout ctermbg=DarkGrey ctermfg=Cyan",
|
CENT("Folded term=standout ctermbg=DarkGrey ctermfg=Cyan",
|
||||||
"Folded term=standout ctermbg=DarkGrey ctermfg=Cyan guibg=DarkGrey guifg=Cyan"),
|
"Folded term=standout ctermbg=DarkGrey ctermfg=Cyan guibg=DarkGrey guifg=Cyan"),
|
||||||
CENT("FoldColumn term=standout ctermbg=DarkGrey ctermfg=Cyan",
|
CENT("FoldColumn term=standout ctermbg=DarkGrey ctermfg=Cyan",
|
||||||
"FoldColumn term=standout ctermbg=DarkGrey ctermfg=Cyan guibg=Grey guifg=Cyan"),
|
"FoldColumn term=standout ctermbg=DarkGrey ctermfg=Cyan guibg=Grey guifg=Cyan"),
|
||||||
#endif
|
#endif
|
||||||
#ifdef FEAT_SIGNS
|
#ifdef FEAT_SIGNS
|
||||||
CENT("SignColumn term=standout ctermbg=DarkGrey ctermfg=Cyan",
|
CENT("SignColumn term=standout ctermbg=DarkGrey ctermfg=Cyan",
|
||||||
"SignColumn term=standout ctermbg=DarkGrey ctermfg=Cyan guibg=Grey guifg=Cyan"),
|
"SignColumn term=standout ctermbg=DarkGrey ctermfg=Cyan guibg=Grey guifg=Cyan"),
|
||||||
#endif
|
#endif
|
||||||
CENT("Visual term=reverse",
|
CENT("Visual term=reverse",
|
||||||
"Visual term=reverse guibg=DarkGrey"),
|
"Visual term=reverse guibg=DarkGrey"),
|
||||||
#ifdef FEAT_DIFF
|
#ifdef FEAT_DIFF
|
||||||
CENT("DiffAdd term=bold ctermbg=DarkBlue",
|
CENT("DiffAdd term=bold ctermbg=DarkBlue",
|
||||||
"DiffAdd term=bold ctermbg=DarkBlue guibg=DarkBlue"),
|
"DiffAdd term=bold ctermbg=DarkBlue guibg=DarkBlue"),
|
||||||
CENT("DiffChange term=bold ctermbg=DarkMagenta",
|
CENT("DiffChange term=bold ctermbg=DarkMagenta",
|
||||||
"DiffChange term=bold ctermbg=DarkMagenta guibg=DarkMagenta"),
|
"DiffChange term=bold ctermbg=DarkMagenta guibg=DarkMagenta"),
|
||||||
CENT("DiffDelete term=bold ctermfg=Blue ctermbg=DarkCyan",
|
CENT("DiffDelete term=bold ctermfg=Blue ctermbg=DarkCyan",
|
||||||
"DiffDelete term=bold ctermfg=Blue ctermbg=DarkCyan gui=bold guifg=Blue guibg=DarkCyan"),
|
"DiffDelete term=bold ctermfg=Blue ctermbg=DarkCyan gui=bold guifg=Blue guibg=DarkCyan"),
|
||||||
#endif
|
#endif
|
||||||
#ifdef FEAT_WINDOWS
|
#ifdef FEAT_WINDOWS
|
||||||
CENT("TabLine term=underline cterm=underline ctermfg=white ctermbg=DarkGrey",
|
CENT("TabLine term=underline cterm=underline ctermfg=white ctermbg=DarkGrey",
|
||||||
"TabLine term=underline cterm=underline ctermfg=white ctermbg=DarkGrey gui=underline guibg=DarkGrey"),
|
"TabLine term=underline cterm=underline ctermfg=white ctermbg=DarkGrey gui=underline guibg=DarkGrey"),
|
||||||
#endif
|
#endif
|
||||||
#ifdef FEAT_SYN_HL
|
#ifdef FEAT_SYN_HL
|
||||||
CENT("CursorColumn term=reverse ctermbg=DarkGrey",
|
CENT("CursorColumn term=reverse ctermbg=DarkGrey",
|
||||||
"CursorColumn term=reverse ctermbg=DarkGrey guibg=Grey40"),
|
"CursorColumn term=reverse ctermbg=DarkGrey guibg=Grey40"),
|
||||||
CENT("CursorLine term=underline cterm=underline",
|
CENT("CursorLine term=underline cterm=underline",
|
||||||
"CursorLine term=underline cterm=underline guibg=Grey40"),
|
"CursorLine term=underline cterm=underline guibg=Grey40"),
|
||||||
CENT("ColorColumn term=reverse ctermbg=DarkRed",
|
CENT("ColorColumn term=reverse ctermbg=DarkRed",
|
||||||
"ColorColumn term=reverse ctermbg=DarkRed guibg=DarkRed"),
|
"ColorColumn term=reverse ctermbg=DarkRed guibg=DarkRed"),
|
||||||
#endif
|
#endif
|
||||||
#ifdef FEAT_AUTOCMD
|
#ifdef FEAT_AUTOCMD
|
||||||
CENT("MatchParen term=reverse ctermbg=DarkCyan",
|
CENT("MatchParen term=reverse ctermbg=DarkCyan",
|
||||||
"MatchParen term=reverse ctermbg=DarkCyan guibg=DarkCyan"),
|
"MatchParen term=reverse ctermbg=DarkCyan guibg=DarkCyan"),
|
||||||
#endif
|
#endif
|
||||||
#ifdef FEAT_CONCEAL
|
#ifdef FEAT_CONCEAL
|
||||||
CENT("Conceal ctermbg=DarkGrey ctermfg=LightGrey",
|
CENT("Conceal ctermbg=DarkGrey ctermfg=LightGrey",
|
||||||
"Conceal ctermbg=DarkGrey ctermfg=LightGrey guibg=DarkGrey guifg=LightGrey"),
|
"Conceal ctermbg=DarkGrey ctermfg=LightGrey guibg=DarkGrey guifg=LightGrey"),
|
||||||
#endif
|
#endif
|
||||||
#ifdef FEAT_GUI
|
#ifdef FEAT_GUI
|
||||||
"Normal gui=NONE",
|
"Normal gui=NONE",
|
||||||
#endif
|
#endif
|
||||||
NULL
|
#ifdef FEAT_TERMINAL
|
||||||
};
|
CENT("StatusLineTerm term=reverse,bold cterm=bold ctermfg=Black ctermbg=LightGreen",
|
||||||
|
"StatusLineTerm term=reverse,bold cterm=bold ctermfg=Black ctermbg=LightGreen gui=bold guifg=bg guibg=LightGreen"),
|
||||||
|
CENT("StatusLineTermNC term=reverse ctermfg=Black ctermbg=LightGreen",
|
||||||
|
"StatusLineTermNC term=reverse ctermfg=Black ctermbg=LightGreen guifg=bg guibg=LightGreen"),
|
||||||
|
#endif
|
||||||
|
NULL
|
||||||
|
};
|
||||||
|
|
||||||
void
|
void
|
||||||
init_highlight(
|
init_highlight(
|
||||||
@@ -9788,7 +9795,7 @@ gui_do_one_color(
|
|||||||
|
|
||||||
#if defined(USER_HIGHLIGHT) && defined(FEAT_STL_OPT)
|
#if defined(USER_HIGHLIGHT) && defined(FEAT_STL_OPT)
|
||||||
/*
|
/*
|
||||||
* Apply difference between User[1-9] and HLF_S to HLF_SNC or HLF_ST.
|
* Apply difference between User[1-9] and HLF_S to HLF_SNC, HLF_ST or HLF_STNC.
|
||||||
*/
|
*/
|
||||||
static void
|
static void
|
||||||
combine_stl_hlt(
|
combine_stl_hlt(
|
||||||
@@ -9877,6 +9884,7 @@ highlight_changed(void)
|
|||||||
int id_S = -1;
|
int id_S = -1;
|
||||||
# ifdef FEAT_TERMINAL
|
# ifdef FEAT_TERMINAL
|
||||||
int id_ST = -1;
|
int id_ST = -1;
|
||||||
|
int id_STNC = -1;
|
||||||
# endif
|
# endif
|
||||||
int hlcnt;
|
int hlcnt;
|
||||||
# endif
|
# endif
|
||||||
@@ -9960,6 +9968,8 @@ highlight_changed(void)
|
|||||||
# ifdef FEAT_TERMINAL
|
# ifdef FEAT_TERMINAL
|
||||||
else if (hlf == (int)HLF_ST)
|
else if (hlf == (int)HLF_ST)
|
||||||
id_ST = syn_get_final_id(id);
|
id_ST = syn_get_final_id(id);
|
||||||
|
else if (hlf == (int)HLF_STNC)
|
||||||
|
id_STNC = syn_get_final_id(id);
|
||||||
# endif
|
# endif
|
||||||
else if (hlf == (int)HLF_S)
|
else if (hlf == (int)HLF_S)
|
||||||
id_S = syn_get_final_id(id);
|
id_S = syn_get_final_id(id);
|
||||||
@@ -9977,22 +9987,23 @@ highlight_changed(void)
|
|||||||
#ifdef USER_HIGHLIGHT
|
#ifdef USER_HIGHLIGHT
|
||||||
/* Setup the user highlights
|
/* Setup the user highlights
|
||||||
*
|
*
|
||||||
* Temporarily utilize 19 more hl entries:
|
* Temporarily utilize 28 more hl entries:
|
||||||
* 9 for User1-User9 combined with StatusLineNC
|
* 9 for User1-User9 combined with StatusLineNC
|
||||||
* 9 for User1-User9 combined with StatusLineTerm
|
* 9 for User1-User9 combined with StatusLineTerm
|
||||||
|
* 9 for User1-User9 combined with StatusLineTermNC
|
||||||
* 1 for StatusLine default
|
* 1 for StatusLine default
|
||||||
* Have to be in there simultaneously in case of table overflows in
|
* Have to be in there simultaneously in case of table overflows in
|
||||||
* get_attr_entry()
|
* get_attr_entry()
|
||||||
*/
|
*/
|
||||||
# ifdef FEAT_STL_OPT
|
# ifdef FEAT_STL_OPT
|
||||||
if (ga_grow(&highlight_ga, 19) == FAIL)
|
if (ga_grow(&highlight_ga, 28) == FAIL)
|
||||||
return FAIL;
|
return FAIL;
|
||||||
hlcnt = highlight_ga.ga_len;
|
hlcnt = highlight_ga.ga_len;
|
||||||
if (id_S == 0)
|
if (id_S == 0)
|
||||||
{
|
{
|
||||||
/* Make sure id_S is always valid to simplify code below. Use the last
|
/* Make sure id_S is always valid to simplify code below. Use the last
|
||||||
* entry. */
|
* entry. */
|
||||||
vim_memset(&HL_TABLE()[hlcnt + 18], 0, sizeof(struct hl_group));
|
vim_memset(&HL_TABLE()[hlcnt + 27], 0, sizeof(struct hl_group));
|
||||||
HL_TABLE()[hlcnt + 18].sg_term = highlight_attr[HLF_S];
|
HL_TABLE()[hlcnt + 18].sg_term = highlight_attr[HLF_S];
|
||||||
id_S = hlcnt + 19;
|
id_S = hlcnt + 19;
|
||||||
}
|
}
|
||||||
@@ -10008,6 +10019,7 @@ highlight_changed(void)
|
|||||||
highlight_stlnc[i] = 0;
|
highlight_stlnc[i] = 0;
|
||||||
# ifdef FEAT_TERMINAL
|
# ifdef FEAT_TERMINAL
|
||||||
highlight_stlterm[i] = 0;
|
highlight_stlterm[i] = 0;
|
||||||
|
highlight_stltermnc[i] = 0;
|
||||||
# endif
|
# endif
|
||||||
# endif
|
# endif
|
||||||
}
|
}
|
||||||
@@ -10020,6 +10032,8 @@ highlight_changed(void)
|
|||||||
# ifdef FEAT_TERMINAL
|
# ifdef FEAT_TERMINAL
|
||||||
combine_stl_hlt(id, id_S, id_ST, hlcnt + 9, i,
|
combine_stl_hlt(id, id_S, id_ST, hlcnt + 9, i,
|
||||||
HLF_ST, highlight_stlterm);
|
HLF_ST, highlight_stlterm);
|
||||||
|
combine_stl_hlt(id, id_S, id_STNC, hlcnt + 18, i,
|
||||||
|
HLF_STNC, highlight_stltermnc);
|
||||||
# endif
|
# endif
|
||||||
# endif
|
# endif
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -769,6 +769,8 @@ static char *(features[]) =
|
|||||||
|
|
||||||
static int included_patches[] =
|
static int included_patches[] =
|
||||||
{ /* Add new patch number below this line */
|
{ /* Add new patch number below this line */
|
||||||
|
/**/
|
||||||
|
941,
|
||||||
/**/
|
/**/
|
||||||
940,
|
940,
|
||||||
/**/
|
/**/
|
||||||
|
|||||||
@@ -1437,6 +1437,7 @@ typedef enum
|
|||||||
, HLF_MC /* 'colorcolumn' */
|
, HLF_MC /* 'colorcolumn' */
|
||||||
, HLF_QFL /* quickfix window line currently selected */
|
, HLF_QFL /* quickfix window line currently selected */
|
||||||
, HLF_ST /* status lines of terminal windows */
|
, HLF_ST /* status lines of terminal windows */
|
||||||
|
, HLF_STNC /* status lines of not-current terminal windows */
|
||||||
, HLF_COUNT /* MUST be the last one */
|
, HLF_COUNT /* MUST be the last one */
|
||||||
} hlf_T;
|
} hlf_T;
|
||||||
|
|
||||||
@@ -1446,7 +1447,8 @@ typedef enum
|
|||||||
'n', 'N', 'r', 's', 'S', 'c', 't', 'v', 'V', 'w', 'W', \
|
'n', 'N', 'r', 's', 'S', 'c', 't', 'v', 'V', 'w', 'W', \
|
||||||
'f', 'F', 'A', 'C', 'D', 'T', '-', '>', \
|
'f', 'F', 'A', 'C', 'D', 'T', '-', '>', \
|
||||||
'B', 'P', 'R', 'L', \
|
'B', 'P', 'R', 'L', \
|
||||||
'+', '=', 'x', 'X', '*', '#', '_', '!', '.', 'o', 'q', '$'}
|
'+', '=', 'x', 'X', '*', '#', '_', '!', '.', 'o', 'q', \
|
||||||
|
'z', 'Z'}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Boolean constants
|
* Boolean constants
|
||||||
|
|||||||
Reference in New Issue
Block a user