←back to thread

457 points benoitg | 1 comments | | HN request time: 0.2s | source
Show context
nh2 ◴[] No.44371598[source]
With or without starship, one problem I have with zsh prompts is that when I press Enter, there is still a visible delay where for a fraction of a second, the cursor moves to the beginning of the next line.

This makes a nasty "flashing" effect.

If I keep Enter pressed, the cursor is permanently visible at offset 0 in the lowest line.

If the prompt is ultra-fast (e.g. plain root shell prompt on zsh), it happens less (e.g. only 50% of cases), but as soon as the prompt does anything, it's very visible.

I observe this with many terminals (gnome-terminal, wezterm, kitty, alacritty, xterm).

The only terminal I tried that doesn't have this problem is urxvt, where it looks perfect.

Video repro: https://nh2.me/flashing-cursors-on-newline.mp4

Why, and is there a way around it for those other terminals?

replies(2): >>44376643 #>>44377645 #
1. nh2 ◴[] No.44376643[source]
For Kitty I posted it on https://github.com/kovidgoyal/kitty/issues/8752, maybe we'll learn more!