zellij-org / zellij

A terminal workspace with batteries included
https://zellij.dev
MIT License
19.38k stars 610 forks source link

fix(rendering): do not render cursor if there's nothing to render #3439

Closed imsnif closed 1 week ago

imsnif commented 1 week ago

Fixes https://github.com/zellij-org/zellij/issues/3208

This fixes an issue where we would sometimes needlessly send an instruction to render the cursor in its current coordinates, even when the output buffer was not dirty. This affected very few cases, since normally the cursor rendering is a no-op, but in programs that render heavily to the terminal (eg. nvim floating windows) this sometimes created a flicker.