helix-editor / helix

A post-modern modal text editor.
https://helix-editor.com
Mozilla Public License 2.0
33.96k stars 2.51k forks source link

Use Synchronized Output sequences #731

Open valpackett opened 3 years ago

valpackett commented 3 years ago

Describe your feature request

To avoid any possible visual glitches like flickering, many modern terminal emulators (WezTerm, Kitty, iTerm2, foot, mintty, …) support DEC mode 2026 as described in:

https://gist.github.com/christianparpart/d8a62cc1ab659194337d73e399004036

to allow applications like text editors to mark complete frames with begin and end markers.

Helix should ensure these are used.

pickfire commented 3 years ago

I believe this is upstream library dependent, not sure if the upstream libraries support it.

kirawi commented 3 years ago

It looks like termwiz supports it, but there's no available release yet for the commits that implemented it.

kchibisov commented 2 years ago

What kind of upstream library this should go for? I can try to implement it in some way when I have time? It's not like a complicated escape sequence as a whole and more of just a marker that could be sent in a right point of time?

the-mikedavis commented 2 years ago

If it isn't already implemented in crossterm (https://github.com/crossterm-rs/crossterm) it might make a good contribution there. Currently we use crossterm for terminat manipulation. I think in the long run we want to switch to termwiz though which already supports it

kirawi commented 2 years ago

There's #1847, but it looks like it's stalled.

the-mikedavis commented 1 year ago

This was added to crossterm recently in https://github.com/crossterm-rs/crossterm/pull/756 but we will need detection (similar to #4939). I'll post a patch upstream to add the detection function

k4lizen commented 1 month ago

Any progress on this? When I move and resize my windows around in kitty I get flicker even worse than the one in this issue: https://github.com/kovidgoyal/kitty/discussions/4395

k4lizen commented 1 month ago

https://github.com/user-attachments/assets/948f135a-64ea-40e4-8bc8-270f219d5419

kirawi commented 1 month ago

Someone still needs to add detection upstream.

k4lizen commented 1 month ago

Could someone who understands more about this than me open a feature request for the detection upstream so the people working on crossterm at least know it's keeping this issue open