zsh-users / zsh-syntax-highlighting

Fish shell like syntax highlighting for Zsh.
github.com/zsh-users/zsh-syntax-highlighting
BSD 3-Clause "New" or "Revised" License
20k stars 1.33k forks source link

zsh-syntax-highlighting leaving residual on vscode terminal #879

Closed thienbao12a2 closed 2 years ago

thienbao12a2 commented 2 years ago

I am having an issue with zsh-syntax-highlighting when using zsh on vscode. I am on window, and managed to install oh-my-zsh on git bash, and i use it in vscode. However, syntax-highliting will leave small colored pixels on the terminal when I clear the terminal. Looks like these pixels are residual of the content on the terminal that I clear. Could you please help? image

danielshahaf commented 2 years ago

I'm not sure we can, actually. It looks like the "clear screen" functionality does run, but doesn't do its job correctly. That means the issue is with the terminal emulator, not with z-sy-h or zsh. (Their bucks stop where the command to clear the screen was delivered from zsh to the terminal.)

You should be able to reproduce this without z-sy-h just by pressing Ctrl+L in zsh -f… but then again, you should be able to produce this simply by running clear or tput clear in any shell.

thienbao12a2 commented 2 years ago

I'm not sure we can, actually. It looks like the "clear screen" functionality does run, but doesn't do its job correctly. That means the issue is with the terminal emulator, not with z-sy-h or zsh. (Their bucks stop where the command to clear the screen was delivered from zsh to the terminal.)

You should be able to reproduce this without z-sy-h just by pressing Ctrl+L in zsh -f… but then again, you should be able to produce this simply by running clear or tput clear in any shell.

Thank you, it is weird but the issue seems to be fixed by itself after like 12 hours or so.