Vim - 'escape' key issue when keys chained
Yorgg opened this issue · 5 comments
Escape is not correctly pressed+released in Vim when I chain keys
(it seems like the esc key is held down while the next key is executed).
mapping = { 'grep': Key('escape, space, f, p') }
I also tried this, and same result:
mapping = { 'grep': Key('escape') + Key('space, f, p') }
this also fails:
def _esc():
Key("escape:down").execute()
Key("escape:up").execute()
mapping = { 'grep': Function(_esc) + Key('space, f, p') }
I am using NeoVim
I was able to remove this error by adding a sleep call:
def _esc():
Key("escape:down").execute()
Key("escape:up").execute()
sleep(0.1)
I'm not familiar with the aenea code base, but I know the basic Dragonfly API allows a pause or delay to be given inside of the key spec. I believe it works something like Key("escape/10")
, with time being hundredths of a second.
thanks Versatilus, I had tried that but it also didn't work.
Hmm, I assume this is not related to Aenea, and mark as resolved.
I believe the "escape/10" thing could be made to work in Aenea; we use our own key parser and I don't remember if we implement that notation. But the broader question of why a pause is needed I suspect is mostly likely a function of xdotool/x itself.