updated for version 7.0021
diff --git a/src/term.c b/src/term.c
index 71b1911..a83f506 100644
--- a/src/term.c
+++ b/src/term.c
@@ -1643,6 +1643,7 @@
{KS_CIS, "IS"}, {KS_CIE, "IE"},
{KS_TS, "ts"}, {KS_FS, "fs"},
{KS_CWP, "WP"}, {KS_CWS, "WS"},
+ {KS_CSI, "SI"}, {KS_CEI, "EI"},
{(enum SpecialKey)0, NULL}
};
@@ -3400,6 +3401,31 @@
}
/*
+ * Set cursor shape to match Insert mode.
+ */
+ void
+term_cursor_shape()
+{
+ static int showing_insert_mode = MAYBE;
+
+ if (!full_screen || *T_CSI == NUL || *T_CEI == NUL)
+ return;
+
+ if (State & INSERT)
+ {
+ if (showing_insert_mode != TRUE)
+ out_str(T_CSI); /* disable cursor */
+ showing_insert_mode = TRUE;
+ }
+ else
+ {
+ if (showing_insert_mode != FALSE)
+ out_str(T_CEI); /* disable cursor */
+ showing_insert_mode = FALSE;
+ }
+}
+
+/*
* Set scrolling region for window 'wp'.
* The region starts 'off' lines from the start of the window.
* Also set the vertical scroll region for a vertically split window. Always