aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lisp/ChangeLog4
-rw-r--r--lisp/calendar/solar.el22
2 files changed, 11 insertions, 15 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index b04319891fd..dc62555a471 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,5 +1,9 @@
12015-02-20 Glenn Morris <rgm@gnu.org> 12015-02-20 Glenn Morris <rgm@gnu.org>
2 2
3 * calendar/solar.el (solar-sunrise-sunset-string):
4 Shorten message a little.
5 (sunrise-sunset): Use message rather than a window. (Bug#19859)
6
3 * progmodes/f90.el (f90-keywords-re, f90-procedures-re) 7 * progmodes/f90.el (f90-keywords-re, f90-procedures-re)
4 (f90-font-lock-keywords-2): Some F2008 additions. 8 (f90-font-lock-keywords-2): Some F2008 additions.
5 9
diff --git a/lisp/calendar/solar.el b/lisp/calendar/solar.el
index 46cd8d3eb6d..25a24eeffeb 100644
--- a/lisp/calendar/solar.el
+++ b/lisp/calendar/solar.el
@@ -657,7 +657,7 @@ Corresponding value is nil if there is no sunrise/sunset."
657Optional NOLOCATION non-nil means do not print the location." 657Optional NOLOCATION non-nil means do not print the location."
658 (let ((l (solar-sunrise-sunset date))) 658 (let ((l (solar-sunrise-sunset date)))
659 (format 659 (format
660 "%s, %s%s (%s hours daylight)" 660 "%s, %s%s (%s hrs daylight)"
661 (if (car l) 661 (if (car l)
662 (concat "Sunrise " (apply 'solar-time-string (car l))) 662 (concat "Sunrise " (apply 'solar-time-string (car l)))
663 "No sunrise") 663 "No sunrise")
@@ -847,20 +847,12 @@ This function is suitable for execution in an init file."
847 (date (if (< arg 4) (calendar-current-date) (calendar-read-date))) 847 (date (if (< arg 4) (calendar-current-date) (calendar-read-date)))
848 (date-string (calendar-date-string date t)) 848 (date-string (calendar-date-string date t))
849 (time-string (solar-sunrise-sunset-string date)) 849 (time-string (solar-sunrise-sunset-string date))
850 (msg (format "%s: %s" date-string time-string)) 850 (msg (format "%s%s"
851 (one-window (one-window-p t))) 851 (if (< arg 4) "" ; don't print date if it's today's
852 (if (<= (length msg) (frame-width)) 852 (format "%s: " date-string))
853 (message "%s" msg) 853 time-string)))
854 (with-output-to-temp-buffer "*temp*" 854 (message "%s" msg)
855 (princ (concat date-string "\n" time-string))) 855 msg))
856 (message "%s"
857 (substitute-command-keys
858 (if one-window
859 (if pop-up-windows
860 "Type \\[delete-other-windows] to remove temp window."
861 "Type \\[switch-to-buffer] RET to remove temp window.")
862 "Type \\[switch-to-buffer-other-window] RET to restore old \
863contents of temp window."))))))
864 856
865;;;###cal-autoload 857;;;###cal-autoload
866(defun calendar-sunrise-sunset (&optional event) 858(defun calendar-sunrise-sunset (&optional event)