34 lines
1.3 KiB
Plaintext
34 lines
1.3 KiB
Plaintext
|
function! s:sonokai_custom() abort
|
||
|
" Link a highlight group to a predefined highlight group.
|
||
|
" See `colors/sonokai.vim` for all predefined highlight groups.
|
||
|
"highlight! link groupA groupB
|
||
|
"highlight! link groupC groupD
|
||
|
|
||
|
" Initialize the color palette.
|
||
|
" The parameter is a valid value for `g:sonokai_style`,
|
||
|
let l:palette = sonokai#get_palette('default')
|
||
|
" Define a highlight group.
|
||
|
" The first parameter is the name of a highlight group,
|
||
|
" the second parameter is the foreground color,
|
||
|
" the third parameter is the background color,
|
||
|
" the fourth parameter is for UI highlighting which is optional,
|
||
|
" and the last parameter is for `guisp` which is also optional.
|
||
|
" See `autoload/sonokai.vim` for the format of `l:palette`.
|
||
|
call sonokai#highlight('LineNr', l:palette.grey, l:palette.bg1)
|
||
|
call sonokai#highlight('SignColumn', l:palette.fg, l:palette.bg1)
|
||
|
call sonokai#highlight('VertSplit', l:palette.bg1, l:palette.none)
|
||
|
call sonokai#highlight('Terminal', l:palette.fg, l:palette.bg1)
|
||
|
endfunction
|
||
|
|
||
|
augroup CustomColors
|
||
|
autocmd!
|
||
|
autocmd ColorScheme sonokai call s:sonokai_custom()
|
||
|
augroup END
|
||
|
|
||
|
" Colorscheme setup
|
||
|
let g:lightline.colorscheme = 'sonokai'
|
||
|
let g:sonokai_transparent_background = 1
|
||
|
let g:sonokai_show_eob = 0
|
||
|
|
||
|
colorscheme sonokai
|