Cannot copy-paste "\r\n" from IC within IC or anywhere else

Issue #1768 resolved
René Görgens created an issue

Hi Scott,

I’m trying to edit this line in a test class:

tAccount.BillingStreet = 'First line\r\nSecond line';

I want to copy "\r\n" to the end of the literal and append “Third line”, like so:

tAccount.BillingStreet = 'First line\r\nSecond line\r\nThird line';

However when I highlight "\r\n" and try to copy-paste it (within IC or somewhere else), nothing happens.

I can copy-paste "\r\n" outside IC fine, just not when I’m trying to copy it from IC.

Update: If I copy something else along with "\r\n" such as "\r\nThird Line", then I get:

tAccount.BillingStreet = 'First line\r\nSecond line\r\nThird line\n' +
    'Third line';

So instead of being pasted as a literal, the line break is interpreted…

I would argue that if I copy this as part of a literal, upon pasting it should not get interpreted.

Running Windows 10 v19041.630, IntelliJ v2020.2.3, IC v2.1.5.1

Obviously a minor bug, if it is one.

Kind regards,

René

Comments (6)

  1. Scott Wells repo owner

    This is the exact same behavior that occurs in the JetBrains Java editor (but interestingly, not in the native JavaScript editor). Let me follow up with them and see why this might be happening and whether it's something you can configure or a bug in the core IDE.

  2. Log in to comment