From 23146787d054cd20441ca07f3d50cb591554eadf Mon Sep 17 00:00:00 2001 From: Shougo Matsushita Date: Thu, 8 Mar 2012 18:38:58 +0900 Subject: [PATCH] - Fixed plugin indentation problem. --- autoload/neocomplcache/sources/snippets_complete.vim | 8 ++++++++ doc/neocomplcache-snippets-complete.txt | 1 + 2 files changed, 9 insertions(+) diff --git a/autoload/neocomplcache/sources/snippets_complete.vim b/autoload/neocomplcache/sources/snippets_complete.vim index 848d942..599c842 100644 --- a/autoload/neocomplcache/sources/snippets_complete.vim +++ b/autoload/neocomplcache/sources/snippets_complete.vim @@ -568,6 +568,8 @@ function! s:expand_newline()"{{{ let formatoptions = &l:formatoptions setlocal formatoptions-=r + let equalprg = &l:equalprg + setlocal equalprg= while match >= 0 let end = getline('.')[matchend(getline('.'), '<\\n>') :] @@ -581,12 +583,18 @@ function! s:expand_newline()"{{{ silent execute 'normal!' \ (match+1 >= col('$')? 'a' : 'i')."\" + let pos = getpos('.') + startinsert! + normal! == + call setpos('.', pos) + " Next match. let match = match(getline('.'), '<\\n>') let s:end_snippet += 1 endwhile let &l:formatoptions = formatoptions + let &l:equalprg = equalprg endfunction"}}} function! s:expand_tabline()"{{{ let tablines = split(getline('.'), '<\\n>') diff --git a/doc/neocomplcache-snippets-complete.txt b/doc/neocomplcache-snippets-complete.txt index 98196bd..8caf0f3 100644 --- a/doc/neocomplcache-snippets-complete.txt +++ b/doc/neocomplcache-snippets-complete.txt @@ -297,6 +297,7 @@ CHANGELOG *neocomplcache-snippets-complete-changelog* 2012-03-08 - Use shiftwidth instead of softabstop. +- Fixed plugin indentation problem. 2012-03-07 - Added snippet source.