Sublime Forum

How to select previous line (MacOS)?

#1

From Apple’s docs, there are very useful cursor manipulation shortcuts, such as Control-N (Move down one line) and Control-A (Move to the beginning of the line or paragraph).

Even better, when you hold down shift during these shortcuts, the text in between the old and new cursor positions is selected. For example, if cursor is currently at the end of line, and I press SHIFT-CONTROL-A, I will select everything in that line, and the cursor is also moved to the beginning of that line.

This works in all text editors like Atom and Apple’s TextEdit. However, SHIFT-CONTROL-P, even after unbinding the default "show_scope_name". This is frustrating because the other ones, e.g., SHIFT-CONTROL-A all work. Only the P one does not.

If it helps, another keyboard combo that does the same thing is SHIFT+UP.

My frustrations are exactly the ones in this unanswered forum post: Select previous line (expand_selection backwards). As that post states, there is a similar keymap: { "keys": ["ctrl+shift+p"], "command": "expand_selection", "args": {"to": "line"} } . However, adding the arg "forward":false doesn’t make this text selection move backwards.

How can I move the cursor to previous line while selecting the text along the way? Is there a plugin I can install or some other way to modify the bindings that I don’t know about?

Please help, thank you!

0 Likes