emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[nongnu] elpa/evil-goggles 04b93b8564 157/225: Use alternative pulse dur


From: ELPA Syncer
Subject: [nongnu] elpa/evil-goggles 04b93b8564 157/225: Use alternative pulse duration calculation
Date: Wed, 12 Jan 2022 08:59:04 -0500 (EST)

branch: elpa/evil-goggles
commit 04b93b8564177c9da6366a6db3c6daf8e03e2bcb
Author: Evgeni Kolev <evgenysw@gmail.com>
Commit: Evgeni Kolev <evgenysw@gmail.com>

    Use alternative pulse duration calculation
    
    With this change the number of iterations is kept the same (always 10)
    and the number of iterations are tweaked instead. This works better
    since pulse.el doesn't have (or use) enough color shades and runs out
    of shades by the 10th iteration.
---
 evil-goggles.el | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/evil-goggles.el b/evil-goggles.el
index 3b22f2958e..40f0dff1bc 100644
--- a/evil-goggles.el
+++ b/evil-goggles.el
@@ -100,8 +100,8 @@ can't work with input such as (backgound . \"red\")."
 
 This function returns immediately, it doesn't wait for the pulse
 animation to end."
-  (let* ((pulse-delay 0.03)
-         (pulse-iterations (round dur pulse-delay)))
+  (let* ((pulse-iterations 10)
+         (pulse-delay (/ (float dur) pulse-iterations) ))
     (ignore pulse-iterations) ;; silence compile warning Unused lexical 
variable
     (set-face-attribute 'evil-goggles--pulse-face nil :background background)
     (pulse-momentary-highlight-overlay ov 'evil-goggles--pulse-face)))



reply via email to

[Prev in Thread] Current Thread [Next in Thread]