XWiki Keyboard Shortcuts

Hi,

I would like to add new keyboard shortcuts in Edit Mode,
so for example “CTRL + 1” for format a marked text to “Heading 1” , “CTRL + 2” for format a marked text to “Heading 2”, …

My questions : is this possbile ? And if yes, how is it to be done.

I’ve checked this documentation:
https://www.xwiki.org/xwiki/bin/view/Documentation/UserGuide/Features/KeyboardShortcuts
, Section “Modifying keyboards shortcuts” but I’ve no “Internationalization Document Bundles” field.

Many thanks,
vierzwerge

Hi, I’ve updated https://www.xwiki.org/xwiki/bin/view/Documentation/UserGuide/Features/KeyboardShortcuts#HModifyingkeyboardshortcuts which was not up to date (it was documenting an old way - still working but there’s a simpler way now) :slight_smile:

Note: This is to modify existing shortcuts, not to add new ones.

I’ve also updated the https://www.xwiki.org/xwiki/bin/view/Documentation/UserGuide/Features/KeyboardShortcuts#HAddingyourownshortcuts section.

Hi @vmassol, many thanks, this works great !
Now I have to check how to define the “format a text with Heading 1” … Do you have some advice for this ? Thank you.

Hi, maybe old topic but shortcut.remove("Alt+s"); completely not working for me.
Any ideas?
Cheers.