Separate "very visible" flag from blinking flag, it should not affect

DECSCUSR. GitHub issue 2891.
This commit is contained in:
nicm
2021-10-05 12:46:02 +00:00
parent 3d5a02bf45
commit 9b1fdb291e
4 changed files with 93 additions and 96 deletions

View File

@ -163,27 +163,27 @@ screen_set_cursor_style(struct screen *s, u_int style)
break;
case 1:
s->cstyle = SCREEN_CURSOR_BLOCK;
s->mode |= MODE_BLINKING;
s->mode |= MODE_CURSOR_BLINKING;
break;
case 2:
s->cstyle = SCREEN_CURSOR_BLOCK;
s->mode &= ~MODE_BLINKING;
s->mode &= ~MODE_CURSOR_BLINKING;
break;
case 3:
s->cstyle = SCREEN_CURSOR_UNDERLINE;
s->mode |= MODE_BLINKING;
s->mode |= MODE_CURSOR_BLINKING;
break;
case 4:
s->cstyle = SCREEN_CURSOR_UNDERLINE;
s->mode &= ~MODE_BLINKING;
s->mode &= ~MODE_CURSOR_BLINKING;
break;
case 5:
s->cstyle = SCREEN_CURSOR_BAR;
s->mode |= MODE_BLINKING;
s->mode |= MODE_CURSOR_BLINKING;
break;
case 6:
s->cstyle = SCREEN_CURSOR_BAR;
s->mode &= ~MODE_BLINKING;
s->mode &= ~MODE_CURSOR_BLINKING;
break;
}
}
@ -680,8 +680,10 @@ screen_mode_to_string(int mode)
strlcat(tmp, "MOUSE_STANDARD,", sizeof tmp);
if (mode & MODE_MOUSE_BUTTON)
strlcat(tmp, "MOUSE_BUTTON,", sizeof tmp);
if (mode & MODE_BLINKING)
strlcat(tmp, "BLINKING,", sizeof tmp);
if (mode & MODE_CURSOR_BLINKING)
strlcat(tmp, "CURSOR_BLINKING,", sizeof tmp);
if (mode & MODE_CURSOR_VERY_VISIBLE)
strlcat(tmp, "CURSOR_VERY_VISIBLE,", sizeof tmp);
if (mode & MODE_MOUSE_UTF8)
strlcat(tmp, "UTF8,", sizeof tmp);
if (mode & MODE_MOUSE_SGR)