mirror of
https://github.com/neovim/neovim.git
synced 2025-02-25 18:55:25 -06:00
vim-patch:8.0.0282 vim-patch:8.0.0291 (#7255)
vim-patch:8.0.0291 Problem: Visual block insertion does not insert in all lines. Solution: Don't bail out of insert too early. Add a test. (Christian Brabandt, closes vim/vim#1290)23fa81d222
vim-patch:8.0.0282 Problem: When doing a Visual selection and using "I" to go to insert mode, CTRL-O needs to be used twice to go to Normal mode. (Coacher) Solution: Check for the return value of edit(). (Christian Brabandt, closes #1290)0b5c93a7f2
This commit is contained in:
parent
d173d48177
commit
713a957e9c
@ -1942,8 +1942,11 @@ void do_pending_operator(cmdarg_T *cap, int old_col, bool gui_yank)
|
|||||||
* the lines. */
|
* the lines. */
|
||||||
auto_format(false, true);
|
auto_format(false, true);
|
||||||
|
|
||||||
if (restart_edit == 0)
|
if (restart_edit == 0) {
|
||||||
restart_edit = restart_edit_save;
|
restart_edit = restart_edit_save;
|
||||||
|
} else {
|
||||||
|
cap->retval |= CA_COMMAND_BUSY;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
@ -2060,7 +2060,7 @@ void op_insert(oparg_T *oap, long count1)
|
|||||||
}
|
}
|
||||||
|
|
||||||
t1 = oap->start;
|
t1 = oap->start;
|
||||||
edit(NUL, false, (linenr_T)count1);
|
(void)edit(NUL, false, (linenr_T)count1);
|
||||||
|
|
||||||
// When a tab was inserted, and the characters in front of the tab
|
// When a tab was inserted, and the characters in front of the tab
|
||||||
// have been converted to a tab as well, the column of the cursor
|
// have been converted to a tab as well, the column of the cursor
|
||||||
|
@ -15,3 +15,16 @@ func Test_block_shift_multibyte()
|
|||||||
call assert_equal(' ヹxxx', getline(2))
|
call assert_equal(' ヹxxx', getline(2))
|
||||||
q!
|
q!
|
||||||
endfunc
|
endfunc
|
||||||
|
|
||||||
|
func Test_Visual_ctrl_o()
|
||||||
|
new
|
||||||
|
call setline(1, ['one', 'two', 'three'])
|
||||||
|
call cursor(1,2)
|
||||||
|
set noshowmode
|
||||||
|
set tw=0
|
||||||
|
call feedkeys("\<c-v>jjlIa\<c-\>\<c-o>:set tw=88\<cr>\<esc>", 'tx')
|
||||||
|
call assert_equal(['oane', 'tawo', 'tahree'], getline(1, 3))
|
||||||
|
call assert_equal(88, &tw)
|
||||||
|
set tw&
|
||||||
|
bw!
|
||||||
|
endfu
|
||||||
|
@ -661,7 +661,7 @@ static const int included_patches[] = {
|
|||||||
// 294,
|
// 294,
|
||||||
// 293,
|
// 293,
|
||||||
// 292,
|
// 292,
|
||||||
// 291,
|
291,
|
||||||
290,
|
290,
|
||||||
// 289,
|
// 289,
|
||||||
// 288 NA
|
// 288 NA
|
||||||
@ -670,7 +670,7 @@ static const int included_patches[] = {
|
|||||||
// 285 NA
|
// 285 NA
|
||||||
// 284 NA
|
// 284 NA
|
||||||
// 283,
|
// 283,
|
||||||
// 282,
|
282,
|
||||||
// 281 NA
|
// 281 NA
|
||||||
280,
|
280,
|
||||||
// 279 NA
|
// 279 NA
|
||||||
|
Loading…
Reference in New Issue
Block a user