summaryrefslogtreecommitdiff
path: root/lisp/emacs-lisp
diff options
context:
space:
mode:
authorEli Zaretskii <eliz@gnu.org>2020-03-25 16:18:37 +0200
committerEli Zaretskii <eliz@gnu.org>2020-03-25 16:18:37 +0200
commit74489bdcb663722b1747f6a3f81f1f111c751f04 (patch)
treea7ac6cfff8aaf215c0ed8ced812bf0489defec11 /lisp/emacs-lisp
parentb85d29f4fd555eda34ffba5b9a6006b5758e2955 (diff)
downloademacs-74489bdcb663722b1747f6a3f81f1f111c751f04.tar.gz
emacs-74489bdcb663722b1747f6a3f81f1f111c751f04.tar.bz2
emacs-74489bdcb663722b1747f6a3f81f1f111c751f04.zip
Improve the UI of 'list-timers'
* lisp/emacs-lisp/timer-list.el (list-timers): Display both "Next" and "Repeat" in units of seconds, for consistency. (timer-list-mode): Add help-echo to column headers.
Diffstat (limited to 'lisp/emacs-lisp')
-rw-r--r--lisp/emacs-lisp/timer-list.el15
1 files changed, 13 insertions, 2 deletions
diff --git a/lisp/emacs-lisp/timer-list.el b/lisp/emacs-lisp/timer-list.el
index 4fa31f32673..4cebd739c3b 100644
--- a/lisp/emacs-lisp/timer-list.el
+++ b/lisp/emacs-lisp/timer-list.el
@@ -52,7 +52,7 @@
(let ((repeat (aref timer 4)))
(cond
((numberp repeat)
- (format "%.2f" (/ repeat 60)))
+ (format "%.1f" repeat))
((null repeat)
"-")
(t
@@ -91,7 +91,18 @@
(setq header-line-format
(concat (propertize " " 'display '(space :align-to 0))
(format "%4s %10s %8s %s"
- "Idle" "Next" "Repeat" "Function"))))
+ (propertize "Idle"
+ 'mouse-face 'highlight
+ 'help-echo "* marks idle timers")
+ (propertize "Next"
+ 'mouse-face 'highlight
+ 'help-echo "Time in sec till next invocation")
+ (propertize "Repeat"
+ 'mouse-face 'highlight
+ 'help-echo "Symbol: repeat; number: repeat interval in sec")
+ (propertize "Function"
+ 'mouse-face 'highlight
+ 'help-echo "Function called by timer")))))
(defun timer-list-cancel ()
"Cancel the timer on the line under point."