]> granicus.if.org Git - neomutt/commitdiff
name unicode chars
authorRichard Russon <rich@flatcap.org>
Sat, 20 Jan 2018 02:48:41 +0000 (02:48 +0000)
committerRichard Russon <rich@flatcap.org>
Wed, 24 Jan 2018 21:30:36 +0000 (21:30 +0000)
mutt/charset.c
pager.c

index eeef3b41d3f68a072c1f0ef5b63216ade73c9e4c..5557fe31ebc8144a85d8a505c43e8338e888078d 100644 (file)
@@ -939,7 +939,7 @@ void mutt_ch_set_charset(char *charset)
   if (mutt_ch_is_utf8(buffer))
   {
     Charset_is_utf8 = true;
-    ReplacementChar = 0xfffd;
+    ReplacementChar = 0xfffd; /* replacement character */
   }
   else
   {
diff --git a/pager.c b/pager.c
index 806964e90305bba4387ede1471da16e28d8ec6c7..eed2b1e355400f74911799b6d98294f5c59d4c0f 100644 (file)
--- a/pager.c
+++ b/pager.c
@@ -1258,6 +1258,7 @@ static int format_line(struct Line **line_info, int n, unsigned char *buf, int f
 
     if (Charset_is_utf8)
     {
+      /* zero width space, zero width no-break space */
       if (wc == 0x200B || wc == 0xFEFF)
       {
         mutt_debug(3, "skip zero-width character U+%04X\n", (unsigned short) wc);
@@ -1315,10 +1316,14 @@ static int format_line(struct Line **line_info, int n, unsigned char *buf, int f
       last_special = special;
     }
 
+    /* no-break space, narrow no-break space */
     if (IsWPrint(wc) || (Charset_is_utf8 && (wc == 0x00A0 || wc == 0x202F)))
     {
       if (wc == ' ')
+      {
         space = ch;
+      }
+      /* no-break space, narrow no-break space */
       else if (Charset_is_utf8 && (wc == 0x00A0 || wc == 0x202F))
       {
         /* Convert non-breaking space to normal space. The local variable