Question

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:

enter image description here

Then I can change those, and all the other foo are still highlighted:

enter image description here

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 foos 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?

Was it helpful?

Solution

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.

OTHER TIPS

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.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top