GNU bug report logs -
#70000
29.2; Grapheme handling incorrect
Previous Next
Reported by: Phillip Susi <phill <at> thesusis.net>
Date: Mon, 25 Mar 2024 18:47:01 UTC
Severity: normal
Tags: notabug, wontfix
Found in version 29.2
Done: Eli Zaretskii <eliz <at> gnu.org>
Bug is archived. No further changes may be made.
Full log
Message #13 received at 70000 <at> debbugs.gnu.org (full text, mbox):
Eli Zaretskii <eliz <at> gnu.org> writes:
> Querying the cursor position won't help in this case because it is
> Emacs that moves the cursor when you type C-f, not the terminal.
I'm not talking about C-f, but simply displaying the characters on the
screen. Emacs assumes the width is 4 when it prints this character, and
so it thinks that the cursor moved over 4 places. When the terminal
actually only moves the cursor over 2 spaces, emacs gets out of sync
with the terminal, and massive breakage occurs.
By reading back the cursor position from the terminal after displaying a
grapheme cluster, it would learn how the terminal displayed it and
update its idea of where the cursor is correctly.
I originally ran into this problem not with a ZWJ, but with an emoji
followed by alternate selector 16 that someone used in a subject line of
an email, and when browsing my inbox with notmuch, the terminal went
FUBAR.
This bug report was last modified 82 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.