diff options
author | cathook <b01902109@csie.ntu.edu.tw> | 2014-11-20 08:24:44 +0800 |
---|---|---|
committer | cathook <b01902109@csie.ntu.edu.tw> | 2014-11-20 08:24:44 +0800 |
commit | 17ac3088d3c401e800d7f56a12cdd2bed78d5bb8 (patch) | |
tree | f775d95ec2916c6103872951445b02d3aa04e5c4 | |
parent | e8a48909eabbfcc6693590fa6b42eade6431c2ca (diff) | |
download | vim-shrvim-17ac3088d3c401e800d7f56a12cdd2bed78d5bb8.tar vim-shrvim-17ac3088d3c401e800d7f56a12cdd2bed78d5bb8.tar.gz vim-shrvim-17ac3088d3c401e800d7f56a12cdd2bed78d5bb8.tar.bz2 vim-shrvim-17ac3088d3c401e800d7f56a12cdd2bed78d5bb8.tar.lz vim-shrvim-17ac3088d3c401e800d7f56a12cdd2bed78d5bb8.tar.xz vim-shrvim-17ac3088d3c401e800d7f56a12cdd2bed78d5bb8.tar.zst vim-shrvim-17ac3088d3c401e800d7f56a12cdd2bed78d5bb8.zip |
fix "o" command in vim
-rw-r--r-- | vim/plugin/shrvim.vim | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/vim/plugin/shrvim.vim b/vim/plugin/shrvim.vim index 0d2b4fe..070a35f 100644 --- a/vim/plugin/shrvim.vim +++ b/vim/plugin/shrvim.vim @@ -25,7 +25,6 @@ let g:shrvim_auto_sync_level = 3 autocmd! InsertLeave * call _ShrVimAutoSync(1) autocmd! CursorMoved * call _ShrVimAutoSync(1) autocmd! CursorHold * call _ShrVimAutoSync(1) -autocmd! InsertEnter * call _ShrVimAutoSync(2) autocmd! CursorMovedI * call _ShrVimAutoSync(3) autocmd! CursorHoldI * call _ShrVimAutoSync(3) @@ -461,6 +460,8 @@ class VimLinesInfo(object): for last in range(orig_rows - 1, first - 1, -1): if orig_lines[last] != self._lines[last + delta]: break + else: + last -= 1 return [(first, last + 1, self._lines[first : last + delta + 1])] def apply_patch(self, patch_info): |