You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This reproduces on all platforms and all versions of VSCode.
Enter three lines of text:
ABC
BCD
CDE
Use column-select to select BCD from the middle and press Ctrl+X to cut it.
place the cursor after the C on the first line and make sure to you're out of multi-cursor edit mode.
Press Ctrl+V
The end result is this:
ACB
C
D
BD
CE
The result should be this:
ACB
BDC
CED
Now, if you re-enter multi-cursor mode and select a 0x3 region on the right and then paste, it works. But this is both impractical and inconsistent with other editors.
It is impractical because for a large region of text, one can't realistically remember how many columns were selected as part of the Cut/Copy operation, and re-selecting a region of exactly the same size on the Paste is basically impossible. If you plan to paste within the same file, you might get lucky and have this work (as long as you don't click the mouse anywhere else at all before you go to the area you want to paste into), but if you want to paste into a separate editor window there's no solution here, because the editor forgets how many columns were selected as part of the original multi-cursor copy/cut operation. It also means that if I cut from VSCode and paste into another editor (or vice versa), it won't work correctly.
It is inconsistent with other editors because Visual Studio proper, Notepad++, and many other editors behave the way I've described as "expected" up above. If you do a box select and then copy or cut, then move the cursor anywhere else in the file (or another file) and paste, it behaves as expected.
It appears that VSCode is buggy on both the copy as well as the paste operations.
I determined that copy is buggy in VSCode by first selecting a rectangular area in Notepad++ and pasting it into Visual Studio (not VSCode). It behaves as expected, suggesting that this information is retained even cross-process, and that as long as clipboard data is constructed properly, Visual Studio can correctly paste data that was copied from another program. But when pasting data into VS that was originally copied from VSCode, it inserts new lines for each subsequent line of data that was copied, rather than pasting them into existing lines. So VSCode copy is not constructing the correct clipboard block
I determined that paste is buggy in VSCode by doing the converse. This time I copied from Visual Studio and pasted into VSCode, and lines were inserted. So even if the clipboard data is constructed correctly, VSCode still doesn't respect it.
The text was updated successfully, but these errors were encountered:
This reproduces on all platforms and all versions of VSCode.
The end result is this:
The result should be this:
Now, if you re-enter multi-cursor mode and select a 0x3 region on the right and then paste, it works. But this is both impractical and inconsistent with other editors.
It is impractical because for a large region of text, one can't realistically remember how many columns were selected as part of the Cut/Copy operation, and re-selecting a region of exactly the same size on the Paste is basically impossible. If you plan to paste within the same file, you might get lucky and have this work (as long as you don't click the mouse anywhere else at all before you go to the area you want to paste into), but if you want to paste into a separate editor window there's no solution here, because the editor forgets how many columns were selected as part of the original multi-cursor copy/cut operation. It also means that if I cut from VSCode and paste into another editor (or vice versa), it won't work correctly.
It is inconsistent with other editors because Visual Studio proper, Notepad++, and many other editors behave the way I've described as "expected" up above. If you do a box select and then copy or cut, then move the cursor anywhere else in the file (or another file) and paste, it behaves as expected.
It appears that VSCode is buggy on both the copy as well as the paste operations.
I determined that copy is buggy in VSCode by first selecting a rectangular area in Notepad++ and pasting it into Visual Studio (not VSCode). It behaves as expected, suggesting that this information is retained even cross-process, and that as long as clipboard data is constructed properly, Visual Studio can correctly paste data that was copied from another program. But when pasting data into VS that was originally copied from VSCode, it inserts new lines for each subsequent line of data that was copied, rather than pasting them into existing lines. So VSCode copy is not constructing the correct clipboard block
I determined that paste is buggy in VSCode by doing the converse. This time I copied from Visual Studio and pasted into VSCode, and lines were inserted. So even if the clipboard data is constructed correctly, VSCode still doesn't respect it.
The text was updated successfully, but these errors were encountered: