Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: PATCH: zcalc prompt fix



On 08.01.2010 03:15, Richard Hartmann wrote:

What line exactly? What do you do to trigger the bug?
Can you reproduce it with zsh -f, and if not, what do you
need to do so that you can reproduce it?

I thought it would be much easier.
This is very simple bug. It occurs due to the incorrect prompt length calculations. It reproduces with zsh -f.
% zsh -f
% autoload zcalc
% ZCALCPROMPT="%F{red}%1v%f> "
% echo "$COLUMNS - `echo "${(%)ZCALCPROMPT}" | wc -c`" | bc
67
% zcalc
1> When you'll type 67'th character, prompt will disappear. It doesn't scroll to the right, but overwrites. After this you will not possible to edit beginning of the line anymore.

--
sergio.



Messages sorted by: Reverse Date, Date, Thread, Author