Skip to content

feat: iterm2 inline image protocol support#87

Open
NSPC911 wants to merge 2 commits into
lnqs:mainfrom
NSPC911-forks:it2-iip
Open

feat: iterm2 inline image protocol support#87
NSPC911 wants to merge 2 commits into
lnqs:mainfrom
NSPC911-forks:it2-iip

Conversation

@NSPC911

@NSPC911 NSPC911 commented Feb 28, 2026

Copy link
Copy Markdown

very very questionable, still very much wip, mostly just a proof of concept, but still has the same issues as sixel, if not more (#86 also occurs)

resolves #68

@lnqs

lnqs commented Apr 2, 2026

Copy link
Copy Markdown
Owner

Hey, sorry for the late response. I'd be happy to merge iterm2 support, but I also can't test it as I don't have access to a mac.
After reading through code it looks fine to me, even though it could probably make sense to refactor some of the functionality shared between Sixel and iTerm2 to a common place.

@NSPC911

NSPC911 commented Apr 3, 2026

Copy link
Copy Markdown
Author

I don't think you need a Mac to test this, this works on Wezterm because it has iTerm2 Inline Image Protocol, along with Rio Terminal (albeit in a less stable form)

However, I'm not able to fix issues related to Textual not properly rewriting the borders on the bottom, leading to issues quite similar to Sixel, or even worse.

@lnqs

lnqs commented Apr 4, 2026

Copy link
Copy Markdown
Owner

I guess the basic problem is how textual-image works. It's basically bunch of hacks hooking into textual functionality to inject data. To have a cleaner and more reliable implementation, changes to textual itself would be needed.

@NSPC911

NSPC911 commented Apr 5, 2026

Copy link
Copy Markdown
Author

I was trying to vibe-code a chafa implementation NSPC911/textual-chafa, but it feels quite iffy because certain terminals just don't show anything (rio supports iT2 and sixel, but chafa displays nothing). I think it solved the border issues there, but I'll need to take a closer look as to what it actually did

However, I don't think I will be making this PR ready. Feel free to continue from my checkpoint. I may attempt to add enhanced Sixel support soon, but only time will tell.

@NSPC911

NSPC911 commented Apr 14, 2026

Copy link
Copy Markdown
Author

I don't think the artifacts can be fixed.

image

I've tried everything, it seems nearly (or really is) impossible to fix.

@NSPC911 NSPC911 marked this pull request as ready for review April 18, 2026 03:28
@lnqs

lnqs commented May 28, 2026

Copy link
Copy Markdown
Owner

As this'll probably not be continues, I'll close the PR for now.

@lnqs lnqs closed this May 28, 2026
@NSPC911

NSPC911 commented May 29, 2026

Copy link
Copy Markdown
Author

@lnqs This is working fine, why did you close it?

@NSPC911

NSPC911 commented May 29, 2026

Copy link
Copy Markdown
Author

i forgot to mention the update that i did in 8325291

@lnqs lnqs reopened this May 29, 2026
@lnqs

lnqs commented May 29, 2026

Copy link
Copy Markdown
Owner

I closed it because of this comment:

However, I don't think I will be making this PR ready

Didn't check it, so I didn't notice it works. I'll have a look at the code.

@lnqs

lnqs commented May 29, 2026

Copy link
Copy Markdown
Owner

Looks good, overall. Would you rebasing the PR (and improve on the commit messages/squashing the commits)?

@NSPC911 NSPC911 force-pushed the it2-iip branch 2 times, most recently from 472e11a to dd63f91 Compare May 29, 2026 10:48
@NSPC911

NSPC911 commented May 29, 2026

Copy link
Copy Markdown
Author

I've rebased the PR, but removed the support table for iTerm2, do you want me to add that back again?

@lnqs

lnqs commented May 29, 2026

Copy link
Copy Markdown
Owner

I think it would make sense to have it

@lnqs

lnqs commented May 29, 2026

Copy link
Copy Markdown
Owner

Did you notice the failing checks?

@NSPC911

NSPC911 commented May 30, 2026

Copy link
Copy Markdown
Author

The tests should be fixed.

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

Successfully merging this pull request may close these issues.

iTerm2 Protocol support

2 participants