-
Notifications
You must be signed in to change notification settings - Fork 84
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
C-n jumps to the start of the next line first time it is used #243
Comments
There was a similar issue, but I can't find it, try #241. |
I tried |
When you start neovim, before starting VM for the first time, see what says
|
|
Because it's the normal behaviour for Also I don't understand how it can work the second time, since |
Otherwise <C-n> will insert <CR> on first run, due to default mapping occuring see mg979/vim-visual-multi#243
The above BerkeleyTrue/dotfiles@a3b4487 fixed issue for me. ( lazy=false) . I think issue can be closed. |
With Lazy.nvim, even with
|
ok, you are right - visual mode still did not work. My workaround is to call vm in any way, so that its keys gets loaded: {
"mg979/vim-visual-multi", --multi cursor
config = function()
vim.g.VM_mouse_mappings = 1
vim.cmd[[VMDebug]] -- fixes the ctrl+n in visuala mode
end,
}, |
Above answer didn't solve it, but helped by showing me the overwritten imap error in the debug message from #172 Disabling
|
I posted my solution here which was inspired by the aggregation of the answers in this issue. Also, I didn't have to disable |
To fix compatibility with nvim autopairs: config = function ()
-- Hack around issue with conflicting insert mode <BS> mapping
-- between this plugin and nvim-autopairs
vim.api.nvim_create_autocmd("User", {
pattern = "visual_multi_start",
callback = function()
pcall(vim.keymap.del, "i", "<BS>", { buffer = 0 })
end,
})
vim.api.nvim_create_autocmd("User", {
pattern = "visual_multi_exit",
callback = function()
require("nvim-autopairs").force_attach()
end,
})
end To fix compatibilty with nvim treesitter-textobjects: config = function ()
-- Fixes conflict with treesitter-textobjects bindings
vim.g.VM_maps = {
["Goto Next"] = "]v", -- can be any bind
["Goto Prev"] = "[v",
}
end Presence of any of those 2 plugins without respective fix will have a newline added on VM startup afaik. Maybe there are more plugins with a similar comp. issue |
Describe the issue:
I have the plugin installed with lazy.nvim and have it set up to not load lazily. When I type
<C-n>
instead of going to the next word the cursor jumps to the start of the next line. When I redo the steps it works normallySteps to reproduce
<C-n>
The text was updated successfully, but these errors were encountered: