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

Lag for key mapping for move up one line #6743

Open
mhz5 opened this issue Jun 15, 2021 · 7 comments · May be fixed by #6860 or #9403
Open

Lag for key mapping for move up one line #6743

mhz5 opened this issue Jun 15, 2021 · 7 comments · May be fixed by #6860 or #9403

Comments

@mhz5
Copy link

mhz5 commented Jun 15, 2021

Describe the bug
When c is mapped to k (move up one line) in Normal mode, pressing c has significant lag.

To Reproduce

  • settings.json includes the setting: "vim.vimrc.enable": true
  • .vimrc includes the mapping: noremap c k (c key moves up one line)
  • In normal mode, press c c c. There is lag.

Expected behavior
There should be no lag.

Environment (please complete the following information):

  • Extension (VsCodeVim) version:
  • VSCode version: Bug introduced in 1.21.0
  • OS: Mac 11.3.1
@pcwa-ahendricks
Copy link

pcwa-ahendricks commented Jun 16, 2021

Having a similar issue with one of my re-mappings after a recent update. In normal mode there is now a lag which didn't happen before.

   "vim.normalModeKeyBindingsNonRecursive": [
    {
      "before": ["d"],
      "after": ["p"]
    }
  ],

@waynewaynetsai
Copy link
Contributor

waynewaynetsai commented Jun 22, 2021

We could set less delay time for remapped commands directly at settings.json.
image

@pcwa-ahendricks
Copy link

Setting that to 0 breaks a number of other commands as far as I can tell.

@waynewaynetsai
Copy link
Contributor

Setting that to 0 breaks a number of other commands as far as I can tell.

Is there any github issue about it ?

@pcwa-ahendricks
Copy link

Setting that to 0 breaks a number of other commands as far as I can tell.

Is there any github issue about it ?

I'm not sure if that is necessarily a bug so there may be no issue for that one; it appears any remap that uses more that one character seems to not work with a 0 timeout value. Either way, I believe this issue relates to a breaking change that occurred after the 1.21.0 release. 1.20.3 didn't have this issue. The timeout setting existed during the 1.21.0 release when this wasn't an issue so I don't believe that to be the underlying cause.

@sql-koala
Copy link
Contributor

see #6812
Looks like we need to create an option.

@sql-koala sql-koala linked a pull request Jul 11, 2021 that will close this issue
@pcwa-ahendricks
Copy link

Can this issue get labeled as a bug?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
6 participants
@mhz5 @J-Fields @pcwa-ahendricks @waynewaynetsai @sql-koala and others