1

I have noticed that some files look better than others with different colorschemes. Is there a way to toggle between two different colorschemes, for example:

colorscheme TextMate "OceanicNext

:nmap <leader>C colorscheme Textmate ? colorscheme OceanicNext : OceanicNext

1 Answer 1

2

Normally Vim colorschemes set a variable g:colors_name

nnoremap <expr><silent><leader>C printf(':colorscheme %s<CR>',
    \ g:colors_name !=# 'OceanicNext' ? 'OceanicNext' : 'Textmate')

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.