VSCodeVim / VSCodeVim/Vim

Letter under cursor is not included in selection in visual selection mode

Open
#5,517 2 comments 1 reaction 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 / To Reproduce
In normal mode, the character under the cursor is affected as it should be. E.g. cursor starts under h, I press e cursor moves to the letter o and I press x, then o is deleted.

hello world
    ^

In visual selection mode, cursor starts under h, I press e, cursor moves past o, and if I press d hello is deleted, but not the space on which the cursor is positioned.

hello world
-----^

Expected behavior
When selecting text in visual mode, it is expected that the character under the cursor is included in the selection.

Environment (please complete the following information):

  • Extension (VsCodeVim) version: 1.17.1
  • VSCode version: 1.50.1
  • OS: macOS 10.13.6

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

Reproduce the reported movement and deletion sequence in VSCode using the issue's example text, comparing normal mode with visual selection mode. Trace the visual-selection handling for the e motion and d deletion; done means the character under the cursor is included in the selection and the described deletion behaves as expected.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript, vscode
Domain
tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.