diff --git a/st.c b/st.c index d35f134..d022494 100644 --- a/st.c +++ b/st.c @@ -1379,6 +1379,8 @@ tswapscreen(void) term.images_alt = im; #endif // SIXEL_PATCH term.mode ^= MODE_ALTSCREEN; + if (!IS_SET(MODE_ALTSCREEN)) + xsetdefaultcursor(); tfulldirt(); } diff --git a/win.h b/win.h index 3faaab9..4f161c7 100644 --- a/win.h +++ b/win.h @@ -43,6 +43,7 @@ int xsetcolorname(int, const char *); void xseticontitle(char *); void xsettitle(char *); int xsetcursor(int); +void xsetdefaultcursor(void); void xsetmode(int, unsigned int); void xsetpointermotion(int); void xsetsel(char *); diff --git a/x.c b/x.c index 39504c1..58e4974 100644 --- a/x.c +++ b/x.c @@ -2414,6 +2414,16 @@ xsetcursor(int cursor) return 0; } +void +xsetdefaultcursor(void) +{ + #if BLINKING_CURSOR_PATCH + xsetcursor(cursorstyle); + #else + xsetcursor(cursorshape); + #endif // BLINKING_CURSOR_PATCH +} + void xseturgency(int add) {