diff --git a/doc/syntastic.txt b/doc/syntastic.txt index 4f32784f..ba84144e 100644 --- a/doc/syntastic.txt +++ b/doc/syntastic.txt @@ -203,6 +203,14 @@ detected, but not opened automatically. > let g:syntastic_auto_loc_list=2 < + *'syntastic_loc_list_height'* +Default: 10 +Use this option to specify the height of the location lists that syntastic +opens. > + let g:syntastic_loc_list_height=5 +< + + *'syntastic_mode_map'* Default: { "mode": "active", "active_filetypes": [], diff --git a/plugin/syntastic.vim b/plugin/syntastic.vim index efb674ec..6fb8066a 100644 --- a/plugin/syntastic.vim +++ b/plugin/syntastic.vim @@ -81,6 +81,10 @@ if !exists("g:syntastic_check_on_open") let g:syntastic_check_on_open = 0 endif +if !exists("g:syntastic_loc_list_height") + let g:syntastic_loc_list_height = 10 +endif + command! SyntasticToggleMode call s:ToggleMode() command! SyntasticCheck call s:UpdateErrors(0) redraw! command! Errors call s:ShowLocList() @@ -340,7 +344,7 @@ endfunction function! s:ShowLocList() if !empty(s:LocList()) let num = winnr() - lopen + exec "lopen " . g:syntastic_loc_list_height if num != winnr() wincmd p endif