Custom keyboard shortcuts

Keyboard shortcuts can be customized in the file Key Bindings.json. The default keyboard settings file looks as follows:

[
	...
	{ "keys": ["F4"], "command": "open_with_editor" },
	{ "keys": ["F5"], "command": "copy" },
	{ "keys": ["Shift+F6"], "command": "rename" },
	{ "keys": ["F6"], "command": "move" },
	{ "keys": ["F7"], "command": "create_directory" },
	{ "keys": ["F8"], "command": "move_to_trash" },
	...
]

To define a keyboard shortcut, go to your data directory and create (or edit) the file Plugins/​User/​Settings/​Key Bindings.json. For example, if you want to be able to open files with F3, the file would look as follows:

[
	{ "keys": ["F3"], "command": "open" }
]

To apply your changes, open the Command Palette with Ctrl+Shift+P (or Cmd+Shift+P on Mac) and enter Reload plugins:

  • Reload plugins

A list of all available commands can be found in the Core plugin. If you see a command MoveCursorDown there, refer to it in the key bindings as move_cursor_down.

Note that it is not necessary to repeat all existing keyboard shortcuts. You simply selectively (re-)define the ones you want.

A common surprise is that defining a shortcut does not remove existing ones. For example: On Mac, Enter opens the current file. When you define a new shortcut so Cmd+O does the same, then Enter still works. You can disable it by tying it to the command none:

[
	{ "keys": ["Cmd+O"], "command": "open" },
	{ "keys": ["Enter"], "command": "none" }
]

Another caveat: If you want to define a shortcut for a key that requires pressing Shift, such as for instance : or ?, then there's currently a bug that requires you to include Shift as a modifier. For instance:

{ "keys": ["Shift+:"], "command": "open" }

Further information

fman internally uses the Qt framework to process keystrokes. For a list of more available keys and further information, please see this page from the Qt documentation.

The fact that you write custom settings in Plugins/User/Settings hints at fman's plugin system. It is described in more detail on another page.