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

ZLE got wrong prompt line size, resulting redisplay eats lines when called



Step to reproduce:

1. Run zsh in clean mode
```
zsh -d -f -i
```

2. Set PROMPT, fill line with dash, then carriage return, fill line
with dash again
```
PROMPT="${(pl:${COLUMNS}::-:)}$terminfo[cr]\
${(pl:${COLUMNS}::-:)}$terminfo[cr]\

%# "
```

By using this PROMPT, we filled the first line of the PROMPT with
dashes twice, it takes only a single line.
But it seems that ZLE doesn't understand carriage return, it considers
that the PROMPT takes multiple lines.

3. Bind ctrl-X to redisplay
```
bindkey "^X" redisplay
```

4. By pressing ctrl-x, one will experience the bug, that PROMPT is
eating lines from previous command outputs.




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