mirror of
https://github.com/vim/vim.git
synced 2025-09-26 04:04:07 -04:00
patch 7.4.929
Problem: "gv" after paste selects one character less if 'selection' is "exclusive". Solution: Increment the end position. (Christian Brabandt)
This commit is contained in:
@@ -9496,6 +9496,9 @@ nv_put(cap)
|
|||||||
{
|
{
|
||||||
curbuf->b_visual.vi_start = curbuf->b_op_start;
|
curbuf->b_visual.vi_start = curbuf->b_op_start;
|
||||||
curbuf->b_visual.vi_end = curbuf->b_op_end;
|
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
|
/* When all lines were selected and deleted do_put() leaves an empty
|
||||||
|
@@ -210,6 +210,21 @@ $vp
|
|||||||
:$put ='aaa'
|
:$put ='aaa'
|
||||||
:$put ='bbb'
|
:$put ='bbb'
|
||||||
:$put ='ccc'
|
:$put ='ccc'
|
||||||
|
:-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
|
:set selection=exclusive
|
||||||
0v3lgvcxxx
|
0v3lgvcxxx
|
||||||
:$put ='---'
|
:$put ='---'
|
||||||
|
@@ -112,3 +112,12 @@ cc
|
|||||||
aaa
|
aaa
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
|
gv in exclusive select mode after operation
|
||||||
|
zzz
|
||||||
|
xxx
|
||||||
|
---
|
||||||
|
|
||||||
|
gv in exclusive select mode without operation
|
||||||
|
xxx
|
||||||
|
---
|
||||||
|
@@ -741,6 +741,8 @@ static char *(features[]) =
|
|||||||
|
|
||||||
static int included_patches[] =
|
static int included_patches[] =
|
||||||
{ /* Add new patch number below this line */
|
{ /* Add new patch number below this line */
|
||||||
|
/**/
|
||||||
|
929,
|
||||||
/**/
|
/**/
|
||||||
928,
|
928,
|
||||||
/**/
|
/**/
|
||||||
|
Reference in New Issue
Block a user