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

text objects' functions gets spelt in full in the command line #78

Open
resolritter opened this issue Sep 15, 2019 · 4 comments
Open

text objects' functions gets spelt in full in the command line #78

resolritter opened this issue Sep 15, 2019 · 4 comments

Comments

@resolritter
Copy link

resolritter commented Sep 15, 2019

When you have a map like this:

onoremap <silent> [key] :call TextObjectFunction()<CR>

Upon typing cw, the text object won't be changed right away. You'll first see the :call command get typed fully in the command-line before actually going through, which adds a noticeable delay and general unexpected visual noise.

Reverting to 474f12c solves this problem.

If the behavior is not clear enough, Monday I can post a short 4 second video demonstrating what actually happens. Currently I can't due to bad internet.

@ardagnir
Copy link
Owner

ardagnir commented Oct 23, 2019

This is caused by vim/vim#2889

This can be fixed in neovim by using <Cmd> instead of ":".

For normal vim, I'm adding a helper function to workaround this problem (currently in branch 1.3).

@resolritter
Copy link
Author

Thank you for taking a look at this. I'm still seeing the behavior in the OP on my end (testing on branch 1.3, using Vim, not Neovim).

@shahzebs
Copy link

I could really see myself using this. However, the described behavior is disturbing. Hoping for a fix soon.

@ardagnir
Copy link
Owner

ardagnir commented Mar 1, 2021

Regular vim now has support for <cmd> so this should now only be a problem for older-style mappings

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