shotcut给sublime添加快捷键
Sublime官方文档:http://docs.sublimetext.info/en/latest/customization/key_bindings.html
From : https://forum.sublimetext.com/t/how-to-set-shortcut-for-menu-view-word-wrap/5278/2
Hello.
I've tried to set shortcut to menu "View => word Wrap" and I've failed.
I'd like to switch between "word Wrap" * *on/off within keys **ctrl+t+w.
I've opened "Preferences => Key Bindings - User" and here is conent:
[code]{ "keys": "ctrl+t+w"], "command": "toggle wordWrap" }
]
[/code]I've saved this settings with ctrl+s
Then I've opened my txt file containing long strings and I've tried to use ctrl+t+w.
There were no effect.
What is the problem?
How can I bind chortcut ctrl+t+w to menu item **"word Wrap" **?
- I don't think you can use "t" as a modifier key. As far as I know, only "ctrl", "shift", "alt", and "meta" can be modifier keys.
2.Your command would not work anyways; "toggle wordWrap" is not a command.
- Do this (change shortcut to what you want only using accepted modifier keys; this is tested, and does work):
{ "keys": ["ctrl+shift+w"], "command": "toggle_setting", "args": {"setting": "word_wrap"}}
浙公网安备 33010602011771号