From: Jimmy Aguilar Mena Date: Mon, 14 Mar 2022 08:46:32 +0000 (+0100) Subject: Add local to remove-hook in cursor-face-highlight-mode X-Git-Tag: emacs-29.0.90~1931^2~1002^2~5 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=11bfff37ad6cced524a43d1a0f77d2b691cabddf;p=emacs.git Add local to remove-hook in cursor-face-highlight-mode Add LOCAL flag in remove-hook and reword the dock string. Thanks to Stefan Monnier for this --- diff --git a/lisp/simple.el b/lisp/simple.el index cada2e5571a..5768fb3c956 100644 --- a/lisp/simple.el +++ b/lisp/simple.el @@ -6567,13 +6567,13 @@ which is the window that will be redisplayed. When run, the `current-buffer' is set to the buffer displayed in that window.") (define-minor-mode cursor-face-highlight-mode - "When enabled the cursor-face property is respected." + "When enabled, respect the cursor-face property." :global nil (if cursor-face-highlight-mode (add-hook 'pre-redisplay-functions #'redisplay--update-cursor-face-highlight nil t) (add-hook 'pre-redisplay-functions - #'redisplay--update-cursor-face-highlight))) + #'redisplay--update-cursor-face-highlight t))) (defun redisplay--pre-redisplay-functions (windows) (with-demoted-errors "redisplay--pre-redisplay-functions: %S"