mirror of
https://github.com/itme-brain/vim.git
synced 2026-05-08 07:30:13 -04:00
more compat
This commit is contained in:
parent
8721c364b1
commit
978f17aa64
2 changed files with 114 additions and 89 deletions
|
|
@ -1,6 +1,5 @@
|
||||||
" anticuus.vim
|
" anticuus.vim
|
||||||
" Pitch-black minimalist theme — port of nvim anticuus + custom syntax extensions.
|
" Pitch-black minimalist theme with 256-color terminal fallbacks.
|
||||||
" Requires `set termguicolors`.
|
|
||||||
|
|
||||||
hi clear
|
hi clear
|
||||||
if exists('syntax_on')
|
if exists('syntax_on')
|
||||||
|
|
@ -10,133 +9,156 @@ endif
|
||||||
let g:colors_name = 'anticuus'
|
let g:colors_name = 'anticuus'
|
||||||
set background=dark
|
set background=dark
|
||||||
|
|
||||||
|
function! s:hi(group, guifg, guibg, ctermfg, ctermbg, gui, cterm)
|
||||||
|
let l:cmd = 'highlight ' . a:group
|
||||||
|
if a:guifg !=# ''
|
||||||
|
let l:cmd .= ' guifg=' . a:guifg
|
||||||
|
endif
|
||||||
|
if a:guibg !=# ''
|
||||||
|
let l:cmd .= ' guibg=' . a:guibg
|
||||||
|
endif
|
||||||
|
if a:ctermfg !=# ''
|
||||||
|
let l:cmd .= ' ctermfg=' . a:ctermfg
|
||||||
|
endif
|
||||||
|
if a:ctermbg !=# ''
|
||||||
|
let l:cmd .= ' ctermbg=' . a:ctermbg
|
||||||
|
endif
|
||||||
|
if a:gui !=# ''
|
||||||
|
let l:cmd .= ' gui=' . a:gui
|
||||||
|
endif
|
||||||
|
if a:cterm !=# ''
|
||||||
|
let l:cmd .= ' cterm=' . a:cterm
|
||||||
|
endif
|
||||||
|
execute l:cmd
|
||||||
|
endfunction
|
||||||
|
|
||||||
" === Base ===
|
" === Base ===
|
||||||
highlight Normal guifg=#dadada guibg=#000000
|
call s:hi('Normal', '#dadada', '#000000', '253', '16', '', '')
|
||||||
highlight NormalNC guifg=#dadada guibg=#000000
|
call s:hi('NormalNC', '#dadada', '#000000', '253', '16', '', '')
|
||||||
highlight NonText guifg=#3a3a3a guibg=NONE
|
call s:hi('NonText', '#3a3a3a', 'NONE', '237', 'NONE', '', '')
|
||||||
highlight EndOfBuffer guifg=#000000 guibg=NONE
|
call s:hi('EndOfBuffer', '#000000', 'NONE', '16', 'NONE', '', '')
|
||||||
highlight Whitespace guifg=#3a3a3a
|
call s:hi('Whitespace', '#3a3a3a', '', '237', '', '', '')
|
||||||
highlight SpecialKey guifg=#3a3a3a
|
call s:hi('SpecialKey', '#3a3a3a', '', '237', '', '', '')
|
||||||
|
|
||||||
" === Syntax: comments dim italic, strings green ===
|
" === Syntax: comments dim italic, strings green ===
|
||||||
highlight Comment guifg=#5a5a5a gui=italic cterm=italic
|
call s:hi('Comment', '#5a5a5a', '', '240', '', 'italic', 'italic')
|
||||||
highlight SpecialComment guifg=#5a5a5a gui=italic cterm=italic
|
call s:hi('SpecialComment', '#5a5a5a', '', '240', '', 'italic', 'italic')
|
||||||
highlight String guifg=#00b300
|
call s:hi('String', '#00b300', '', '34', '', '', '')
|
||||||
highlight Character guifg=#5a5a5a gui=italic cterm=italic
|
call s:hi('Character', '#5a5a5a', '', '240', '', 'italic', 'italic')
|
||||||
|
|
||||||
" === Literals: purple ===
|
" === Literals: purple ===
|
||||||
highlight Number guifg=#c490d0
|
call s:hi('Number', '#c490d0', '', '176', '', '', '')
|
||||||
highlight Float guifg=#c490d0
|
call s:hi('Float', '#c490d0', '', '176', '', '', '')
|
||||||
highlight Boolean guifg=#c490d0
|
call s:hi('Boolean', '#c490d0', '', '176', '', '', '')
|
||||||
highlight Constant guifg=#c490d0
|
call s:hi('Constant', '#c490d0', '', '176', '', '', '')
|
||||||
|
|
||||||
" === Identifiers / functions: white baseline, functions teal ===
|
" === Identifiers / functions: white baseline, functions teal ===
|
||||||
highlight Identifier guifg=#dadada
|
call s:hi('Identifier', '#dadada', '', '253', '', '', '')
|
||||||
highlight Function guifg=#88ddcc
|
call s:hi('Function', '#88ddcc', '', '116', '', '', '')
|
||||||
|
|
||||||
" === Statements: yellow keywords, red exception/return ===
|
" === Statements: yellow keywords, red exception/return ===
|
||||||
highlight Statement guifg=#ffcc00
|
call s:hi('Statement', '#ffcc00', '', '220', '', '', '')
|
||||||
highlight Conditional guifg=#ffcc00
|
call s:hi('Conditional', '#ffcc00', '', '220', '', '', '')
|
||||||
highlight Repeat guifg=#dadada
|
call s:hi('Repeat', '#dadada', '', '253', '', '', '')
|
||||||
highlight Keyword guifg=#ffcc00
|
call s:hi('Keyword', '#ffcc00', '', '220', '', '', '')
|
||||||
highlight Operator guifg=#dadada
|
call s:hi('Operator', '#dadada', '', '253', '', '', '')
|
||||||
highlight Label guifg=#ffcc00
|
call s:hi('Label', '#ffcc00', '', '220', '', '', '')
|
||||||
highlight Exception guifg=#ff6b6b
|
call s:hi('Exception', '#ff6b6b', '', '203', '', '', '')
|
||||||
|
|
||||||
" === PreProc family: green ===
|
" === PreProc family: green ===
|
||||||
highlight PreProc guifg=#00b300
|
call s:hi('PreProc', '#00b300', '', '34', '', '', '')
|
||||||
highlight Include guifg=#00b300
|
call s:hi('Include', '#00b300', '', '34', '', '', '')
|
||||||
highlight Define guifg=#00b300
|
call s:hi('Define', '#00b300', '', '34', '', '', '')
|
||||||
highlight Macro guifg=#00b300
|
call s:hi('Macro', '#00b300', '', '34', '', '', '')
|
||||||
highlight PreCondit guifg=#00b300
|
call s:hi('PreCondit', '#00b300', '', '34', '', '', '')
|
||||||
|
|
||||||
" === Types: amber ===
|
" === Types: amber ===
|
||||||
highlight Type guifg=#e8a060
|
call s:hi('Type', '#e8a060', '', '215', '', '', '')
|
||||||
highlight StorageClass guifg=#e8a060
|
call s:hi('StorageClass', '#e8a060', '', '215', '', '', '')
|
||||||
highlight Structure guifg=#e8a060
|
call s:hi('Structure', '#e8a060', '', '215', '', '', '')
|
||||||
highlight Typedef guifg=#e8a060
|
call s:hi('Typedef', '#e8a060', '', '215', '', '', '')
|
||||||
|
|
||||||
" === Special: green for special chars, red for tags ===
|
" === Special: green for special chars, red for tags ===
|
||||||
highlight Special guifg=#00b300
|
call s:hi('Special', '#00b300', '', '34', '', '', '')
|
||||||
highlight SpecialChar guifg=#00b300
|
call s:hi('SpecialChar', '#00b300', '', '34', '', '', '')
|
||||||
highlight Tag guifg=#ff6b6b
|
call s:hi('Tag', '#ff6b6b', '', '203', '', '', '')
|
||||||
highlight Delimiter guifg=#dadada
|
call s:hi('Delimiter', '#dadada', '', '253', '', '', '')
|
||||||
|
|
||||||
" === Errors / Todo ===
|
" === Errors / Todo ===
|
||||||
highlight Error guifg=#ff6b6b
|
call s:hi('Error', '#ff6b6b', '', '203', '', '', '')
|
||||||
highlight Todo guifg=#ffcc00 gui=bold cterm=bold
|
call s:hi('Todo', '#ffcc00', '', '220', '', 'bold', 'bold')
|
||||||
|
|
||||||
" === Line numbers / cursor / columns ===
|
" === Line numbers / cursor / columns ===
|
||||||
highlight LineNr guifg=#dadada guibg=NONE
|
call s:hi('LineNr', '#dadada', 'NONE', '253', 'NONE', '', '')
|
||||||
highlight CursorLineNr guifg=#dadada guibg=#282828 gui=bold cterm=bold
|
call s:hi('CursorLineNr', '#dadada', '#282828', '253', '235', 'bold', 'bold')
|
||||||
highlight CursorLine guibg=#121212
|
call s:hi('CursorLine', '', '#121212', '', '233', 'NONE', 'NONE')
|
||||||
highlight CursorColumn guibg=#121212
|
call s:hi('CursorColumn', '', '#121212', '', '233', '', '')
|
||||||
highlight ColorColumn guibg=#1a1a1a
|
call s:hi('ColorColumn', '', '#1a1a1a', '', '234', '', '')
|
||||||
highlight SignColumn guifg=#00b300 guibg=#000000
|
call s:hi('SignColumn', '#00b300', '#000000', '34', '16', '', '')
|
||||||
|
|
||||||
" === Splits / status / winbar ===
|
" === Splits / status / winbar ===
|
||||||
highlight VertSplit guifg=#3a3a3a guibg=NONE
|
call s:hi('VertSplit', '#3a3a3a', 'NONE', '237', 'NONE', '', '')
|
||||||
highlight WinSeparator guifg=#3a3a3a guibg=NONE
|
call s:hi('WinSeparator', '#3a3a3a', 'NONE', '237', 'NONE', '', '')
|
||||||
highlight StatusLine guifg=#dadada guibg=#000000
|
call s:hi('StatusLine', '#dadada', '#000000', '253', '16', '', '')
|
||||||
highlight StatusLineNC guifg=#dadada guibg=#000000
|
call s:hi('StatusLineNC', '#dadada', '#000000', '253', '16', '', '')
|
||||||
highlight WinBar guifg=#dadada gui=bold cterm=bold
|
call s:hi('WinBar', '#dadada', '', '253', '', 'bold', 'bold')
|
||||||
highlight WinBarNC guifg=#888888
|
call s:hi('WinBarNC', '#888888', '', '245', '', '', '')
|
||||||
|
|
||||||
" === Visual / search ===
|
" === Visual / search ===
|
||||||
highlight Visual guibg=#3a3a3a
|
call s:hi('Visual', '', '#3a3a3a', '', '237', '', '')
|
||||||
highlight VisualNOS guibg=#3a3a3a
|
call s:hi('VisualNOS', '', '#3a3a3a', '', '237', '', '')
|
||||||
highlight Search guifg=#000000 guibg=#ffcc00
|
call s:hi('Search', '#000000', '#ffcc00', '16', '220', '', '')
|
||||||
highlight IncSearch guifg=#000000 guibg=#88ddcc
|
call s:hi('IncSearch', '#000000', '#88ddcc', '16', '116', '', '')
|
||||||
highlight CurSearch guifg=#000000 guibg=#c490d0
|
call s:hi('CurSearch', '#000000', '#c490d0', '16', '176', '', '')
|
||||||
|
|
||||||
" === Brackets ===
|
" === Brackets ===
|
||||||
highlight MatchParen guifg=#c490d0 gui=bold,underline cterm=bold,underline
|
call s:hi('MatchParen', '#c490d0', '', '176', '', 'bold,underline', 'bold,underline')
|
||||||
|
|
||||||
" === Popup menu (completion / fzf overlay) ===
|
" === Popup menu (completion / fzf overlay) ===
|
||||||
highlight Pmenu guifg=#dadada guibg=#181818
|
call s:hi('Pmenu', '#dadada', '#181818', '253', '234', '', '')
|
||||||
highlight PmenuSel guifg=#000000 guibg=#ffcc00
|
call s:hi('PmenuSel', '#000000', '#ffcc00', '16', '220', '', '')
|
||||||
highlight PmenuSbar guibg=#181818
|
call s:hi('PmenuSbar', '', '#181818', '', '234', '', '')
|
||||||
highlight PmenuThumb guibg=#3a3a3a
|
call s:hi('PmenuThumb', '', '#3a3a3a', '', '237', '', '')
|
||||||
|
|
||||||
" === Folds / titles / directories ===
|
" === Folds / titles / directories ===
|
||||||
highlight Folded guifg=#888888 gui=italic cterm=italic
|
call s:hi('Folded', '#888888', '', '245', '', 'italic', 'italic')
|
||||||
highlight FoldColumn guifg=#888888 guibg=NONE
|
call s:hi('FoldColumn', '#888888', 'NONE', '245', 'NONE', '', '')
|
||||||
highlight Title guifg=#88ddcc gui=bold cterm=bold
|
call s:hi('Title', '#88ddcc', '', '116', '', 'bold', 'bold')
|
||||||
highlight Directory guifg=#88ddcc
|
call s:hi('Directory', '#88ddcc', '', '116', '', '', '')
|
||||||
|
|
||||||
" === Diff ===
|
" === Diff ===
|
||||||
highlight DiffAdd guifg=#a5d6a7 guibg=#0a2010
|
call s:hi('DiffAdd', '#a5d6a7', '#0a2010', '151', '22', '','')
|
||||||
highlight DiffChange guifg=#e8a060 guibg=#201a0a
|
call s:hi('DiffChange', '#e8a060', '#201a0a', '215', '58', '','')
|
||||||
highlight DiffDelete guifg=#ff6b6b guibg=#200a0a
|
call s:hi('DiffDelete', '#ff6b6b', '#200a0a', '203', '52', '','')
|
||||||
highlight DiffText guifg=#ffcc00 guibg=#3a2000 gui=bold cterm=bold
|
call s:hi('DiffText', '#ffcc00', '#3a2000', '220', '94', 'bold', 'bold')
|
||||||
|
|
||||||
" === Spell ===
|
" === Spell ===
|
||||||
highlight SpellBad guisp=#ff6b6b gui=undercurl cterm=underline
|
highlight SpellBad guisp=#ff6b6b gui=undercurl cterm=underline
|
||||||
highlight SpellCap guisp=#ffcc00 gui=undercurl cterm=underline
|
highlight SpellCap guisp=#ffcc00 gui=undercurl cterm=underline
|
||||||
highlight SpellRare guisp=#c490d0 gui=undercurl cterm=underline
|
highlight SpellRare guisp=#c490d0 gui=undercurl cterm=underline
|
||||||
highlight SpellLocal guisp=#88ddcc gui=undercurl cterm=undercurl
|
highlight SpellLocal guisp=#88ddcc gui=undercurl cterm=underline
|
||||||
|
|
||||||
" === Markdown (vim's built-in syntax) ===
|
" === Markdown (vim's built-in syntax) ===
|
||||||
highlight markdownH1 guifg=#00b300 gui=bold cterm=bold
|
call s:hi('markdownH1', '#00b300', '', '34', '', 'bold', 'bold')
|
||||||
highlight markdownH2 guifg=#00b300 gui=bold cterm=bold
|
call s:hi('markdownH2', '#00b300', '', '34', '', 'bold', 'bold')
|
||||||
highlight markdownH3 guifg=#00b300 gui=bold cterm=bold
|
call s:hi('markdownH3', '#00b300', '', '34', '', 'bold', 'bold')
|
||||||
highlight markdownH4 guifg=#00b300 gui=bold cterm=bold
|
call s:hi('markdownH4', '#00b300', '', '34', '', 'bold', 'bold')
|
||||||
highlight markdownH5 guifg=#00b300 gui=bold cterm=bold
|
call s:hi('markdownH5', '#00b300', '', '34', '', 'bold', 'bold')
|
||||||
highlight markdownH6 guifg=#00b300 gui=bold cterm=bold
|
call s:hi('markdownH6', '#00b300', '', '34', '', 'bold', 'bold')
|
||||||
highlight markdownHeadingDelimiter guifg=#00b300 gui=bold cterm=bold
|
call s:hi('markdownHeadingDelimiter', '#00b300', '', '34', '', 'bold', 'bold')
|
||||||
highlight markdownLinkText guifg=#88ddcc gui=underline cterm=underline
|
call s:hi('markdownLinkText', '#88ddcc', '', '116', '', 'underline', 'underline')
|
||||||
highlight markdownUrl guifg=#5a5a5a gui=italic cterm=italic
|
call s:hi('markdownUrl', '#5a5a5a', '', '240', '', 'italic', 'italic')
|
||||||
highlight markdownCode guifg=#e8a060
|
call s:hi('markdownCode', '#e8a060', '', '215', '', '', '')
|
||||||
highlight markdownCodeBlock guifg=#e8a060
|
call s:hi('markdownCodeBlock', '#e8a060', '', '215', '', '', '')
|
||||||
|
|
||||||
" === Diagnostic groups (for plugins like ALE/CoC) ===
|
" === Diagnostic groups (for plugins like ALE/CoC) ===
|
||||||
highlight DiagnosticError guifg=#ff6b6b
|
call s:hi('DiagnosticError', '#ff6b6b', '', '203', '', '', '')
|
||||||
highlight DiagnosticWarn guifg=#ffcc00
|
call s:hi('DiagnosticWarn', '#ffcc00', '', '220', '', '', '')
|
||||||
highlight DiagnosticInfo guifg=#00b300
|
call s:hi('DiagnosticInfo', '#00b300', '', '34', '', '', '')
|
||||||
highlight DiagnosticHint guifg=#dadada
|
call s:hi('DiagnosticHint', '#dadada', '', '253', '', '', '')
|
||||||
highlight link ALEErrorSign DiagnosticError
|
highlight link ALEErrorSign DiagnosticError
|
||||||
highlight link ALEWarningSign DiagnosticWarn
|
highlight link ALEWarningSign DiagnosticWarn
|
||||||
highlight link ALEInfoSign DiagnosticInfo
|
highlight link ALEInfoSign DiagnosticInfo
|
||||||
|
|
||||||
" === vim-highlightedyank ===
|
" === vim-highlightedyank ===
|
||||||
highlight HighlightedyankRegion guifg=#000000 guibg=#ffcc00
|
call s:hi('HighlightedyankRegion', '#000000', '#ffcc00', '16', '220', '', '')
|
||||||
|
|
|
||||||
7
vimrc
7
vimrc
|
|
@ -27,6 +27,9 @@ call plug#end()
|
||||||
|
|
||||||
let mapleader = "\<Space>"
|
let mapleader = "\<Space>"
|
||||||
set background=dark
|
set background=dark
|
||||||
|
if !has('gui_running') && &t_Co < 256
|
||||||
|
set t_Co=256
|
||||||
|
endif
|
||||||
if has('termguicolors')
|
if has('termguicolors')
|
||||||
set termguicolors
|
set termguicolors
|
||||||
endif
|
endif
|
||||||
|
|
@ -34,8 +37,8 @@ silent! colorscheme anticuus
|
||||||
|
|
||||||
highlight Normal ctermbg=NONE guibg=NONE ctermfg=White guifg=#FFFFFF
|
highlight Normal ctermbg=NONE guibg=NONE ctermfg=White guifg=#FFFFFF
|
||||||
highlight NonText ctermbg=NONE guibg=NONE
|
highlight NonText ctermbg=NONE guibg=NONE
|
||||||
highlight CursorLine ctermbg=NONE guibg=NONE
|
highlight CursorLine term=NONE cterm=NONE gui=NONE ctermbg=NONE guibg=NONE
|
||||||
highlight CursorLineNr ctermfg=Yellow guifg=#E5C07B ctermbg=NONE guibg=NONE cterm=bold gui=bold
|
highlight CursorLineNr term=bold ctermfg=Yellow guifg=#E5C07B ctermbg=NONE guibg=NONE cterm=bold gui=bold
|
||||||
highlight HighlightedyankRegion ctermfg=Black guifg=#000000 ctermbg=Yellow guibg=yellow
|
highlight HighlightedyankRegion ctermfg=Black guifg=#000000 ctermbg=Yellow guibg=yellow
|
||||||
highlight NormalNC ctermbg=NONE guibg=NONE
|
highlight NormalNC ctermbg=NONE guibg=NONE
|
||||||
highlight Search ctermfg=Black guifg=#000000 ctermbg=Yellow guibg=#FFCC66
|
highlight Search ctermfg=Black guifg=#000000 ctermbg=Yellow guibg=#FFCC66
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue