From 8466f73e21e0c3f849a0b7b1bb6e9f255dd99167 Mon Sep 17 00:00:00 2001 From: Bill-Gray Date: Thu, 3 Oct 2024 10:23:28 -0400 Subject: [PATCH] WinGUI display : I don't think the code that displays a preceding and trailing character is really needed to avoid stray pixel garbage. In fact, I can't see how that could possibly have ever worked. It caused some (not all) of the flickering problem described in issue #322. --- wingui/pdcdisp.c | 8 -------- 1 file changed, 8 deletions(-) diff --git a/wingui/pdcdisp.c b/wingui/pdcdisp.c index d1eb7d05..519f4b0c 100644 --- a/wingui/pdcdisp.c +++ b/wingui/pdcdisp.c @@ -393,17 +393,9 @@ static void PDC_transform_line_given_hdc( const HDC hdc, const int lineno, return; } assert( x >= 0); - if( len < SP->cols - x && (srcp[len] & A_CHARTEXT) < MAX_UNICODE) - len++; /* draw an extra char to avoid leaving garbage on screen */ assert( len <= SP->cols - x); assert( lineno < SP->lines && len > 0 && lineno >= 0); assert( (srcp[len - 1] & A_CHARTEXT) != MAX_UNICODE); - if( x && (srcp[-1] & A_CHARTEXT) < MAX_UNICODE) - { /* back up by one character to avoid */ - x--; /* leaving garbage on the screen */ - len++; - srcp--; - } if( lineno == SP->cursrow && SP->curscol >= x && SP->curscol < x + len) if( PDC_current_cursor_state( )) cursor_overwritten = TRUE;