Skip to content

Copy-and-paste from console no longer maintains the formatting #8400

Open

Description

@ronblum

System details

RStudio Edition : Desktop
RStudio Version : 1.3.1093 and 1.4.1032
OS Version      : Windows 10 (also Ubuntu 20 & Red Hat 8)
R Version       : 4.0.3

Steps to reproduce the problem

  1. In the console:
x <- 1
x
  1. Copy the code and output
  2. Paste in a Word document.

Describe the problem in detail

None of the paste options result in pasting the text with formatting.

  1. Paste default/option 1 (cell contents)
    image

  2. Paste option 2 (entire cell)
    image

  3. Paste option 3 (keep text only)
    image

Describe the behavior you expected

The text should be pasted with the formatting. This was the case in 1.2.5042 on Windows 10.
image

Note:

  • This used to work on Windows in 1.2, but does not in 1.3 and 1.4.

  • This isn't working in 1.4 on Ubuntu and Red Hat with LibreOffice Writer and Calc, which is resulting in an empty one-column table. In 1.2.5042, on Ubuntu 16, the paste resulted in formatted text inside a table.

  • On Mac, pasting results in unformatted text, but at least it pastes. This is true for 1.2, 1.3, and 1.4.

  • I have read the guide for submitting good bug reports.

  • I have installed the latest version of RStudio, and confirmed that the issue still persists.

  • If I am reporting a RStudio crash, I have included a diagnostics report.

  • I have done my best to include a minimal, self-contained set of instructions for consistently reproducing the issue.

Activity

  1. added this to the Later milestone on Nov 16, 2020
  2. martinrd3D commented on Dec 29, 2020

    @martinrd3D

    I also have this very annoying problem, and cannot copy/paste into body of a gmail.

    Doug Martin

  3. madsenl commented on Jan 9, 2022

    @madsenl

    I'm running into this problem too. Used to be able to copy-and-paste output into a Canvas discussion but no more. As a workaround, I've been running R outside of RStudio.

  4. kevinushey commented on Jan 10, 2022

    @kevinushey
    Collaborator

    It would be worth checking what the behavior here is with Electron.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions