From 16d8f388bd881f9fb5a6c52c332d2800e5e7c787 Mon Sep 17 00:00:00 2001 From: Nate Kane Date: Sun, 5 Dec 2010 19:30:10 +1000 Subject: [PATCH] Fixed bug with highlight colors not working --- plugin/indent-guides.vim | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/plugin/indent-guides.vim b/plugin/indent-guides.vim index 6136a20..d7f1abc 100644 --- a/plugin/indent-guides.vim +++ b/plugin/indent-guides.vim @@ -14,6 +14,7 @@ endfunction function! s:IndentGuidesEnable() IndentGuidesDisable + call s:IndentGuidesHighlightColors() for level in range(1, g:IndentGuides_indent_levels) let group = 'IndentLevel' . ((level % 2 == 0) ? 'Even' : 'Odd') @@ -41,6 +42,11 @@ function! s:IndentGuidesDisable() endif endfunction +function! s:IndentGuidesHighlightColors() + hi IndentLevelOdd guibg=#252525 + hi IndentLevelEven guibg=#303030 +endfunction + " Commands command! IndentGuidesToggle call s:IndentGuidesToggle() command! IndentGuidesEnable call s:IndentGuidesEnable() @@ -50,10 +56,6 @@ command! IndentGuidesDisable call s:IndentGuidesDisable() let g:IndentGuides_indent_levels = 50 let g:IndentGuides_debug = 0 -" Default highlight colors -hi IndentLevelOdd guibg=#252525 -hi IndentLevelEven guibg=#303030 - " Default mapping nmap ig :IndentGuidesToggle