Search code examples
sublimetextsublimetext3

ctrl+space key binding not working for commenting in Sublime Text 3


After installing Sublime Text 3 (Build 3059) I tried to configure some key bindings as I usually did in the past. So I configured this in "Preferences \ Key Bindings - User":

[
  { "keys": ["ctrl+space"], "command": "toggle_comment", "args": { "block": false } }
]

Well, this simply does not work. I can see the key binding is registered when I hover over to "Edit \ Comment \ Toggle Comment" as there is the key binding shown in grey right next to the "Toggle Comment" text. Commenting works when I click the Toggle Comment menu item, but not with the key binding.

When binding shift+space commenting works as expected. So, why won't ctrl+space do?


Solution

  • So, it had to do with ibus. I could fix it by following these steps:

    1. $ sudo apt-get install dconf-editor
    2. $ dconf-editor
    3. Go to desktop \ ibus \ general \ hotkey
    4. Change the value for triggers from ['<Control>space'] to []