Vscode json カスタム設定カーソル ショートカット キーを上下左右に移動する

1.設定ファイルを開く

  パスは次の図に示すとおりです: [ファイル] -> [設定] -> [キーボード ショートカット] -> [キーボード ショートカット JSON を開く] (右上隅のステップ 3 ファイル アイコン)。
ここに画像の説明を挿入

次に、構成ファイルをコピーします

  カスタムなど、開いているドキュメントに次のドキュメントをコピーするだけです。

  • カーソルの左側にあるものをすべて削除します。Ctrl + Backspace
  • カーソルの右側にあるものをすべて削除します。Alt + Backspace
// Place your key bindings in this file to override the defaultsauto[]
 
[
    {
      "key": "alt+i",
      "command": "cursorUp",
      "when": "textInputFocus"
    },
    {
      "key": "up",
      "command": "cursorUp",
      "when": "textInputFocus"
    },
    {
      "key": "alt+i",
      "command": "selectPrevSuggestion",
      "when": "suggestWidgetMultipleSuggestions && suggestWidgetVisible && textInputFocus"
    },
    {
      "key": "up",
      "command": "selectPrevSuggestion",
      "when": "suggestWidgetMultipleSuggestions && suggestWidgetVisible && textInputFocus"
    },
 
    {
      "key": "alt+k",
      "command": "cursorDown",
      "when": "textInputFocus"
    },
    {
      "key": "down",
      "command": "cursorDown",
      "when": "textInputFocus"
    },
    {
      "key": "alt+k",
      "command": "selectNextSuggestion",
      "when": "suggestWidgetMultipleSuggestions && suggestWidgetVisible && textInputFocus"
    },
    {
      "key": "down",
      "command": "-selectNextSuggestion",
      "when": "suggestWidgetMultipleSuggestions && suggestWidgetVisible && textInputFocus"
    },
 
    {
      "key": "alt+l",
      "command": "cursorRight",
      "when": "textInputFocus"
    },
    {
      "key": "right",
      "command": "cursorRight",
      "when": "textInputFocus"
    },
 
    {
      "key": "alt+j",
      "command": "cursorLeft",
      "when": "textInputFocus"
    },
    {
      "key": "left",
      "command": "cursorLeft",
      "when": "textInputFocus"
    },
 
    {
      "key": "alt+o",
      "command": "cursorEnd",
      "when": "textInputFocus"
    },
    {
      "key": "end",
      "command": "cursorEnd",
      "when": "textInputFocus"
    },
 
    {
      "key": "alt+u",
      "command": "cursorHome",
      "when": "textInputFocus"
    },
    {
      "key": "home",
      "command": "cursorHome",
      "when": "textInputFocus"
    }
    {
      "key": "alt+backspace",
      "command": "deleteAllRight",
      "when": "textInputFocus"
    }
    {
      "key": "ctrl+backspace",
      "command": "deleteAllLeft",
      "when": "textInputFocus"
    }
 
]
  
  

おすすめ

転載: blog.csdn.net/qq_38429958/article/details/126841403
おすすめ