Vim icon indicating copy to clipboard operation
Vim copied to clipboard

Cannot type capital letters in Insert mode

Open osa1 opened this issue 4 years ago • 10 comments

I'm sure this is a bad configuration or some interaction with another plugin, but I can't figure it out, and GitHub discussions is not enabled on this repo, so submitting a bug report.

Describe the bug Can't use shift in insert mode to enter uppercase letters.

To Reproduce Open any file with, switch to insert mode, try to enter uppercase letters. Some of the keys work, but for example shift-d or shift-i don't work.

Expected behavior Shift + letters should work in insert mode, insert an uppercase letter.

Environment (please complete the following information):

  • Extension (VsCodeVim) version: latest
  • VSCode version: latest
  • OS: linux

Additional context Full config:

{
    "telemetry.enableCrashReporter": false,
    "telemetry.enableTelemetry": false,
    "editor.fontFamily": "'Jetbrains Mono Medium'",
    "workbench.colorTheme": "Gray Matter Dark",
    "files.watcherExclude": {
        "**/target/**": true
    },
    "editor.lineNumbers": "off",
    "window.zoomLevel": 1,
    "editor.cursorBlinking": "solid",
    "editor.cursorStyle": "block",
    "breadcrumbs.enabled": true,
    "vim.leader": ",",
    "vim.useCtrlKeys": true,
    "vim.handleKeys": {
        "<C-f>": false,
        "<C-]>": false,
        "<C-[>": false,
        "<C-b>": false,
        "<C-k>": false,
    },
    "vim.insertModeKeyBindings": [
        {
            "before": [
                "j",
                "k"
            ],
            "after": [
                "<Esc>"
            ]
        },
        {
            "before": [
                "k",
                "j"
            ],
            "after": [
                "<Esc>"
            ]
        }
    ],
    "vim.normalModeKeyBindings": [
        {
            "before": [
                "H"
            ],
            "after": [
                "^"
            ]
        },
        {
            "before": [
                "L"
            ],
            "after": [
                "$"
            ]
        },
        {
            "before": [
                "Space"
            ],
            "after": [
                "O",
                "<Esc>"
            ]
        },
        {
            "before": [
                "Enter"
            ],
            "after": [
                "o",
                "<Esc>"
            ]
        }
    ],
    "vim.visualModeKeyBindings": [
        {
            "before": [
                "H"
            ],
            "after": [
                "^"
            ]
        },
        {
            "before": [
                "L"
            ],
            "after": [
                "$"
            ]
        },
    ],
    "editor.renderLineHighlight": "none",
    "editor.renderIndentGuides": false,
    "files.autoSave": "afterDelay",
    "gitlens.blame.ignoreWhitespace": true,
    "editor.minimap.enabled": false,
    "scm.diffDecorations": "gutter",
    "C_Cpp.updateChannel": "Insiders",
    "[rust]": {
        "editor.defaultFormatter": "matklad.rust-analyzer"
    },
    "gitlens.advanced.repositorySearchDepth": 2,
    "editor.wordWrapColumn": 100,
    "vim.textwidth": 100,
    "terminal.integrated.fontSize": 13,
    "editor.semanticHighlighting.enabled": true,
    "rust-analyzer.cargo.allFeatures": false,
    "rust-analyzer.checkOnSave.allFeatures": false,
    "editor.fontLigatures": true,
    "debug.console.fontSize": 13,
    "extensions.ignoreRecommendations": true,
    "editor.fontSize": 13,
    "search.useGlobalIgnoreFiles": true,
    "editor.renderWhitespace": "none",
    "editor.find.cursorMoveOnType": false,
    "editor.tokenColorCustomizations": {
        "[Solarized Light]": {
            "variables": "#002b36",
            "functions": "#002b36",
        },
        "[Gray Matter Dark]": {
            "comments": "#969caf"
        },
        "[Gray Matter Light]": {
            "comments": "#969caf"
        }
    },
    "editor.semanticTokenColorCustomizations": {
        "[Solarized Light]": {
            "enabled": true,
        },
        "[Gray Matter Dark]": {
            "enabled": false,
        }
    },
    "workbench.colorCustomizations": {
        "[Gray Matter Dark]": {
            "editor.background": "#282a36",
            "sideBar.background": "#282a36",
        }
    },
    "workbench.iconTheme": "vs-seti",
}

osa1 avatar Feb 03 '21 18:02 osa1

Very weird. Can you still reproduce?

J-Fields avatar Oct 15 '21 19:10 J-Fields

I have the same problem but only with the letter k. If I press shift + k in insert mode it doesn't do anything.

And with this mapping it doesn't work either. I mean, I can't use shift + k in any mode.

"vim.normalModeKeyBindingsNonRecursive": [
    {
      "before": ["J"],
      "after": ["5", "j"]
    },
    {
      "before": ["K"],
      "after": ["5", "k"]
    },
  ],

miguelangeltorresfp avatar Feb 12 '22 07:02 miguelangeltorresfp

I have the same issue as Miguel above. I cannot use shift + k in any mode. weird...

g-omahony avatar Apr 07 '22 14:04 g-omahony

Sorry, my issue is with Vim but not with vscode; I'm not sure how to delete this comment.

baezanat avatar Apr 20 '22 14:04 baezanat

In my case i mapped <S-x> where x is hjkl, changed to <A-x>

rafaeloledo avatar Feb 24 '23 08:02 rafaeloledo

Sorry, my issue is with Vim but not with vscode; I'm not sure how to delete this comment.

Same Issue here shift+k doesn't work in mode, even after disabling vim extension

Prathamesh-Chavan-232 avatar Apr 14 '23 19:04 Prathamesh-Chavan-232

in my case its shift + c which dosen't produce "C" but puts the vscode to visual mode

anshulspider avatar Jan 10 '24 22:01 anshulspider

For me, the shift K wasn't working in insert mode, vim search and vim command line mode. I fixed it by editing the keybindings.json file by adding mode exceptions in the "when" property of shift-k key.

    {
        "key": "shift+k",
        "command": "editor.action.showHover",
        "when": "editorTextFocus && vim.mode != 'Insert' && vim.mode != 'CommandlineInProgress' && vim.mode != 'SearchInProgressMode'"
    },

Zetaniis avatar Mar 05 '24 22:03 Zetaniis

cannot enter capital N

This vim extension ( vscodevim ) obviously should recognize when its in insert mode and auto disable all non vim keybindings until user hits ESC to return back to command mode

when I am editing code then enter letter N even when in vim insert mode vscode opens up a new vscode window ... showstopper bug

I know vi however am new to vscode so this bug is ongoing

related issue ... when editing code right click to display available commands like COPY and PASTE show normal ctrl-C and ctrl-V however those keybindings are not correct ... so vscode needs to make itself savvy to current keybindings so it displays correct keys on that right click command listing

scottstensland avatar Jun 08 '24 12:06 scottstensland