Marktext: Keybindings.json in marktext-user-data is not being respected

Created on 27 Sep 2019  路  3Comments  路  Source: marktext/marktext

Description

As explained in KEYBINDINGS.md I have created a keybindings.json file and placed it inside of my marktext-user-data which is on a usb. I use portable Mark Text at work from this usb.

  • [x] Can you reproduce the issue?

Steps to reproduce

  1. Install Mark Text Portable (I don't think that it has to be on a usb).
  2. Create marktext-user-data as instructed in PORTABLE.md.
  3. In marktext-user-data create a keybindings.json like this.
{
  "fileNewTab": "CmdOrCtrl+T",
  "viewToggleSideBar": "CmdOrCtrl+Shift+R"
}
  1. Open Mark Text Portable and try and use the Shortcuts above. They will do their original actions
    and not open a new tab or toggle the sidebar.

Expected behavior:

Shortcuts specified in keybindings.json should override keyboard shortcuts in Mark Text.

Actual behavior:

No change to the keyboard shortcuts.

Versions

  • Mark Text: v0.15.0
  • Operating system: Windows 7 32 bit
platforwindows platforlinux 馃悰 bug

Most helpful comment

@yougotwill There was another issue that is fixed now. You need to unset the default shortcut until the next release. This configuration should work for now:

{
  "fileNewTab": "Ctrl+T",
  "paragraphTable": "",
  "viewToggleSideBar": "Ctrl+Shift+R",
  "formatClearFormat": "",
  "viewDevReload": ""
}

You can verify this by launching Mark Text via command line:

$ marktext
   Invalid keybindings.json configuration: Duplicate key viewToggleSideBar - formatClearFormat

All 3 comments

Thank you for taking the time to report this issue! There is an issue with the portable mode that the directory cannot be detected if the current working directory don't match the application directory.

@fxha Tested this morning with v0.15.1 The keybindings still don't respect the keybindings .json :cry:

My keybindings.json is as follows

{
  "fileNewTab": "Ctrl+T",
  "viewToggleSideBar": "Ctrl+Shift+R"
}

and it's stored in marktext-user-data. Am I doing something wrong?

@yougotwill There was another issue that is fixed now. You need to unset the default shortcut until the next release. This configuration should work for now:

{
  "fileNewTab": "Ctrl+T",
  "paragraphTable": "",
  "viewToggleSideBar": "Ctrl+Shift+R",
  "formatClearFormat": "",
  "viewDevReload": ""
}

You can verify this by launching Mark Text via command line:

$ marktext
   Invalid keybindings.json configuration: Duplicate key viewToggleSideBar - formatClearFormat
Was this page helpful?
0 / 5 - 0 ratings

Related issues

stefnotch picture stefnotch  路  4Comments

umi-neko picture umi-neko  路  4Comments

1dancook picture 1dancook  路  4Comments

fxha picture fxha  路  3Comments

acostalima picture acostalima  路  3Comments