Reputation: 14593
This one is hard for me to explain, I'm sorry, but I have pictures!
When I hit ctrl+d twice, it selects the first two foo
, like this:
Then I can change those, and all the other foo
are still highlighted:
But if I hit ctrl+d again now, it selects both bar
because that's where my cursors are. I'm trying to change two foo
s at a time, as efficiently as possible. How can I get the next two selected? They're still highlighted so I think there has to be a way?
Upvotes: 0
Views: 65
Reputation: 107
Simply. When u make changes to those first foo, your cursor stays at the end of first foo. Just press arrow-key down, so the cursor goes to second-line foo, than ctrl+d again -> changes -> arrow-key down -> ctrl+d and on and on..
ADDED:
When edited text goes longer, than second line's 'foo', you can always navigate to the line begining. Maybe Home button? If home is not a solution, you can always make your own keybindings, maybe, this way:
{ "keys": ["ctrl+alt+left"], "command": "move_to", "args": {"to": "bol", "extend": false} },
{ "keys": ["ctrl+alt+right"], "command": "move_to", "args": {"to": "eol", "extend": false} }
This way you will be able to get to lines begining by pressing Ctrl+alt+left.. of course u can change it - code is pretty simple.
Upvotes: 0
Reputation: 19189
I can think of two ways:
One, use F3 to "Find next" which will highlight the third foo. So, hitting Ctrl + D now will have the next two foo's selected. (⌘ + G instead of F3 for Mac users)
Option two:
Do it manually with the arrow keys, reselecting as you go.
Upvotes: 2