Sublime Text Como hacer multiples selecciones
https://www.sublimetext.com/docs/1/selection
Basics
Sublime Text works with all the standard Windows shortcuts: In addition to the arrow keys, home, end, page up, etc, there is:
- Ctrl+Left / Ctrl+Right: Move by words
- Ctrl+Home / Ctrl+End: Move to the beginning / end of the file
- Ctrl+L: Expand selection to line
Expand selection to line is quite handy, it's worth giving it a try to get a feel for it. Pressing it multiple times will extend the selection by a line at a time. Pressing Ctrl+L,Backspace will delete the current line.
Multiple Selections
Use multiple selections to edit in more that one place at once. It works as a quick substitute for find and replace, or to apply the same sequence of changes to multiple lines simultaneously.
To select multiple regions using the keyboard, select a block of text, then press Ctrl+Shift+L to split it into one selection per line.
When you're done with using multiple selections, just press Ctrl+K to trim all but the first.
Given a selected block of text, Ctrl+Shift+K will split it into two selections, one for each end.
Using the Mouse
Whether clicking, double clicking to select a word or dragging to select text, you can hold down modifier keys to work with multiple selections:
- Ctrl to add to the selection
- Alt to remove from the selection
Dragging with the middle button / mouse wheel will do a column selection. You can use Ctrl and Alt with this too. Shift+Right mouse button is an alternative way to initial a column select.
Dragging in the gutter (where the line numbers are), will select entire lines at once.
Find
Two handy ways to use find to work with the selection:
- Ctrl+F3 to find the next occurrence of the current word or selected text
- Alt+F3 to find all occurrences of the current word or selected text
Alt+F3 gives a really simple way to do find and replace: Use it to select all occurrences of the current word or selection, then just start typing to replace or edit them all at once.
No hay comentarios:
Publicar un comentario