]> granicus.if.org Git - neomutt/commitdiff
Fix display of backspace sequences. From EGE.
authorThomas Roessler <roessler@does-not-exist.org>
Wed, 30 Aug 2000 21:34:42 +0000 (21:34 +0000)
committerThomas Roessler <roessler@does-not-exist.org>
Wed, 30 Aug 2000 21:34:42 +0000 (21:34 +0000)
pager.c

diff --git a/pager.c b/pager.c
index af3f3e653fba85141c41971e46cba687a229ec63..eb4d9b56a82ce5c8a52f93940e4fb13a569f102a 100644 (file)
--- a/pager.c
+++ b/pager.c
@@ -976,7 +976,7 @@ static int format_line (struct line_t **lineInfo, int n, unsigned char *buf,
 {
   int space = -1; /* index of the last space or TAB */
   int col = option (OPTMARKERS) ? (*lineInfo)[n].continuation : 0;
-  int ch, vch, k, special = 0, t;
+  int ch, vch, k, last_special = -1, special = 0, t;
   wchar_t wc;
   mbstate_t mbstate;
 
@@ -1043,9 +1043,12 @@ static int format_line (struct line_t **lineInfo, int n, unsigned char *buf,
     }
 
     if (pa &&
-       ((flags & (M_SHOWCOLOR | M_SEARCH | M_PAGER_MARKER)) || special
-        || pa->attr))
+       ((flags & (M_SHOWCOLOR | M_SEARCH | M_PAGER_MARKER)) ||
+        special || last_special || pa->attr))
+    {
       resolve_color (*lineInfo, n, vch, flags, special, pa);
+      last_special = special;
+    }
 
     if (IsWPrint (wc))
     {