Re: [PATCH] emacs: fix author field width with double-width chars

Subject: Re: [PATCH] emacs: fix author field width with double-width chars

Date: Wed, 02 Jul 2025 17:40:08 +0300

To: Yikai Zhao, notmuch@notmuchmail.org

Cc:

From: Teemu Likonen


* 2025-06-28 17:49:58+0800, Yikai Zhao wrote:

> Some non-ascii characters is double-width (e.g. CJK characters), which
> means that its `length' is not the same as `string-width' (display
> width). This commit fixes the width calculation in
> notmuch-search-insert-authors so that author field with these
> characters can be properly aligned.
> ---
>  emacs/notmuch.el | 18 +++++++++---------
>  1 file changed, 9 insertions(+), 9 deletions(-)

I wonder (but don't really know) if some display properties would be
better for aligning columns. See these Elisp pages:

https://emacsdocs.org/docs/elisp/Specified-Space
https://emacsdocs.org/docs/elisp/Pixel-Specification

-- 
/// Teemu Likonen - .-.. https://www.iki.fi/tlikonen/
// OpenPGP: 6965F03973F0D4CA22B9410F0F2CAE0E07608462
signature.asc (application/pgp-signature)
_______________________________________________
notmuch mailing list -- notmuch@notmuchmail.org
To unsubscribe send an email to notmuch-leave@notmuchmail.org

Thread: