How to enable Cyrillic support? A little tired every time to switch the layout for command mode.

  • It seems to me that these are 2 different questions - about the Cyrillic alphabet and about the quotation marks - and they should be arranged separately. - Michael Radionov
  • Divided, with vim I figured it out, it would be - B.Yakushev
  • @ B.Yakushev, if you understand, please state the results in the form of an answer to a question. - aleksandr barakin
  • @alexander barakin alas, but I never found the answer to my question - B.Yakushev

1 answer 1

The solution is to assign the same commands to the Cyrillic letters and symbols of the Russian layout as the characters from the English, located next to them on the same key - the same as q , ц - w and so on.

If it was

 { "keys": ["q", "<character>"], "command": "vi_begin_record_macro", "context": [{"key": "setting.command_mode"}] }, 

we have to add hotkeys to the file:

 { "keys": ["й", "<character>"], "command": "vi_begin_record_macro", "context": [{"key": "setting.command_mode"}] }, 

In order not to waste time on self-editing for each key, there is a code where everything is done for us. PreferencesKey Bindings - User → paste this text into the opened file (just in case an archive copy ) → save.

If you have already assigned any custom hotkeys in this file, remove the extra [square brackets], for example:

It was:

 [ { "keys": ["alt+home"], "command": "sublimeserver_browser" }, { "keys" : ["ctrl+shift+,"], "command" : "open_dir", "args" : {"dir" : "$file_path"} }, ] 

It became:

 [ { "keys": ["alt+home"], "command": "sublimeserver_browser" }, { "keys" : ["ctrl+shift+,"], "command" : "open_dir", "args" : {"dir" : "$file_path"} }, { "keys": ["escape"], "command": "exit_insert_mode", "context": [ { "key": "setting.command_mode", "operand": false }, { "key": "setting.is_widget", "operand": false } ] }, <Тут остальной код без квадратных скобок в конце, так как у нас уже есть завершающая квадратная скобка> ] 

They write that it is possible to change the contents of the Default.sublime-keymap in the Vintage folder, but when updating Sublime Text 3 it can overwrite it, and your changes will be lost, why I recommend editing the file that opens after PreferencesKey Bindings - User .

Demonstration:

Command Mode in the Russian layout

If you change the default keys for commands in the English layout, you will have to make similar corrections in Cyrillic.