Mark Llobrera

Sublime Text 2: Remapping Key Bindings

While looking for a way to remap the keyboard shortcut for “Enter Full Screen” to “Replace All”, I kept running into a wall. Merely specifying the same keyboard shortcut didn’t work, as Sublime Text seemed to favor the default mapping. I stumbled onto this note, however, which illustrated how to unbind a keyboard shortcut:

{ "keys": ["alt+shift+left"], "command": "unbound" }

So I ended up unbinding the shortcut, and then remapped it:

{ "keys": ["super+ctrl+f"], "command": "unbound" },
{ "keys": ["super+ctrl+f"], "command": "replace_all", "args": {"close_panel": true},
"context": [{"key": "panel", "operand": "replace"}, {"key": "panel_has_focus"}]