Skip to content
This repository has been archived by the owner on Sep 6, 2021. It is now read-only.

User Specified Keyboard Shortcuts for Commands (in JSON) #8814

Closed
8 tasks done
pthiess opened this issue Aug 20, 2014 · 0 comments
Closed
8 tasks done

User Specified Keyboard Shortcuts for Commands (in JSON) #8814

pthiess opened this issue Aug 20, 2014 · 0 comments
Assignees
Labels

Comments

@pthiess
Copy link
Contributor

pthiess commented Aug 20, 2014

As a user I want to specify keyboard shortcuts that persist between installations and updates to Brackets.

Criteria

  • Only handles keybindings for commands, not editor bindings currently handled by the CodeMirror keymap.
  • JSON-based keyboard shortcuts stored in user directory.
  • User shortcuts override default shortcuts
  • Shortcuts are preserved between products updates.
  • Users can remove shortcuts
  • User shortcuts should be able to override shortcuts for extension-registered commands.
    • Need to wait until after extensions are loaded (and possibly app init) to load the overlay.
    • Need to update the menus when the new shortcut is registered.
  • Don't allow modification of bindings for special commands: cut/copy/paste, undo/redo, quit.
    • Can't rebind the keys assigned to those commands.
    • Can't assign new keys to those commands.
  • Show errors when:
    • The JSON file can't be loaded or parsed for some reason
    • The special commands are modified
    • Duplicate definition of keyboard shortcuts
    • If we can't parse the shortcut combination
    • If if the command doesn't exist
  • Documentation for how the keyboard shortcuts work

Out of Scope

  • Keybindings for editor bindings handled by the CodeMirror keymap (see https://trello.com/c/s1WqPUUC/1039-user-specified-editor-keys-in-json)
  • Registering different shortcuts for specific contexts (dialogs, inline editors, etc.)
  • Unregistering a binding without assigning it to something else.
  • UI for changing keyboard shortcuts
  • Allow extensions to provide a bundle of keyboard shortcuts.
  • If a command is renamed don't automatically remap it to the new command.

Tasks

  • Determine the format of custom keyboard.json file.
  • Provide a command to create/open the custom keyboard.json (empty overlay with an item to point to the wiki)
  • Apply shortcuts from custom keyboard.json file as an overlay on top of all shortcuts specified in core and extensions..
  • Updates menus and shortcuts when the custom keyboard.json is saved.
  • Auto converts Up/Down/Left/Right arrow keys to their corresponding unicode symbols on Mac without having to use displayKey.
  • Display errors in loading or parsing the custom keyboards.json (in dialog or console - maybe follow the workflow for preferences here)
  • Unit tests
  • @redmunds Document how the keyboard shortcuts work in a wiki page.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

5 participants