VSCodeVim / VSCodeVim/Vim

addSelectionToNextFindMatch shortcut (ctrl+d) does not work in Visual Line mode

Open
#4,895 8 comments 0 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
Note that I have the following settings:

...
  "vim.useCtrlKeys": false,
  "vim.handleKeys": {
    "<C-c>": false,
    "<C-d>": false,
    "<C-u>": false,
    "<C-v>": false,
  },
...

When an entire line of text is selected with shift+v and when I try to select the next match with ctrl+d, the text does not get selected

In contrast, this works fine if the text is first selected with a mouse and ctrl+d is pressed
OR
the text is selected (in visual mode) with v + nav key (h,j,k,l) and ctrl+d is pressed

To Reproduce
Steps to reproduce the behavior:

  1. Open/create a file that has lines of duplicated text.
    ie.
sample text
sample text
sample text
....
  1. Navigate to the first line and press shift+v
  2. Once the line is selected as per step 2, press ctrl+d
  3. Watch as the shortcut fails

Expected behavior
I expect subsequent lines of duplicated text to be selected

Environment (please complete the following information):

  • Extension (VsCodeVim) version: 1.14.5
  • Version: 1.45.1 (user setup)
  • OS: Windows_NT x64 10.0.18363

Additional context
Also, this might be related/duplicate of issue #4277

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 failure with Shift+V followed by Ctrl+D in Visual Line mode, using the reported vim.useCtrlKeys and vim.handleKeys settings. Compare it with mouse selection and characterwise visual selection, then trace the addSelectionToNextFindMatch shortcut handling; done means duplicated subsequent lines are selected consistently.

Written by the indexing model from the issue text.

Assessment

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

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.