positron icon indicating copy to clipboard operation
positron copied to clipboard

Display local image files in Viewer, or otherwise support `getOption('viewer')` for images

Open jeroen opened this issue 1 year ago • 3 comments

In RStudio we can do:

library(magick)
frink <- image_read("https://jeroen.github.io/images/frink.png")
print(frink)

But this does not work positron. I think the problem is that the getOption('viewer') does not work with images, only html?

jeroen avatar Apr 25 '24 10:04 jeroen

It actually only works with HTTP urls right now, not local HTML files at all.

I'll transfer this to our regular repo for us to find how to best support images. We do have a nice way to see an image in the main area (where the source editor is):

view-image-file

We'll need to find out how to navigate existing packages that use getOption('viewer') for images and whether people really want to see these images at the same time as their source editor vs. in this area.

juliasilge avatar Apr 25 '24 15:04 juliasilge

Related to #2559

juliasilge avatar Apr 25 '24 15:04 juliasilge

Should be resolved with #4151:

image

jmcphers avatar Jul 25 '24 22:07 jmcphers

Verified Fixed

Positron Version(s) : 2024.07.0-107
OS Version          : OSX

Test scenario(s)

library(magick) frink <- image_read("https://jeroen.github.io/images/frink.png") print(frink)

Link(s) to TestRail test cases run or created: N/A

testlabauto avatar Jul 29 '24 14:07 testlabauto