Sublime Forum

ST3: Undo Multiple Selection

#1

sublimetext.com/docs/3/mult … board.html

and

sublime-text-unofficial-document … iting.html

state that ctrl+u deselects the last item from the multiple selection regions however when I have selected multiple regions with ctrl+d and gone one too far hitting ctrl+u does not deselect the last region on Windows.

My “Default (Windows).sublime-keymap – Default” file has:

{ "keys": "ctrl+u"], "command": "soft_undo" },

and

{ "keys": "ctrl+k", "ctrl+u"], "command": "upper_case" },

Also skipping the current instance with ctrl+k does not skip it but opens and closes the sidebar.

My “Default (Windows).sublime-keymap – User” has :

{ "keys": "ctrl+k"], "command": "toggle_side_bar" },

so that is possibly the reason for opening and close the sidebar?

How do I get to skip and undo selections from selected multiple regions on Windows please?

Kind Regards

0 Likes

#2

[quote=“LoveBoat”]My “Default (Windows).sublime-keymap – User” has :
{ “keys”: “ctrl+k”], “command”: “toggle_side_bar” },[/quote]

Remap this keybinding to another one, ctrl+k is used a lot for sequence of keybinding, and it doesn’t works well if used as a standalone keybinding.

It must works.
Open the console and type:

>>> sublime.log_commands(True)

Hit the ctrl+u keys and check that the console display:

command: soft_undo
0 Likes

#3

Thank you for letting me know about Sublime Log. Where can I read more about this please?

Regarding the issue I did enable

sublime.log_commands(True)

and pressing

ctrl+u

gives me

command: run_emmet_action {"action": "update_image_size"}

since I have Emmet installed.

Now when I go to “Default (Windows).sublime-keymap – Default” and simply copy and paste the key binding for selection regions undo to “Default (Windows).sublime-keymap – User”, this being,

{ "keys": "ctrl+u"], "command": "soft_undo" },

it works.

Does this mean I have to override all the defaults from “Default (Windows).sublime-keymap – Default” in the “Default (Windows).sublime-keymap – User” file if I want the defaults to work?

0 Likes

#4

No, just defaults that are overridden by packages.
User overrides packages which override defaults.

0 Likes