aboutsummaryrefslogtreecommitdiff
path: root/colors/base16-xcode-dusk.vim
diff options
context:
space:
mode:
Diffstat (limited to 'colors/base16-xcode-dusk.vim')
-rw-r--r--colors/base16-xcode-dusk.vim41
1 files changed, 37 insertions, 4 deletions
diff --git a/colors/base16-xcode-dusk.vim b/colors/base16-xcode-dusk.vim
index 7409870..608fbaa 100644
--- a/colors/base16-xcode-dusk.vim
+++ b/colors/base16-xcode-dusk.vim
@@ -153,11 +153,22 @@ function! g:Base16hi(group, guifg, guibg, ctermfg, ctermbg, ...)
let l:attr = get(a:, 1, "")
let l:guisp = get(a:, 2, "")
+ " See :help highlight-guifg
+ let l:gui_special_names = ["NONE", "bg", "background", "fg", "foreground"]
+
if a:guifg != ""
- exec "hi " . a:group . " guifg=#" . a:guifg
+ if index(l:gui_special_names, a:guifg) >= 0
+ exec "hi " . a:group . " guifg=" . a:guifg
+ else
+ exec "hi " . a:group . " guifg=#" . a:guifg
+ endif
endif
if a:guibg != ""
- exec "hi " . a:group . " guibg=#" . a:guibg
+ if index(l:gui_special_names, a:guibg) >= 0
+ exec "hi " . a:group . " guibg=" . a:guibg
+ else
+ exec "hi " . a:group . " guibg=#" . a:guibg
+ endif
endif
if a:ctermfg != ""
exec "hi " . a:group . " ctermfg=" . a:ctermfg
@@ -169,7 +180,11 @@ function! g:Base16hi(group, guifg, guibg, ctermfg, ctermbg, ...)
exec "hi " . a:group . " gui=" . l:attr . " cterm=" . l:attr
endif
if l:guisp != ""
- exec "hi " . a:group . " guisp=#" . l:guisp
+ if index(l:gui_special_names, l:guisp) >= 0
+ exec "hi " . a:group . " guisp=" . l:guisp
+ else
+ exec "hi " . a:group . " guisp=#" . l:guisp
+ endif
endif
endfunction
@@ -216,7 +231,7 @@ call <sid>hi("VertSplit", s:gui02, s:gui02, s:cterm02, s:cterm02, "none", ""
call <sid>hi("ColorColumn", "", s:gui01, "", s:cterm01, "none", "")
call <sid>hi("CursorColumn", "", s:gui01, "", s:cterm01, "none", "")
call <sid>hi("CursorLine", "", s:gui01, "", s:cterm01, "none", "")
-call <sid>hi("CursorLineNr", s:gui04, s:gui01, s:cterm04, s:cterm01, "", "")
+call <sid>hi("CursorLineNr", s:gui04, s:gui01, s:cterm04, s:cterm01, "bold", "")
call <sid>hi("QuickFixLine", "", s:gui01, "", s:cterm01, "none", "")
call <sid>hi("PMenu", s:gui05, s:gui01, s:cterm05, s:cterm01, "none", "")
call <sid>hi("PMenuSel", s:gui01, s:gui05, s:cterm01, s:cterm05, "", "")
@@ -402,6 +417,24 @@ call <sid>hi("StartifySelect", s:gui0C, "", s:cterm0C, "", "", "")
call <sid>hi("StartifySlash", s:gui03, "", s:cterm03, "", "", "")
call <sid>hi("StartifySpecial", s:gui03, "", s:cterm03, "", "", "")
+" Neovim Treesitter highlighting
+if has("nvim")
+ call <sid>hi("TSFunction", s:gui0D, "", s:cterm0D, "", "", "")
+ call <sid>hi("TSKeywordFunction", s:gui0E, "", s:cterm0E, "", "", "")
+ call <sid>hi("TSMethod", s:gui0D, "", s:cterm0D, "", "", "")
+ call <sid>hi("TSProperty", s:gui0A, "", s:cterm0A, "", "", "")
+ call <sid>hi("TSPunctBracket", s:gui0C, "", s:cterm0C, "", "", "")
+ call <sid>hi("TSType", s:gui08, "", s:cterm08, "", "none", "")
+endif
+
+" LSP highlighting
+if has("nvim")
+ call <sid>hi("LspDiagnosticsDefaultError", s:gui08, "", s:cterm08, "", "", "")
+ call <sid>hi("LspDiagnosticsDefaultWarning", s:gui09, "", s:cterm09, "", "", "")
+ call <sid>hi("LspDiagnosticsDefaultInformation", s:gui05, "", s:cterm05, "", "", "")
+ call <sid>hi("LspDiagnosticsDefaultHint", s:gui03, "", s:cterm03, "", "", "")
+endif
+
" Java highlighting
call <sid>hi("javaOperator", s:gui0D, "", s:cterm0D, "", "", "")