Fix display of VT100 vertically-offset horizontal line characters
authorsimon <simon@cda61777-01e9-0310-a592-d414129be87e>
Sat, 16 Jul 2011 11:13:00 +0000 (11:13 +0000)
committersimon <simon@cda61777-01e9-0310-a592-d414129be87e>
Sat, 16 Jul 2011 11:13:00 +0000 (11:13 +0000)
(o,p,r,s). They are displayed in Windows by actually writing the
centred one (q) with a vertical offset, in case fonts don't have the
offset versions; this requires terminal.c to separate those characters
into distinct calls to do_text(). Unfortunately, it was only breaking
up a text-drawing call _before_ one of those characters, not after
one. Spotted by Robert de Bath.

git-svn-id: svn://svn.tartarus.org/sgt/putty@9221 cda61777-01e9-0310-a592-d414129be87e

terminal.c

index 9865355..7aa0b65 100644 (file)
@@ -5016,7 +5016,9 @@ static void do_paint(Terminal *term, Context ctx, int may_optimise)
            break_run = ((tattr ^ attr) & term->attr_mask) != 0;
 
            /* Special hack for VT100 Linedraw glyphs */
-           if (tchar >= 0x23BA && tchar <= 0x23BD)
+           if ((tchar >= 0x23BA && tchar <= 0x23BD) ||
+                (j > 0 && (newline[j-1].chr >= 0x23BA &&
+                           newline[j-1].chr <= 0x23BD)))
                break_run = TRUE;
 
            /*