News for hackers. Stuff that matters.
Re:MapSCII – The Whole World in Your Console by kzrdude on Tuesday May 04, 2021 @07:15PM (#27044035)
I've recently been looking into terminals that can show images properly - and it's looking more widely supported and maturing than I thought. Is there anyone else also looking into the same thing?

It's promising but my main problem is that the multiplexers tmux and screen don't really support the various protocols.

There are some terminals that support images using various protocols:

- iTerm2 (Macos) - bespoke protocol

- Kitty - bespoke protocol

- Mlterm - Sixel and iTerm2 protocol

- Wezterm - iTerm2 protcol (and potentially Sixel too)

- Xterm - Sixel (but not built with it in your distro, maybe)

- Gnome-terminal/libvte terminals - Sixel - not released yet/not available to me, so unconfirmed

Using this support one can for example configure IPython to render images in the terminal inline using its mime-type hooks.

It would be great if we could slowly move terminals forward with this (even if I understand the technology is quite cumbersome to work with). Imagine having neovim, IPython or jupyter notebooks etc all available with image support in a multiplexed terminal.

Re:MapSCII – The Whole World in Your Console by dohliam on Tuesday May 04, 2021 @11:35PM (#27045888)
Given the terminals you listed above, I assume you are referring to something very specific when you say "show images properly". However, there is a lot more flexibility to use the terminal of your choice (not to mention compatibility with other programs like tmux) if you don't need pixel-perfect reproduction.

For example, I made an image browser for the terminal [0] based on Terminal Image Viewer [1] (for most image formats) and catimg [2] (for animated GIFs) that doesn't require installing a new terminal. It works great with tmux and SSH and I use it all the time for this purpose (though I didn't initially expect to find it so useful).

YMMV, but I have found that the image quality provided by TIV for example is more than sufficient for the kinds of use cases I tend to have when in a console session and needing to quickly view one or more images. Mostly that involves quickly identifying a particular image file among others in a directory, but it's so much easier to not have to leave the terminal and change contexts that it's often more convenient to reach for it for more general tasks too. Any tradeoff in quality is more than made up for in my view by the convenience of being able to use my regular terminal.

[0]: https://github.com/dohliam/console-image-browser [1]: https://github.com/stefanhaustein/TerminalImageViewer [2]: https://github.com/posva/catimg/

Re:MapSCII – The Whole World in Your Console by mendelmaleh on Wednesday May 05, 2021 @12:39AM (#27046238)
There is also dnkl/foot, a very nice wayland native terminal with sixel support.

https://codeberg.org/dnkl/foot

Re:MapSCII – The Whole World in Your Console by kzrdude on Wednesday May 05, 2021 @02:39AM (#27046869)
Thanks for the tip
Re:MapSCII – The Whole World in Your Console by themk on Tuesday May 04, 2021 @07:41PM (#27044260)
Googles hterm also supports the iTerm2 protocol. Can be good for embedding a terminal in a slideshow presentation.

If your language has a REPL with appropriate control over the display of objects you can get a pretty great experience. I used it to get familiar with Haskell's diagrams and JuicyPixel libraries and it was great[0].

[0] https://hackage.haskell.org/packages/search?terms=iterm-show

Re:MapSCII – The Whole World in Your Console by kzrdude on Wednesday May 05, 2021 @08:00AM (#27048810)
Yes, I'm looking for something that can display plots like a jupyter notebook could so the low resolution solutions don't really cut it. Maybe it's good as a fallback, though..
Re:MapSCII – The Whole World in Your Console by themk on Friday May 07, 2021 @01:55AM (#27072698)
This is using the iTerm2 protocol from the REPL. So it's high resolution. For example all the plots in this Haskell tutorial [0] can be plotted in your terminal from the REPL while you are developing and the appear as they do in the PDF.

[0] https://lancelet.github.io/space-workshop/notes.pdf

Re:MapSCII – The Whole World in Your Console by rbanffy on Tuesday May 04, 2021 @08:12PM (#27044492)
You can get 2x3 Teletext mosaics on VTE without font support. Sixel support is problematic for full-screen. You can try Tektronix graphics.
Re:MapSCII – The Whole World in Your Console by meshenna on Wednesday May 05, 2021 @07:57AM (#27048784)
Not a terminal, but might be of interest: https://github.com/dankamongmen/notcurses
Re:MapSCII – The Whole World in Your Console by kzrdude on Wednesday May 05, 2021 @07:59AM (#27048797)
Much appreciated. Thanks!