GNU bug report logs -
#47810
28.0.50; pulse no longer accepts a face argument
Previous Next
Reported by: Protesilaos Stavrou <info <at> protesilaos.com>
Date: Thu, 15 Apr 2021 19:36:01 UTC
Severity: normal
Tags: fixed, patch
Found in version 28.0.50
Fixed in version 28.1
Done: Lars Ingebrigtsen <larsi <at> gnus.org>
Bug is archived. No further changes may be made.
Full log
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
Dear maintainers,
I would expect the following two expressions to produce pulse effects
that differ in colour (tried with emacs -Q):
(pulse-momentary-highlight-region (point-at-bol) (point-at-eol) 'highlight)
(pulse-momentary-highlight-region (point-at-bol) (point-at-eol) 'region)
Instead they use the background of pulse-highlight-start-face. This
test confirms as much:
(set-face-background 'pulse-highlight-start-face "red")
(pulse-momentary-highlight-region (point-at-bol) (point-at-eol) 'highlight)
(set-face-background 'pulse-highlight-start-face "blue")
(pulse-momentary-highlight-region (point-at-bol) (point-at-eol) 'region)
The following diff addresses the problem with the FACE argument, but
introduces a noticeable delay to the pulse effect:
lisp/cedet/pulse.el | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lisp/cedet/pulse.el b/lisp/cedet/pulse.el
index 1e4506713a..e4733ca007 100644
--- a/lisp/cedet/pulse.el
+++ b/lisp/cedet/pulse.el
@@ -147,7 +147,7 @@ (defun pulse-momentary-highlight-overlay (o &optional face)
(add-hook 'pre-command-hook
#'pulse-momentary-unhighlight))
;; Pulse it.
- (overlay-put o 'face 'pulse-highlight-face)
+ (overlay-put o 'face (or face 'pulse-highlight-start-face))
;; The pulse function puts FACE onto 'pulse-highlight-face.
;; Thus above we put our face on the overlay, but pulse
;; with a reference face needed for the color.
I am not sure what may be causing that delay.
Thank you for your attention!
--
Protesilaos Stavrou
protesilaos.com
This bug report was last modified 4 years and 54 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.