diff --git a/7.4.929 b/7.4.929 new file mode 100644 index 0000000..6db323e --- /dev/null +++ b/7.4.929 @@ -0,0 +1,90 @@ +To: vim_dev@googlegroups.com +Subject: Patch 7.4.929 +Fcc: outbox +From: Bram Moolenaar +Mime-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.4.929 +Problem: "gv" after paste selects one character less if 'selection' is + "exclusive". +Solution: Increment the end position. (Christian Brabandt) +Files: src/normal.c, src/testdir/test94.in, src/testdir/test94.ok + + +*** ../vim-7.4.928/src/normal.c 2015-09-25 19:34:57.891936941 +0200 +--- src/normal.c 2015-11-19 20:09:02.567921274 +0100 +*************** +*** 9496,9501 **** +--- 9496,9504 ---- + { + curbuf->b_visual.vi_start = curbuf->b_op_start; + curbuf->b_visual.vi_end = curbuf->b_op_end; ++ /* need to adjust cursor position */ ++ if (*p_sel == 'e') ++ inc(&curbuf->b_visual.vi_end); + } + + /* When all lines were selected and deleted do_put() leaves an empty +*** ../vim-7.4.928/src/testdir/test94.in 2015-06-19 15:17:49.891065610 +0200 +--- src/testdir/test94.in 2015-11-19 20:08:31.508255552 +0100 +*************** +*** 210,215 **** +--- 210,230 ---- + :-2yank + $v$p + :$put ='---' ++ : ++ :$put ='' ++ :$put ='gv in exclusive select mode after operation' ++ :$put ='zzz ' ++ :$put ='äà ' ++ :set selection=exclusive ++ kv3lyjv3lpgvcxxx ++ :$put ='---' ++ : ++ :$put ='' ++ :$put ='gv in exclusive select mode without operation' ++ :$put ='zzz ' ++ :set selection=exclusive ++ 0v3lgvcxxx ++ :$put ='---' + :/^start:/+2,$w! test.out + :q! + ENDTEST +*** ../vim-7.4.928/src/testdir/test94.ok 2015-06-19 15:17:49.891065610 +0200 +--- src/testdir/test94.ok 2015-11-19 19:59:32.450049406 +0100 +*************** +*** 112,114 **** +--- 112,123 ---- + aaa + + --- ++ ++ gv in exclusive select mode after operation ++ zzz ++ xxx ++ --- ++ ++ gv in exclusive select mode without operation ++ xxx ++ --- +*** ../vim-7.4.928/src/version.c 2015-11-19 19:55:12.340839491 +0100 +--- src/version.c 2015-11-19 19:59:18.198202378 +0100 +*************** +*** 743,744 **** +--- 743,746 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 929, + /**/ + +-- +Support your right to bare arms! Wear short sleeves! + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ an exciting new programming language -- http://www.Zimbu.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org ///