This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Created attachment 159179 [details] Shows the issue Reproduction: * copy a single word to the clipboard * Place several carets * Press CTRL-V to paste ACTUAL: the text is pasted only at one caret - see attachment-gif EXPECTED: the text is pasted at every caret Product Version: NetBeans IDE Dev (Build 201603200001) Updates: Updates available Java: 1.8.0_71; Java HotSpot(TM) 64-Bit Server VM 25.71-b15 Runtime: Java(TM) SE Runtime Environment 1.8.0_71-b15
changeset: 7c7e4598a4e4 parent: 296312:0aff84f50cb3 user: Ralph Benjamin Ruijs <ralphbenjamin@netbeans.org> date: Mon Apr 11 11:02:05 2016 +0200 summary: #258752 #258742 - install TransferHandler
Integrated into 'main-silver', will be available in build *201604120001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-silver/rev/7c7e4598a4e4 User: Ralph Benjamin Ruijs <ralphbenjamin@netbeans.org> Log: #258752 #258742 - install TransferHandler
Created attachment 159241 [details] Issues: Pasting multiple lines
(In reply to Quality Engineering from comment #2) > Integrated into 'main-silver', will be available in build *201604120001* on > http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) > > Changeset: http://hg.netbeans.org/main-silver/rev/7c7e4598a4e4 > User: Ralph Benjamin Ruijs <ralphbenjamin@netbeans.org> > Log: #258752 #258742 - install TransferHandler It works better using Product Version: NetBeans IDE Dev (Build 201604120001). But not quite correct, when multiple lines are in the clipboard. See the screencast https://netbeans.org/bugzilla/attachment.cgi?id=159241 EXPECTED: If you have multiple lines in the clipboard and you paste it to several carets, then every caret gets ONE line of the clipboard! That is the way it works in sublime and in IntellJ idea The topmost caret get the topmost line of the clipboard. The second topmost caret get the second line of the clipboard. And so one. Edge-Cases: If there are more lines (n+x) in the clipboard than carets (n), then apply only the n lines. After the paste there are still n carets. If there are less lines (n-x) in the clipboard than carets (n), then apply only the n-x lines. After the paste there are still n carets.
(In reply to markiewb from comment #4) > (In reply to Quality Engineering from comment #2) > > Integrated into 'main-silver', will be available in build *201604120001* on > > http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) > > > > Changeset: http://hg.netbeans.org/main-silver/rev/7c7e4598a4e4 > > User: Ralph Benjamin Ruijs <ralphbenjamin@netbeans.org> > > Log: #258752 #258742 - install TransferHandler > > It works better using Product Version: NetBeans IDE Dev (Build > 201604120001). > > But not quite correct, when multiple lines are in the clipboard. See the > screencast https://netbeans.org/bugzilla/attachment.cgi?id=159241 > > EXPECTED: > If you have multiple lines in the clipboard and you paste it to several > carets, then every caret gets ONE line of the clipboard! That is the way it > works in sublime and in IntellJ idea > > The topmost caret get the topmost line of the clipboard. > The second topmost caret get the second line of the clipboard. > And so one. > > Edge-Cases: > If there are more lines (n+x) in the clipboard than carets (n), then apply > only the n lines. After the paste there are still n carets. > > If there are less lines (n-x) in the clipboard than carets (n), then apply > only the n-x lines. After the paste there are still n carets. Thanks for the screencast, it shows the pasting with multiple carets from rectangular selection is not working correctly. Pasting multiple lines to multiple carets is working as intended. IMHO Paste action should work similar with one or multiple carets, place the content from the clipboard at the caret. For example, paste the following lines into the table: <span> Placeholder </span> <table> <tr> <td>|</td> </tr> <tr> <td>|</td> </tr> <tr> <td>|</td> </tr> </table> There is one exception, cutting text and then pasting should result in the original state. This also works when there are multiple carets and the side effect of this is: when you copy the lines from the example above with three carets, pasting to three carets will not duplicate the lines, but separate them by lines. If we want to be able to paste content by lines, we could add a separate paste action "Paste by Lines".
changeset: 207d228586ef user: Ralph Benjamin Ruijs <ralphbenjamin@netbeans.org> date: Fri Apr 22 09:09:18 2016 +0200 summary: #258742 - Multicaret: Pasting clipboard content at multiple carets does no t work
Integrated into 'main-silver', will be available in build *201604251813* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-silver/rev/207d228586ef User: Ralph Benjamin Ruijs <ralphbenjamin@netbeans.org> Log: #258742 - Multicaret: Pasting clipboard content at multiple carets does not work
changeset: cbd8a52d37ba user: Ralph Benjamin Ruijs <ralphbenjamin@netbeans.org> date: Thu Apr 28 19:23:03 2016 +0200 summary: #258742 - new Paste by Lines action
Integrated into 'main-silver', will be available in build *201604300002* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-silver/rev/cbd8a52d37ba User: Ralph Benjamin Ruijs <ralphbenjamin@netbeans.org> Log: #258742 - new Paste by Lines action
Integrated into 'main-silver', will be available in build *201605070002* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-silver/rev/39fd951cb1bb User: Ralph Benjamin Ruijs <ralphbenjamin@netbeans.org> Log: #258742 - new Paste by Lines action (add missing class)