[vim/vim] feat; add 'termsync' setting (PR #19541)

16 views
Skip to first unread message

Foxe Chen

unread,
Mar 1, 2026, 1:35:02 PM (yesterday) Mar 1
to vim/vim, Subscribed

Same as Neovim's termsync option. Surprised this wasn't already added, consdering how simple it was to implement and it reduces flickering greatly for me on my machine.

Here's a before and after comparsion:

https://github.com/user-attachments/assets/fb45ab56-b3a8-491b-b589-3c818fa6cd25


You can view, comment on, or merge this pull request online at:

  https://github.com/vim/vim/pull/19541

Commit Summary

File Changes

(10 files)

Patch Links:


Reply to this email directly, view it on GitHub.
You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/19541@github.com>

Foxe Chen

unread,
Mar 1, 2026, 1:48:01 PM (yesterday) Mar 1
to vim/vim, Push

@64-bitman pushed 1 commit.


View it on GitHub or unsubscribe.
You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/19541/before/dcdfd82a50798bb2ecafa9dda9142dc1631b076f/after/18e4c8ed01bd905fa6d724457d37566141e3b848@github.com>

Foxe Chen

unread,
Mar 1, 2026, 3:51:06 PM (yesterday) Mar 1
to vim/vim, Push

@64-bitman pushed 1 commit.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/19541/before/18e4c8ed01bd905fa6d724457d37566141e3b848/after/0e364c74a3ea5eb48b20a613d92ac984a333ba09@github.com>

Foxe Chen

unread,
Mar 1, 2026, 4:17:34 PM (yesterday) Mar 1
to vim/vim, Push

@64-bitman pushed 1 commit.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/19541/before/0e364c74a3ea5eb48b20a613d92ac984a333ba09/after/befd2f04e2be32049945e5cc4ce64569597d9253@github.com>

Foxe Chen

unread,
Mar 1, 2026, 9:56:55 PM (23 hours ago) Mar 1
to vim/vim, Push

@64-bitman pushed 1 commit.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/19541/before/befd2f04e2be32049945e5cc4ce64569597d9253/after/1401cf28920113a9a9e8f56c0b69b298446e63fb@github.com>

Foxe Chen

unread,
Mar 1, 2026, 9:58:24 PM (23 hours ago) Mar 1
to vim/vim, Push

@64-bitman pushed 1 commit.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/19541/before/1401cf28920113a9a9e8f56c0b69b298446e63fb/after/00a08c7a34aad570484249a999ad8fffb6a3234e@github.com>

Foxe Chen

unread,
Mar 1, 2026, 10:06:01 PM (23 hours ago) Mar 1
to vim/vim, Push

@64-bitman pushed 1 commit.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/19541/before/00a08c7a34aad570484249a999ad8fffb6a3234e/after/4525f76e2b897fd1b4a25d7041b00e578061e11b@github.com>

Foxe Chen

unread,
Mar 1, 2026, 10:32:02 PM (22 hours ago) Mar 1
to vim/vim, Push

@64-bitman pushed 1 commit.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/19541/before/32d75e4b1df5f4ebcbfcab8f794486552765c62a/after/3a012f8f6687e9c9416b4746f47bb8ed1ed1eefc@github.com>

Foxe Chen

unread,
Mar 1, 2026, 11:23:45 PM (21 hours ago) Mar 1
to vim/vim, Push

@64-bitman pushed 1 commit.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/19541/before/3a012f8f6687e9c9416b4746f47bb8ed1ed1eefc/after/ec005a070073b20cdc59505af505c97f60290a31@github.com>

Foxe Chen

unread,
Mar 1, 2026, 11:33:37 PM (21 hours ago) Mar 1
to vim/vim, Push

@64-bitman pushed 1 commit.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/19541/before/ec005a070073b20cdc59505af505c97f60290a31/after/f2b8654159173752c04e8b183b497e1f92e33018@github.com>

Foxe Chen

unread,
Mar 1, 2026, 11:35:24 PM (21 hours ago) Mar 1
to vim/vim, Push

@64-bitman pushed 1 commit.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/19541/before/f2b8654159173752c04e8b183b497e1f92e33018/after/56aa075fc50d62a9a831492252d453b8a521f039@github.com>

Foxe Chen

unread,
Mar 1, 2026, 11:37:07 PM (21 hours ago) Mar 1
to vim/vim, Push

@64-bitman pushed 1 commit.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/19541/before/56aa075fc50d62a9a831492252d453b8a521f039/after/798f03b4981eddb33e275f99462b09b64f19ba05@github.com>

Foxe Chen

unread,
Mar 1, 2026, 11:50:40 PM (21 hours ago) Mar 1
to vim/vim, Push

@64-bitman pushed 1 commit.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/19541/before/798f03b4981eddb33e275f99462b09b64f19ba05/after/af717ea22ee62554f8aaa11cb94c1771df0ce1d5@github.com>

Foxe Chen

unread,
Mar 1, 2026, 11:51:28 PM (21 hours ago) Mar 1
to vim/vim, Push

@64-bitman pushed 1 commit.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/19541/before/af717ea22ee62554f8aaa11cb94c1771df0ce1d5/after/417d6778dbfaa41a04c4086f386c47aedb8773d5@github.com>

Foxe Chen

unread,
12:04 AM (21 hours ago) 12:04 AM
to vim/vim, Subscribed
64-bitman left a comment (vim/vim#19541)

I found #11718 which this PR is related to, seems like bram did not get the point of something like this. However it has noticeably reduces flickering for me, so I guess there is a point.


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/19541/c3982093080@github.com>

Foxe Chen

unread,
9:09 AM (12 hours ago) 9:09 AM
to vim/vim, Push

@64-bitman pushed 1 commit.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/19541/before/417d6778dbfaa41a04c4086f386c47aedb8773d5/after/ed465388a82fc9b905b951fb278f397eb4ac8569@github.com>

Foxe Chen

unread,
9:20 AM (11 hours ago) 9:20 AM
to vim/vim, Push

@64-bitman pushed 1 commit.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/19541/before/ed465388a82fc9b905b951fb278f397eb4ac8569/after/d5895058a5708c420da20ee130c6d184a020bb16@github.com>

Foxe Chen

unread,
9:21 AM (11 hours ago) 9:21 AM
to vim/vim, Push

@64-bitman pushed 1 commit.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/19541/before/d5895058a5708c420da20ee130c6d184a020bb16/after/af7f30f4faf631610dd6e6c23b0a2b708fad4ba7@github.com>

Christian Brabandt

unread,
1:34 PM (7 hours ago) 1:34 PM
to vim/vim, Subscribed
chrisbra left a comment (vim/vim#19541)

out_str((char_u *)"\033[?2026$p");

Hm, we typically have those as t_<letter> options. Don't we need this here as well instead of hard coding this?


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/19541/c3986144665@github.com>

Javier Jaramago Fernández

unread,
3:13 PM (6 hours ago) 3:13 PM
to vim/vim, Subscribed
JavierJF left a comment (vim/vim#19541)

This PR fixes the popup flickering, but does it as a side effect of the feature, also since it only does it for terminal that supports this feature, I think that having correctness back for popups without transparencies is important. So opaque popups don't require terminals with this feature to avoid rendering issues, while popups with transparencies will require it for avoiding flickering.

Due to this, I think that even with this PR, the with changes from #19534 are still required. Said this, I think it's a great feature to have 👍 .


Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/19541/c3986670179@github.com>

Foxe Chen

unread,
3:21 PM (5 hours ago) 3:21 PM
to vim/vim, Subscribed
64-bitman left a comment (vim/vim#19541)

out_str((char_u *)"\033[?2026$p");

Hm, we typically have those as t_<letter> options. Don't we need this here as well instead of hard coding this?

Well it looks to me that all terminals that support synchronized output use this same escape sequence. However I think it is a good idea to add a t_ option for consistency


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/19541/c3986707537@github.com>

Foxe Chen

unread,
4:42 PM (4 hours ago) 4:42 PM
to vim/vim, Push

@64-bitman pushed 1 commit.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/19541/before/af7f30f4faf631610dd6e6c23b0a2b708fad4ba7/after/46281ba3f15cd3c64b6033e1a0a05be331c2f7b7@github.com>

Foxe Chen

unread,
4:45 PM (4 hours ago) 4:45 PM
to vim/vim, Push

@64-bitman pushed 1 commit.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/19541/before/46281ba3f15cd3c64b6033e1a0a05be331c2f7b7/after/41d6c3c282d9a1c301cf65b568acbce02539b7e2@github.com>

Foxe Chen

unread,
4:47 PM (4 hours ago) 4:47 PM
to vim/vim, Push

@64-bitman pushed 1 commit.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/19541/before/41d6c3c282d9a1c301cf65b568acbce02539b7e2/after/a089f841a4a4e47b29719ededd10eba85e7a3a9a@github.com>

Foxe Chen

unread,
4:50 PM (4 hours ago) 4:50 PM
to vim/vim, Subscribed
64-bitman left a comment (vim/vim#19541)

Okay I have made it so the escape codes to begin and end synchronized output are configurable by the user. I left the \033[?2026$p escape code hardcoded, because all terminals that support synchronized output use this, and it makes things simpler (esp. when detecting the response).


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/19541/c3987108917@github.com>

Reply all
Reply to author
Forward
0 new messages