|
Karsten Hopp |
9090be |
To: vim-dev@vim.org
|
|
Karsten Hopp |
9090be |
Subject: Patch 7.0.012
|
|
Karsten Hopp |
9090be |
Fcc: outbox
|
|
Karsten Hopp |
9090be |
From: Bram Moolenaar <Bram@moolenaar.net>
|
|
Karsten Hopp |
9090be |
Mime-Version: 1.0
|
|
Karsten Hopp |
9090be |
Content-Type: text/plain; charset=ISO-8859-1
|
|
Karsten Hopp |
9090be |
Content-Transfer-Encoding: 8bit
|
|
Karsten Hopp |
9090be |
------------
|
|
Karsten Hopp |
9090be |
|
|
Karsten Hopp |
9090be |
Patch 7.0.012
|
|
Karsten Hopp |
9090be |
Problem: Using the matchparen plugin, moving the cursor in Insert mode to a
|
|
Karsten Hopp |
9090be |
shorter line that ends in a brace, changes the preferred column
|
|
Karsten Hopp |
9090be |
Solution: Use winsaveview()/winrestview() instead of getpos()/setpos().
|
|
Karsten Hopp |
9090be |
Files: runtime/plugin/matchparen.vim
|
|
Karsten Hopp |
9090be |
|
|
Karsten Hopp |
9090be |
|
|
Karsten Hopp |
9090be |
*** ../vim-7.0.011/runtime/plugin/matchparen.vim Wed May 10 15:22:55 2006
|
|
Karsten Hopp |
9090be |
--- runtime/plugin/matchparen.vim Thu May 11 14:42:55 2006
|
|
Karsten Hopp |
9090be |
***************
|
|
Karsten Hopp |
9090be |
*** 1,6 ****
|
|
Karsten Hopp |
9090be |
" Vim plugin for showing matching parens
|
|
Karsten Hopp |
9090be |
" Maintainer: Bram Moolenaar <Bram@vim.org>
|
|
Karsten Hopp |
9090be |
! " Last Change: 2006 Apr 27
|
|
Karsten Hopp |
9090be |
|
|
Karsten Hopp |
9090be |
" Exit quickly when:
|
|
Karsten Hopp |
9090be |
" - this plugin was already loaded (or disabled)
|
|
Karsten Hopp |
9090be |
--- 1,6 ----
|
|
Karsten Hopp |
9090be |
" Vim plugin for showing matching parens
|
|
Karsten Hopp |
9090be |
" Maintainer: Bram Moolenaar <Bram@vim.org>
|
|
Karsten Hopp |
9090be |
! " Last Change: 2006 May 11
|
|
Karsten Hopp |
9090be |
|
|
Karsten Hopp |
9090be |
" Exit quickly when:
|
|
Karsten Hopp |
9090be |
" - this plugin was already loaded (or disabled)
|
|
Karsten Hopp |
9090be |
***************
|
|
Karsten Hopp |
9090be |
*** 90,96 ****
|
|
Karsten Hopp |
9090be |
" Find the match. When it was just before the cursor move it there for a
|
|
Karsten Hopp |
9090be |
" moment.
|
|
Karsten Hopp |
9090be |
if before > 0
|
|
Karsten Hopp |
9090be |
! let save_cursor = getpos('.')
|
|
Karsten Hopp |
9090be |
call cursor(c_lnum, c_col - before)
|
|
Karsten Hopp |
9090be |
endif
|
|
Karsten Hopp |
9090be |
|
|
Karsten Hopp |
9090be |
--- 90,96 ----
|
|
Karsten Hopp |
9090be |
" Find the match. When it was just before the cursor move it there for a
|
|
Karsten Hopp |
9090be |
" moment.
|
|
Karsten Hopp |
9090be |
if before > 0
|
|
Karsten Hopp |
9090be |
! let save_cursor = winsaveview()
|
|
Karsten Hopp |
9090be |
call cursor(c_lnum, c_col - before)
|
|
Karsten Hopp |
9090be |
endif
|
|
Karsten Hopp |
9090be |
|
|
Karsten Hopp |
9090be |
***************
|
|
Karsten Hopp |
9090be |
*** 102,108 ****
|
|
Karsten Hopp |
9090be |
let [m_lnum, m_col] = searchpairpos(c, '', c2, s_flags, s_skip, stopline)
|
|
Karsten Hopp |
9090be |
|
|
Karsten Hopp |
9090be |
if before > 0
|
|
Karsten Hopp |
9090be |
! call setpos('.', save_cursor)
|
|
Karsten Hopp |
9090be |
endif
|
|
Karsten Hopp |
9090be |
|
|
Karsten Hopp |
9090be |
" If a match is found setup match highlighting.
|
|
Karsten Hopp |
9090be |
--- 102,108 ----
|
|
Karsten Hopp |
9090be |
let [m_lnum, m_col] = searchpairpos(c, '', c2, s_flags, s_skip, stopline)
|
|
Karsten Hopp |
9090be |
|
|
Karsten Hopp |
9090be |
if before > 0
|
|
Karsten Hopp |
9090be |
! call winrestview(save_cursor)
|
|
Karsten Hopp |
9090be |
endif
|
|
Karsten Hopp |
9090be |
|
|
Karsten Hopp |
9090be |
" If a match is found setup match highlighting.
|
|
Karsten Hopp |
9090be |
*** ../vim-7.0.011/src/version.c Thu May 11 19:24:16 2006
|
|
Karsten Hopp |
9090be |
--- src/version.c Thu May 11 19:29:58 2006
|
|
Karsten Hopp |
9090be |
***************
|
|
Karsten Hopp |
9090be |
*** 668,669 ****
|
|
Karsten Hopp |
9090be |
--- 668,671 ----
|
|
Karsten Hopp |
9090be |
{ /* Add new patch number below this line */
|
|
Karsten Hopp |
9090be |
+ /**/
|
|
Karsten Hopp |
9090be |
+ 12,
|
|
Karsten Hopp |
9090be |
/**/
|
|
Karsten Hopp |
9090be |
|
|
Karsten Hopp |
9090be |
--
|
|
Karsten Hopp |
9090be |
Corduroy pillows: They're making headlines!
|
|
Karsten Hopp |
9090be |
|
|
Karsten Hopp |
9090be |
/// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
|
|
Karsten Hopp |
9090be |
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
|
|
Karsten Hopp |
9090be |
\\\ download, build and distribute -- http://www.A-A-P.org ///
|
|
Karsten Hopp |
9090be |
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
|