Skip to content
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

"ii" Insert Mode Mapping Unexpected Behavior #3786

Closed
e-thn opened this issue May 20, 2019 · 3 comments
Closed

"ii" Insert Mode Mapping Unexpected Behavior #3786

e-thn opened this issue May 20, 2019 · 3 comments

Comments

@e-thn
Copy link

e-thn commented May 20, 2019

I like to have ii mapped to Esc in insert mode (my Colemak equivalent of jj), which works fine in vim, however it causes some unusual behaviour in VSCodeVim.

In VSCodeVim, if I press i to change to insert mode, it enters insert mode, but if I press i again (before the timeout), it returns to normal mode, and undoes the last edit I made.

Normally in vim, pressing i to enter insert mode, followed by i again allows me to continue in insert mode.

My best guess is that the i to enter insert mode is being counted as part of the ii insert mode mapping.

My Config

"vim.insertModeKeyBindings": [{ "before": ["i", "i"], "after": ["<Esc>"] }]

Environment

  • Extension (VsCodeVim) version: 1.8.0
  • VSCode version: 1.33.1
  • OS: Any
@mauricecruz
Copy link

Think this issue is being tracked in #1821

@J-Fields
Copy link
Member

inoremap ii <ESC> works for me. @Eja26 is this still an issue?

@e-thn
Copy link
Author

e-thn commented Dec 13, 2019

I have just retested it, and it works for me too now - no longer an issue.

@e-thn e-thn closed this as completed Dec 13, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants