Skip to content

workaround for tmux sixel bug#2600

Draft
valoq wants to merge 2 commits into
gokcehan:masterfrom
valoq:tmux-workaround
Draft

workaround for tmux sixel bug#2600
valoq wants to merge 2 commits into
gokcehan:masterfrom
valoq:tmux-workaround

Conversation

@valoq

@valoq valoq commented May 27, 2026

Copy link
Copy Markdown
Contributor

Adds a workaround for #2581

Since the bug in tmux does not seem to be fixed soon, this may be needed to support sixel in tmux

@veltza

veltza commented May 27, 2026

Copy link
Copy Markdown
Contributor

Depending on the terminal emulator and image size, this will cause more or less flickering in tmux. However, I don't think we can do much better if we want to release a new version soon.

I haven't tested this extensively outside tmux yet. It seems fine so far, but should we still gate this behind if os.Getenv("TMUX") != "" { ... } to avoid potential side effects elsewhere?

@valoq

valoq commented May 27, 2026

Copy link
Copy Markdown
Contributor Author

fyi, I dont get any flicker in tmux at all which means I cant find and fix the issue

@veltza

veltza commented May 28, 2026

Copy link
Copy Markdown
Contributor

fyi, I dont get any flicker in tmux at all which means I cant find and fix the issue

That's interesting. What setup are you using?

I've tested this with Chafa in both WezTerm and Foot, and the behavior is the same in both terminals. When browsing cached images, it still feels like they're being loaded from disk each time. As a result, preloading doesn't make browsing feel as smooth as it does outside of tmux.

@valoq

valoq commented May 28, 2026

Copy link
Copy Markdown
Contributor Author

fyi, I dont get any flicker in tmux at all which means I cant find and fix the issue

That's interesting. What setup are you using?

I've tested this with Chafa in both WezTerm and Foot, and the behavior is the same in both terminals. When browsing cached images, it still feels like they're being loaded from disk each time. As a result, preloading doesn't make browsing feel as smooth as it does outside of tmux.

I tested this with chafa and foot, running on sway/arch
Never noticed a single flicker.

Can you test with this preview script please? It may be related to that
preview-sixel.sh

@veltza

veltza commented May 29, 2026

Copy link
Copy Markdown
Contributor

Your preview script behaves the same as mine. Are you using a sync setting or passthrough mode in your tmux.conf? I can't get rid of the flickering on my end.

@valoq

valoq commented May 30, 2026

Copy link
Copy Markdown
Contributor Author

Im using the default tmux config, no changes.

What terminals did work for you and which ones had flicker?

@valoq

valoq commented Jun 4, 2026

Copy link
Copy Markdown
Contributor Author

@joelim-work Im not sure about adding this to the next release. I opened this PR to have a workaround for tmux users but maybe shipping without this is better. At this point I just think we should make a release in the coming days.

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.

2 participants