Sublime Forum

Shrotcut Crtl+/ is not working

#1

Hi There,
I’m having trouble with the toggle comment shortcut key Crtl+/, it is not working… Someone can help me?
OS: Linux Manjaro (gnome)
Keyboard: portuguese
Thank’s.

0 Likes

#2

if you open the ST console (View menu -> Show Console) and type:

sublime.log_input(True)
sublime.log_commands(True)

and then press Ctrl+/, what is the output?

0 Likes

#3

sublime.log_input(True)
key evt: control+v

sublime.log_commands(True)

key evt: control+keypad_divide

0 Likes

#4

by default ST only binds this command to ctrl + the normal / key, not the one on the keypad. (I’m not sure what a Portuguese keyboard layout looks like, but ST is detecting that the / being pressed is on the keypad). To get this working, you can add the following keybinding (Preferences menu -> Keybindings, right hand pane):

{ "keys": ["ctrl+keypad_divide"], "command": "toggle_comment", "args": { "block": false } },
{ "keys": ["ctrl+shift+keypad_divide"], "command": "toggle_comment", "args": { "block": true } },
0 Likes

#5

Thank’s very much, working perfectly now…

0 Likes