dccsillag / magma-nvim

Interact with Jupyter from NeoVim.
GNU General Public License v3.0
988 stars 50 forks source link

[Feature Request] image display on remote desktop through ssh #37

Closed an9236868 closed 2 years ago

an9236868 commented 2 years ago

Is your feature request related to a problem? Please describe. I'm always frustrated when working with images in Vim, this is an awesome plugin, but I tried on a remote desktop through ssh -X or ssh -Y but the image cannot display

Describe the solution you'd like The plugin can output the display in nvim on a remote desktop

dccsillag commented 2 years ago

This is a hard thing to solve. Our plan was to primarily support images through ssh via notcurses, but that turned out to be a bit complicated.

Now, regarding displaying images with Ueberzug -- I think some of the things it does (e.g. travelling through the process tree to find the window which likely is the current terminal) just won't work remotely with ssh -X (or similar); I don't think we can have remote images with it.

So, what we can do, besides trying to finish the notcurses image display code, is to look into other ways to display images which would work through ssh.

an9236868 commented 2 years ago

thanks @dccsillag for your prompt response, cannot wait to see it :+1:

tzachar commented 2 years ago

This works for me without a problem when using Kitty as my terminal. See the Kitty image protocol magma currently supports.

@dccsillag maybe add that to the readme?

dccsillag commented 2 years ago

Yeah, I suppose the Kitty protocol backend would work through SSH.

I thought it was already in the README; apparently, it's not. Will be adding it soon!

In any case, this is a bigger issue, and just saying "use Kitty" is very unsatisfying. At least having the notcurses backend (https://github.com/dankamongmen/notcurses/issues/2308) would be better. Therefore, until we at least reach that point, I'll be keeping this issue open.

dccsillag commented 2 years ago

Since this comes down to image display without Ueberzug, I'm going to close this in favour of #15.