mirror of
https://github.com/neovim/neovim.git
synced 2025-02-25 18:55:25 -06:00
commit
8d93bc1a4e
@ -5751,8 +5751,12 @@ stop_insert (
|
|||||||
}
|
}
|
||||||
if (curwin->w_cursor.lnum != tpos.lnum)
|
if (curwin->w_cursor.lnum != tpos.lnum)
|
||||||
curwin->w_cursor = tpos;
|
curwin->w_cursor = tpos;
|
||||||
else if (cc != NUL)
|
else {
|
||||||
++curwin->w_cursor.col; /* put cursor back on the NUL */
|
tpos.col++;
|
||||||
|
if (cc != NUL && gchar_pos(&tpos) == NUL) {
|
||||||
|
++curwin->w_cursor.col; // put cursor back on the NUL
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/* <C-S-Right> may have started Visual mode, adjust the position for
|
/* <C-S-Right> may have started Visual mode, adjust the position for
|
||||||
* deleted characters. */
|
* deleted characters. */
|
||||||
|
@ -253,7 +253,7 @@ static int included_patches[] = {
|
|||||||
//495 NA
|
//495 NA
|
||||||
494,
|
494,
|
||||||
493,
|
493,
|
||||||
//492,
|
492,
|
||||||
491,
|
491,
|
||||||
490,
|
490,
|
||||||
489,
|
489,
|
||||||
|
@ -46,6 +46,12 @@ describe('BufEnter with modelines', function()
|
|||||||
-- Include Xxx in the current file
|
-- Include Xxx in the current file
|
||||||
feed('G:r Xxx<CR>')
|
feed('G:r Xxx<CR>')
|
||||||
|
|
||||||
|
-- Vim issue #57 do not move cursor on <c-o> when autoindent is set
|
||||||
|
execute('set fo+=r')
|
||||||
|
feed('G')
|
||||||
|
feed('o# abcdef<Esc>2hi<CR><c-o>d0<Esc>')
|
||||||
|
feed('o# abcdef<Esc>2hi<c-o>d0<Esc>')
|
||||||
|
|
||||||
expect([[
|
expect([[
|
||||||
startstart
|
startstart
|
||||||
start of test file Xxx
|
start of test file Xxx
|
||||||
@ -63,7 +69,10 @@ describe('BufEnter with modelines', function()
|
|||||||
this is a test
|
this is a test
|
||||||
this is a test
|
this is a test
|
||||||
this should be in column 1
|
this should be in column 1
|
||||||
end of test file Xxx]])
|
end of test file Xxx
|
||||||
|
# abc
|
||||||
|
def
|
||||||
|
def]])
|
||||||
end)
|
end)
|
||||||
|
|
||||||
teardown(function()
|
teardown(function()
|
||||||
|
Loading…
Reference in New Issue
Block a user