Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Bug in RPROMPT code?
- X-seq: zsh-workers 40206
- From: "Nikolay Aleksandrovich Pavlov (ZyX)" <kp-pav@xxxxxxxxx>
- To: Nicholas Sterling <nicholas.sterling@xxxxxxxxx>, "zsh-workers@xxxxxxx" <zsh-workers@xxxxxxx>
- Subject: Re: Bug in RPROMPT code?
- Date: Fri, 16 Dec 2016 15:07:38 +0300
- Authentication-results: mxback9o.mail.yandex.net; dkim=pass header.i=@yandex.ru
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yandex.ru; s=mail; t=1481890058; bh=di3YBHlnkNkfAybDGzwhcyB2k3S4HFXPdmMne9LNZuw=; h=From:To:In-Reply-To:References:Subject:Message-Id:Date; b=mpHgV3eiwu42R729kFvoUkShRIm9iT1exqlXQJkuy58xmCFb66vB9+COe6kAAlsCs TrN+DDQrOCDIa2uTWHuJt+YMJGfyXVehfOUjalY/LkXvrXNE+PDDNn0MUBy7MipEAI 2EDNDu5GvzG5Af72odwOl/3OJIiNtw60Ym046Unc=
- In-reply-to: <F34B158F-30CE-4633-9435-22290668900B@gmail.com>
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
- References: <F34B158F-30CE-4633-9435-22290668900B@gmail.com>
16.12.2016, 14:33, "Nicholas Sterling" <nicholas.sterling@xxxxxxxxx>:
Hi folks. Is this a bug? When I use %S%s to make the RPROMPT inverse video, zsh leaves a space at the end. Without inverse video, it is flush with the margin. Is it possible that the calculation to figure out at which column to start the RPROMPT is not taking into account that %s is non-printing?
This is obviously not critical, but I thought you would want to know.
Nicholas
RPROMPT should always be shifted by default, behaviour is controlled by $ZLE_RPROMPT_INDENT which defaults to 1.
Setting it to zero does not work well, see attached screenshot (screenshot was done in `zsh -f`). Note that on screenshot you see cursor right after `%` after zeroing ZLE_RPROMPT_INDENT, while it should be aligned with `R`, `R` and `Z`, but space is left both with and without inverse by default.
Attachment:
screenshot-2016-12-16@15:01:44:359251459.png
Description: PNG image
Messages sorted by:
Reverse Date,
Date,
Thread,
Author