pqrs-org / Karabiner-Elements

Karabiner-Elements is a powerful utility for keyboard customization on macOS Sierra (10.12) or later.
https://pqrs.org/osx/karabiner/
The Unlicense
18.63k stars 836 forks source link

vscode complex_modifications not working #3814

Open rickalex21 opened 4 months ago

rickalex21 commented 4 months ago

Hello,

Thanks for all the great work.

My complex modifications seem to work fine on kitty and Emacs but for some reason they are not working on VSCODE.

{
  "title": "Swap Command and Control for Apps",
  "rules": [
    {
      "description": "Swap Control -> Command for Apps",
      "manipulators": [
        {
          "type": "basic",
          "from": {
            "key_code": "left_control",
            "modifiers": {
              "optional": [
                "any"
              ]
            }
          },
          "to": [
            {
              "key_code": "left_command"
            }
          ],
          "conditions": [
            {
              "type": "frontmost_application_if",
              "bundle_identifiers": [
                "^net\\.kovidgoyal\\.kitty$",
                "^com\\.microsoft\\.VSCode$",
                "^md\\.obsidian$",
                "org\\.gnu\\.Emacs$"
              ]
            }
          ]
        }
      ]
    },
    {
      "description": "Swap Command -> Control for Apps",
      "manipulators": [
        {
          "type": "basic",
          "from": {
            "key_code": "left_command",
            "modifiers": {
              "optional": [
                "any"
              ]
            }
          },
          "to": [
            {
              "key_code": "left_control"
            }
          ],
          "conditions": [
            {
              "type": "frontmost_application_if",
              "bundle_identifiers": [
                "^net\\.kovidgoyal\\.kitty$",
                "^com\\.microsoft\\.VSCode$",
                "^md\\.obsidian$",
                "org\\.gnu\\.Emacs$"
              ]
            }
          ]
        }
      ]
    }
  ]
}