Vscode stop multiline cursors to jump to start of line after last character

115 Views Asked by At

I need to edit multiple files to create fixtures in php. I start with a spreadsheet and use multicursor to insert the code in between the text, adding multiple lines when necessary to have all in one column (that my php linter removes on save).

When I get to the end of the line, some cursors, that are more advanced, restart the line again. What I would like to get :

  • To have those cursors sticking to the end of line so I can add the closing characters after a text that can have different lenghts..

There must be an option for multicursors somewhere but neither Google nor SO hasn't provided me with what I'm looking for...

I have the open source Vscodium version.

1

There are 1 best solutions below

0
On

Found it ! I'm not sure how it works without vim plugin, but with it, it works perfectly this way :

  • In edit mode, it gets to the the cursor restarts the line
  • In command mode, the cursors now stop at the end and beginning of the line.

That is pretty useful, I can now de-align the cursors when arriving at the end of a line, and straighten them up by getting at the start of the line.

Not sure if it is something basic in vscode or a nice trick, but I'll leave the answer here just in case.