From cef76fcd2fb1a2dbb9093209ce4fda0a025f7e64 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Gerd=20M=C3=B6llmann?= Date: Sun, 16 Feb 2025 17:27:58 +0100 Subject: [PATCH] Hide cursor based on tty frame's `cursor-type' * src/dispnew.c (terminal_cursor_magic): if selected-frame has `(cursor-type . nil)' parameter. (cherry picked from commit a51cfbbd15889ce2af59b0b1bffac8735f70f6b9) --- src/dispnew.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/dispnew.c b/src/dispnew.c index 49957e98c4f..349a415ebf9 100644 --- a/src/dispnew.c +++ b/src/dispnew.c @@ -3966,6 +3966,14 @@ terminal_cursor_magic (struct frame *root, struct frame *topmost_child) tty_hide_cursor (FRAME_TTY (root)); } } + + /* Hide cursor if selected frame has (cursor-type . nil). */ + { + struct frame *sf = SELECTED_FRAME (); + Lisp_Object cursor = assq_no_quit (Qcursor_type, sf->param_alist); + if (CONSP (cursor) && NILP (XCDR (cursor))) + tty_hide_cursor (FRAME_TTY (root)); + } } void -- 2.39.5