2

I am trying to copy/paste several lines of code, but it appears that the behavior for this has changed and I'm not sure how to correct this.

When I select multiple words (cursor on each word). Copy. Place the same number of cursors somewhere else. Paste. Instead of pasting one word with each cursor, it is pasting all words where the last cursor is located.

Versions:

  • VS Code Version: 1.39.2
  • Commit: 6ab598523be7a800d7f3eb4d92d7ab9a66069390
  • OS: Linux x64 4.15.0-65-generic (Elementary OS 5.0)

Paste Example

Is there a setting that I am unaware of? I haven't found a setting that affects this. And any search I do is a variation of this question. The answer in this question shows the desired/expected behavior.

tbriggs707
  • 79
  • 7
  • Based on what you learned in your issue regarding the java extension you should answer this question yourself with that info. – Mark Oct 22 '19 at 20:31

2 Answers2

2

When you select multiple words (cursor on each word). Copy. Place the same number of cursors somewhere else in a series (as you state in your example). Paste.

Ctrl + Shift + V

This also work is when you place the cursor on different line as well (same number of cursor as copied)

Gayan S. Muthukumarana
  • 1,182
  • 1
  • 7
  • 24
KamalHalim
  • 21
  • 1
1

I submitted a bug to VS Code and @alexandrudima helped me find the answer.

answer

Both workarounds suggested worked for me, but I also found that Ctrl+Shift+V, @KamalHalim's answer, worked as well.

tbriggs707
  • 79
  • 7