comparison src/screen.c @ 21929:771904112b47 v8.2.1514

patch 8.2.1514: multibyte vertical separator is cleared when dragging popup Commit: https://github.com/vim/vim/commit/dc0cf1db3e8e0de349e4cc5b0a7ab6c8b7dc2ebb Author: Bram Moolenaar <Bram@vim.org> Date: Sun Aug 23 15:09:36 2020 +0200 patch 8.2.1514: multibyte vertical separator is cleared when dragging popup Problem: Multibyte vertical separator is cleared when dragging a popup window using a multi-byte character for the border. Solution: Only clear the character before the window if it is double width. (closes #6766)
author Bram Moolenaar <Bram@vim.org>
date Sun, 23 Aug 2020 15:15:04 +0200
parents ebc6d07840fd
children 92a100fc5e17
comparison
equal deleted inserted replaced
21928:1e038cdaaab6 21929:771904112b47
463 #ifdef FEAT_PROP_POPUP 463 #ifdef FEAT_PROP_POPUP
464 // First char of a popup window may go on top of the right half of a 464 // First char of a popup window may go on top of the right half of a
465 // double-wide character. Clear the left half to avoid it getting the popup 465 // double-wide character. Clear the left half to avoid it getting the popup
466 // window background color. 466 // window background color.
467 if (coloff > 0 && ScreenLines[off_to] == 0 467 if (coloff > 0 && ScreenLines[off_to] == 0
468 && ScreenLinesUC[off_to - 1] != 0) 468 && ScreenLinesUC[off_to - 1] != 0
469 && (*mb_char2cells)(ScreenLinesUC[off_to - 1]) > 1)
469 { 470 {
470 ScreenLines[off_to - 1] = ' '; 471 ScreenLines[off_to - 1] = ' ';
471 ScreenLinesUC[off_to - 1] = 0; 472 ScreenLinesUC[off_to - 1] = 0;
472 screen_char(off_to - 1, row, col + coloff - 1); 473 screen_char(off_to - 1, row, col + coloff - 1);
473 } 474 }