rstudio / rstudioapi

Safely access RStudio's API (when available)
http://rstudio.github.io/rstudioapi
Other
165 stars 35 forks source link

Feature Request: Provide a mechanism to display PDF content in viewer window. #297

Open warnes opened 3 months ago

warnes commented 3 months ago

RStudio can display the PDF file generated from markdown/quarto documents in the "Viewer" window, but does not appear to provide a mechanism to do so for other PDF files.

I would like to be able display existing PDF files, or files that I have created programmatically in R, within the Rstudio "Viewer" window.

Please provide a mechanisem, perhaps vie rstudioapi::viewer() to render PDFS in the "Viewer" window.

jthomasmock commented 1 month ago

Quarto render does render and then open newly created PDFs in the RStudio Viewer, but I do see that rstudioapi::viewer() opens in the system viewer.

Are you using Quarto or RMarkdown or wanting to open arbitrary PDF files?

warnes commented 1 month ago

Are you using Quarto or RMarkdown or wanting to open arbitrary PDF files?

Yes to all three. I have legacy RMarkdown, as well as Quarto files, I also create PDFs from HTML generated from both of these, finally I have PDFs generated elsewhere that I need to view.

jlang-311 commented 3 weeks ago

@warnes thank you so much for this feature suggestion we will review this request in our future release planning to see how we could implement something like this.