inner word selection in visual block mode `^viw` doesn't select inner word
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 entering visual-mode to do selections, inner-word selection fails to select the inner word, in fact, the cursor doesn't move at all.
Whilst ciw, viwc, diw, viwd, yiw, viwy etc are great for operating on inner-words, sometimes selecting multiple items in a visual block selection is more useful e.g.
- when it's a complex op and it is useful to be able to see/preview the selection before you do the operation
- selecting (sub)columns of data in a sheet
To Reproduce
Steps to reproduce the behaviour:
- Create a text file with
"Hello mother, hello father" he said, "I just came to say I love ya'" - Position the cursor at "f",
ff - Enter visual-block mode,
^v - Attempt to select the word 'father' with inner-word,
iw - Note that the cursor does not move
Expected behavior
The inner-word (father) should be selected.
Additionally in the following example, behaviour would ideally match vim, and the column should be selected up to the end of the inner-word chosen, so in the following case
first line
second line
third line
fourth
with the cursor at the f of first pressing ^vjjjiwd should leave the following:
line
line
line
Screenshots
n/a
Environment (please complete the following information):
- Extension (VsCodeVim) version: 1.25.2
- VSCode version: 1.77.3
- OS: OSX
Additional context
Sorry for the spam with the edits on this issue
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the visual-block inner-word selection in VS Code 1.77.3 with VSCodeVim 1.25.2, following the listed steps and multiline example. Trace the extension's handling of ^v and iw, then verify that 'father' is selected and the multiline selection matches the expected output.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript, vscode
- Domain
- devtools
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100