diff options
| author | Benjamin Linskey | 2018-04-13 22:34:16 -0400 |
|---|---|---|
| committer | Benjamin Linskey | 2018-04-13 22:34:16 -0400 |
| commit | a8d5d29e6607706360d181b9fd430ccd12f8b1d0 (patch) | |
| tree | ca3d22ecb69e72cf34eda9bd61fe1e50aca2972d | |
| parent | 019d30f845990aae0355dfacda95fe3db4b8d3b2 (diff) | |
| download | btl.vim-a8d5d29e6607706360d181b9fd430ccd12f8b1d0.tar.gz | |
Improve initialization
Cleaned up and improved the initialization code, fixing a couple of errors reported by the checkcolors.vim script. The script now requires that tCo be set to at least 256 and checks whether syntax highlighting is enabled before issuing “syntax reset”.
| -rw-r--r-- | colors/btl.vim | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/colors/btl.vim b/colors/btl.vim index 9fcf99b..d4c53f6 100644 --- a/colors/btl.vim +++ b/colors/btl.vim @@ -10,12 +10,17 @@ " - Add unset groups, esp. diff, quickfix window " - Consider adding some toggleable, subtle, grayscale syntax highlighting. -let g:colors_name="btl" - -syntax reset +if &t_Co < 256 + echoerr "Colorscheme requires 256-color terminal" +endif set background=dark highlight clear +if exists("syntax_on") + syntax reset +endif + +let g:colors_name="btl" " Grayscale colors used here: " |