I’m trying to create a keyboard shortcut in the
atom-text-editor using the shortcut
cmd+<. Here is the code, resp. in keymap.cson and init.coffee:
'atom-text-editor': 'cmd-<': 'custom:insert-backslash' atom.commands.add 'atom-text-editor', 'custom:insert-backslash': -> atom.workspace.getActiveTextEditor()?.insertText('\\')
However this doesn’t work. Actually, the problem already occurs in the Key Binding Resolver:
cmd+< is not recognised, although both
< are recognised separately. Also,
< is recognised as
@ is recognised as
< (only in the Key Binding Resolver, not in the editor). Putting
cmd+@ instead of
cmd+< in the code works, although of course this is not the keybinding I want.
Does anybody have a clue? Thanks in advance for your help.
Note: I have a MacBook Pro with AZERTY keyboard, so that ‘@’ is on the left of the ‘1’ key and ‘<’ is on the left of the ‘w’ key.
Context: I’m typesetting in LaTeX, and I would like a similar keybinding for the backslash to the one with Windows keyboard, that is similar to AltGr+<.