How to create own shortcuts?

Hi,
Is it possible to create your own shortcuts, and how to do that?

For example, I am constantly using:

  1. Move the note to the notebook. It might be a CTRL+M shortcut.
  2. Duplicate note. It might be a CTRL+D shortcut.
  3. Delete note. It might be a CTRL+DEL shortcut.
  4. Copy the Markdown link. It might be a CTRL+ALT+K shortcut.

Is there a way to implement this?

7 Likes

I want this too!
I need one shortcut for highlighting.
Joplin is getting better day by day :grinning:

2 Likes

@tessus I hoped you could answer because I saw your discussion somewhere about creating own shortcuts, but I couldn't find it. Maybe it was in some thread that is not related to shortcuts directly.

Did I make a mistake, and you have not discussed the ways to create shortcuts? If so, sorry for disturbing you.

Currently you can only set the keyboard shortcuts that are in the list of Preferences -> Keyboard Shortcuts.

I haven't really looked at the plugins code yet, so I don't know, if the shortcuts you mentioned can be done via a plugin or if they have to be added to the core code. After the refactoring I lost track of the code a bit.
Some of the things I would go to in the code don't exist anymore or had been transformed into a few levels of abstraction. I guess it will take me a while to familiarize myself with the code again.

But all of the examples are good choices for shortcuts. Maybe Laurent can let us know what the best way is to implement those. Code vs plugin....

I think its possible to register command in menu item with plugin and assign accelerator to it (aka keyboard short cut)
take a look at this line

EDIT: but it seems you would have to replicate behavior (like duplicate note) inside of plugin.

1 Like

+1 here. I am particularly interested in the following shortcuts:

  • copy the Markdown link of a note
  • delete a note

@tessus would you suggest creating another thread for "Add shortcut to copy Markdown link of a note" - or adding this shortcut is related to the more general question of this thread: How to create [your] own shortcuts?

Hi,

I have a plugin that copies Markdown link of a note - an makes keyboard shortcut available.

I'm confirming if will work with Joplin 1.6 to publish it.
Btw. What version of Joplin do you use now?

Here it is

This is only possible with a plugin. Otherwise it would have to be added to the Joplin core code.

Both of your suggestions make sense and I would add them to the core, but this decision lies with @laurent

6 Likes

I would really like to use a shortcut to create a checkbox, as - [ ] is tedious to type (or to move the mouse to the menu). And it would be even more fantastic if another shortcut would mark the checkbox complete (and add a datetime at the end of the line!) - I am using an extension in VS Code that does all these things, and would find it so convenient if it was in Joplin also.

4 Likes

I looked for this one as well, I liked the current keyboard shortcuts, but I also use Vim. Some of the default keyboard shortcuts are disabled when using Vim: Ctrl+Shift+L/S are disabled.

By any chance, do you guys have an idea if there's a shortcut to toggle Vim keyboard?