[vim/vim] popup image: fix layering of overlapping images, avoid kitty retransmission on redraw (PR #20474)

3 views
Skip to first unread message

mattn

unread,
12:01 PM (10 hours ago) 12:01 PM
to vim/vim, Subscribed

Two fixes for popup window images.

Re-emitting every popup image at the end of each redraw caused two problems: a lower zindex image was painted over a higher popup's cells and image where they overlap (the walk ignored zindex), and with the kitty backend the whole image sequence was retransmitted on every redraw, making cursor movement laggy (for a 1200x1200 RGBA image that is about 7.7MB of base64 per redraw).

The end-of-redraw pass is now GUI-only; in terminal mode the zindex-ordered emit in update_popups() already produces the correct layering, and after emitting a sixel image the cells covered by a higher zindex popup are invalidated in ScreenLines so that popup rewrites them on the same walk. Kitty placements persist on the terminal and are now created with z=zindex, so while a placement is still current the retransmission is skipped entirely: with the reporter's scenario, cursor movement now sends no image data at all (placements are re-sent only after a screen clear or when the image/position actually changes).

Fixes #20460


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

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

Commit Summary

  • def3118 popup image: fix layering of overlapping images, stop kitty retransmission

File Changes

(8 files)

Patch Links:


Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!
You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/20474@github.com>

Christian Brabandt

unread,
3:33 PM (6 hours ago) 3:33 PM
to vim/vim, Subscribed
chrisbra left a comment (vim/vim#20474)

oh and please re-generate the proto files. The CI failed because of a change in the proto files


Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!

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

mattn

unread,
9:09 PM (1 hour ago) 9:09 PM
to vim/vim, Subscribed
mattn left a comment (vim/vim#20474)

Fixed in 967c5ac, all points addressed.


Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!

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

Reply all
Reply to author
Forward
0 new messages