From 99ecc264f798c2fa524f83f5e4b919a4fccf175f Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Thu, 10 Feb 2022 19:30:37 +0100 Subject: [PATCH] fix(tty): xterm-set-window-title in GUI emacs This was fixed in Emacs 28.0.91, but the advice will remain for 27 users. At least until we drop support for it. Fix: #4977 Ref: emacs-mirror/emacs@89d02841ab8a --- modules/os/tty/config.el | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/modules/os/tty/config.el b/modules/os/tty/config.el index 36d66898f..633ac483d 100644 --- a/modules/os/tty/config.el +++ b/modules/os/tty/config.el @@ -3,9 +3,10 @@ ;; Keep window title up-to-date; should fail gracefully in non-xterm terminals. ;; Only works in Emacs 27+. (setq xterm-set-window-title t) +;; DEPRECATED Not needed on Emacs 28+. Remove when dropping 27 support. (defadvice! +tty--only-set-window-title-in-tty-a (&optional terminal) "`xterm-set-window-title' fails in GUI Emacs. Stop that. Get some help." - :before-until #'xterm-set-window-title + :before-while #'xterm-set-window-title (not (display-graphic-p terminal))) ;; Some terminals offer two different cursors: a "visible" static cursor and a