0
0
mirror of https://github.com/vim/vim.git synced 2025-09-29 04:34:16 -04:00

patch 8.0.1531: cannot use 24 bit colors in MS-Windows console

Problem:    Cannot use 24 bit colors in MS-Windows console.
Solution:   Add support for vcon. (Nobuhiro Takasaki, Ken Takasaki,
            fixes #1270, fixes #2060)
This commit is contained in:
Bram Moolenaar
2018-02-22 21:07:09 +01:00
parent 19eb6658ec
commit cafafb381a
13 changed files with 710 additions and 123 deletions

View File

@@ -2177,6 +2177,25 @@ win_update(win_T *wp)
* End of loop over all window lines.
*/
#ifdef FEAT_VTP
/* Rewrite the character at the end of the screen line. */
if (use_vtp())
{
int i;
for (i = 0; i < Rows; ++i)
# ifdef FEAT_MBYTE
if (enc_utf8)
if ((*mb_off2cells)(LineOffset[i] + Columns - 2,
LineOffset[i] + screen_Columns) > 1)
screen_draw_rectangle(i, Columns - 2, 1, 2, FALSE);
else
screen_draw_rectangle(i, Columns - 1, 1, 1, FALSE);
else
# endif
screen_char(LineOffset[i] + Columns - 1, i, Columns - 1);
}
#endif
if (idx > wp->w_lines_valid)
wp->w_lines_valid = idx;