VSCodeVim / VSCodeVim/Vim

Unable to bind key `<C-v>`, it always pastes

Open
#4,649 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

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

Description

Issue Type: Bug

I have this key binding in my config:

    "vim.insertModeKeyBindings": [
        {
            "before": [
                "<C-v>",
                "tab"
            ],
            "commands": [
                {
                    "command": "type",
                    "args": "\t"
                }
            ]
        }
    ],

It doesn't work. When I'm in insert mode and I press Ctrl+v, I always paste.

I have tried setting vim.handleKeys with "<C-v>" set to both true and false, and neither make any difference.

Extension version: 1.13.0
VS Code version: Code 1.42.1 (c47d83b293181d9be64f27ff093689e8e7aed054, 2020-02-11T14:50:36.977Z)
OS version: Linux x64 5.5.7-arch1-1-audio-patched

System Info
Item Value
CPUs AMD Ryzen 9 3950X 16-Core Processor (32 x 2639)
GPU Status 2d_canvas: enabled
flash_3d: enabled
flash_stage3d: enabled
flash_stage3d_baseline: enabled
gpu_compositing: enabled
metal: disabled_off
multiple_raster_threads: enabled_on
oop_rasterization: disabled_off
protected_video_decode: unavailable_off
rasterization: disabled_software
skia_renderer: disabled_off
surface_control: disabled_off
surface_synchronization: enabled_on
video_decode: unavailable_off
viz_display_compositor: enabled_on
viz_hit_test_surface_layer: disabled_off
webgl: enabled
webgl2: enabled
Load (avg) 2, 2, 2
Memory (System) 31.38GB (17.74GB free)
Process Argv
Screen Reader no
VM 0%

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

No source file or test is named. Start by reproducing the vim.insertModeKeyBindings and vim.handleKeys configuration with Ctrl-v in the reported VS Code and extension versions, then trace the extension's keybinding handling; done means Ctrl-v reaches the configured binding instead of always pasting.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript, vscode
Domain
developer-experience, 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.