Hi,
I am having problem with Ctl + Shift + D shortcut in windows; its not working in my sublime text 3.
Please help!
Hi,
I am having problem with Ctl + Shift + D shortcut in windows; its not working in my sublime text 3.
Please help!
Duplicate lines doesn’t work for selections that span across multiple lines. Does it work if you press ctrl+shift+d
with an empty selection?
Edit: sorry my mistake
It does work for multiple lines here.
It’s not working even for single line: http://prntscr.com/hj6l7p
Reinstalling Sublime Text has not effect upon a corrupted package or settings on your user files. You need to revert it to a clean state: https://www.sublimetext.com/docs/3/revert.html
If it still not working, even after reversing it to a clean state, it could mean some program on you computer is stealing the Sublime Text keystroke Ctrl+Shift+D
. You can know it by opening Sublime Text console by going on the menu View -> Show Console
. Then you can use these commands to enable/disable the logging/debugging:
sublime.log_input(True); sublime.log_commands(True); sublime.log_result_regex(True)
sublime.log_input(False); sublime.log_commands(False); sublime.log_result_regex(False)
What do you see on the Sublime Text console after enabling the debug/logging and pressing the Ctrl+Shift+D
key binding?
I am using portable Sublime Text right now, I can’t find the folder in location mentioned in that page. Please help…
I am getting this message when using in view > console
You can find that folder just by going on the menu Preferences -> Browse Packages...
From you screenshot, I see that you successfully enabled debug/log mode. Now you need to press the key bind Ctrl+Shift+D
on some code line and see what outputs on the Sublime Text console. This is what happens here:
You should be able to see that:
key evt: shift+control+d
command: duplicate_line
If you do not see it, it means there is some other application/program on your computer stealing Sublime Text keystroke Ctrl+Shift+D
. Then there nothing we can do to help. You need to find out which application is this, and kill it. Or change the duplicate line keybind to some other keystroke available.
The console shows everything but nothing happens when I hit shift+control+d
I have closed all other programs… still not happening
Can you please tell me how can I assign a new key stroke combination for the duplicate option?
But fist you need to find out some available keystroke on you keyboard. You can see the console log when you press the keystroke.
If the Sublime Text console show the keys like this:
key evt: shift+control+s
after the keystroke, it means these keys are available for use by Sublime Text. Now you can:
Preferences -> Key Bindings
[
{ "keys": ["ctrl+shift+s"], "command": "duplicate_line" },
]
It would set the duplicate line keybind to the keystroke Ctrl+Shit+S
.
You can add multiple new keybinds, just by adding new lines to the file like this:
[
{ "keys": ["ctrl+shift+s"], "command": "duplicate_line" },
{ "keys": ["ctrl+j"], "command": "join_lines" },
]
Once you save the file, the changes will take effect immediately.