changeset 5697:47563495ca14

(calendar-phases-of-moon): Fix mode line.
author Richard M. Stallman <rms@gnu.org>
date Sun, 30 Jan 1994 00:28:54 +0000
parents baab03aaf3b9
children d127e0963a2c
files lisp/calendar/lunar.el
diffstat 1 files changed, 5 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/calendar/lunar.el	Sun Jan 30 00:28:40 1994 +0000
+++ b/lisp/calendar/lunar.el	Sun Jan 30 00:28:54 1994 +0000
@@ -192,8 +192,11 @@
     (set-buffer (get-buffer-create lunar-phases-buffer))
     (setq buffer-read-only nil)
     (calendar-set-mode-line
-          (format "Phases of the moon from %s, %d to %s, %d%%-"
-                  (calendar-month-name m1) y1 (calendar-month-name m2) y2))
+     (if (= y1 y2)
+         (format "Phases of the Moon from %s to %s, %d%%-"
+                 (calendar-month-name m1) (calendar-month-name m2) y2)
+       (format "Phases of the Moon from %s, %d to %s, %d%%-"
+               (calendar-month-name m1) y1 (calendar-month-name m2) y2)))
     (erase-buffer)
     (insert
      (mapconcat