VSCodeVim / VSCodeVim/Vim

Annoying flicker when adding keybinding to EasyMotion

Open
#6,130 1 comment 4 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
15.2k
Forks
1.5k
Avg merge
3d 18h
Merged PRs (30d)
6

Description

Describe the bug
When I use vim keybindings to trigger an easymotion search, there is a noticeable flicker when the command is executed that is not there if I type in the command manually. I'm not sure if this behavior exists for other things (but I only noticed it now because easymotion is so visual)

To Reproduce
Steps to reproduce the behavior:

  1. Go to settings.json.
  2. Add the following keybinding, make sure easy motion is enabled.
"vim.normalModeKeyBindingsNonRecursive": [
		{
			"before": [" "],
			"after": ["leader", "leader", "leader", "b", "d", "w"]
		},
],
"vim.easymotion": true
  1. Hit the spacebar to trigger easymotion, notice flicker.
  2. For comparison, type in <leader> <leader> <leader> b d w manually.

Expected behavior
Instant and/or smooth transition into EASY-MOTION mode overlay (same as typing in the command manually). Instead, there is a flicker where the overlay appears twice. It seems like a small thing, but it's very unpleasant to look at and makes me avoid the otherwise great feature.

Also, the problem persists even when I change the key that the shortcut is bound to.

Screen recording
Here is a screen recording, comparing manual input (first) to the keybinding

Environment (please complete the following information):

  • Extension (VsCodeVim) version: 1.18.9
  • VSCode version: 1.53.2
  • OS: macOS Mojave

Additional context
I've noticed this happens more when there are a lot of lines. If I open a 10-line JSON file, it transitions instantly, often with single-character markers. However, in most files that I need to work in, there are more than 10 lines per file and easymotion needs to generate two-character markers.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the keybinding and manual EasyMotion sequences from settings.json, using the reported extension, VSCode, and macOS versions. Compare behavior in short and longer files, especially when two-character markers are generated; done means the keybinding enters EasyMotion without the overlay flickering or appearing twice.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript, vscode
Domain
tooling
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.