mainThe GNU Readline library - Support: sr #110601, Backspacing over emojis causes...

 
 

sr #110601: Backspacing over emojis causes them to be half erased

Submitter:  None
Submitted:  Sat 29 Jan 2022 04:22:11 PM UTC
   
 
Category:  None Priority:  5 - Normal
Severity:  3 - Normal Status:  Works For Me
Privacy:  Public Assigned to:  None
Originator Email:  -email is unavailable- Open/Closed:  Open
Operating System:  Microsoft Windows
* Mandatory Fields

Add a New Comment Rich Markup
   

Wed 20 Apr 2022 07:43:28 PM UTC, comment #2: 

I don't use mintty, cygwin, or windows 10. This works for me using bash-5.1 on macOS (where I happen to be cutting and pasting from this bug report).

My locale is set appropriately.

Chet Ramey <chet>
Group administrator
Sat 29 Jan 2022 04:38:12 PM UTC, comment #1: 

Text stripped from original report:

🙂 Backspace x cursor-right y
with the following display
🙂 Backspace -> 🙂 highlighted
x -> x🙂, smiley highlighted
cursor-right -> x🙂, smiley highlighted (no change)
y -> x y�, � highlighted

When logging actual character output (e.g. mintty -l .log), final output is:
🙂^H^Hx🙂^H^H^[[Cy�
where ^H is a Backspace character, ^[ is an Escape character, ^[[C is the cursor-right terminal sequence, � is a 0x82 byte.

Anonymous
Sat 29 Jan 2022 04:22:11 PM UTC, original submission:  

Latest stable readline 8.1-2 called from bash 4.4.12(3) started by mintty 3.5.2-1 under Cygwin 3.3.3-1 on Windows 10.

Searching https://git.sv.gnu.org/gitweb/?p=readline.git using pickaxe  for emoji|unicode|utf, it appears from wcwidth.c that Unicode Emoji characters may be handled as single width and it is unclear to me how Emoji ZWJ sequences are handled:
https://www.unicode.org/emoji/charts/emoji-zwj-sequences.html

Reproducible test case:

https://github.com/mintty/mintty/issues/1012#issuecomment-1024930567


Anonymous

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by chet (Posted a comment)
  • -email is unavailable- added by None (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only logged-in users can vote.

     

    Follows 1 latest change.

    Date Changed by Updated Field Previous Value => Replaced by
    2022-04-20 chet StatusNone Works For Me

    Back to the top

    Powered by Savane 3.13-ee12.
    Corresponding source code