Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Consider adding support for sixels? #1

Open
fragglet opened this issue Jul 25, 2023 · 2 comments
Open

Consider adding support for sixels? #1

fragglet opened this issue Jul 25, 2023 · 2 comments

Comments

@fragglet
Copy link

https://en.wikipedia.org/wiki/Sixel

@1j01
Copy link
Owner

1j01 commented Jul 25, 2023

I want this for the Thumbnail view. Sixel support is on the Textual roadmap, but I haven't explored whether it's possible to do without direct support from the framework.

For the canvas itself, it could show more detail, but the mouse position granularity would still be a cell (unless there are some other terminal protocol extensions), so it wouldn't be very useful for drawing.*

*I did have this idea which wouldn't work over SSH, but when running locally it could query for the system mouse position, and correlate it with the cell position received on the terminal, in order to track sub-cell mouse movements, but this would make it less terminal-native. Also this would be complicated by the latency between mouse movement and the terminal control codes received.

For the tool buttons, it could work quite nicely to replace the emoji with proper icons. I would make this optional, like I have with --ascii-only-icons. Other icons in the app could use this too, although I'm quite happy with what I've been able to achieve with Unicode text art (at least as it renders in Ubuntu's Terminal, which has nice geometric character rendering), and I feel like it's part of the charm. I'm also planning to allow picking between different emoji/symbols for each tool, since some cause problems on different systems (tofu, and misalignment of the row of text to the right of the character), and I already have a character picker window I could use.

@daviewales
Copy link

Not sure if this is relevant, but looking at the xterm docs for extended mouse coordinates:

SGR-Pixels (1016)
Use the same mouse response format as the 1006 control, but
report position in pixels rather than character cells.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants