Improve redraw in search mode

This commit is contained in:
hrsh7th
2022-01-10 23:52:23 +09:00
parent 21456a109e
commit ef5bdb43fa

View File

@@ -187,8 +187,10 @@ misc.redraw = setmetatable({
}, {
__call = function(self, force)
if vim.tbl_contains({ '/', '?' }, vim.fn.getcmdtype()) then
if vim.o.incsearch then
return vim.api.nvim_feedkeys(vim.api.nvim_replace_termcodes('<C-r>=""<CR>', true, true, true), 'n', true)
end
end
if self.doing then
return