summaryrefslogtreecommitdiff
path: root/lisp/calendar/solar.el
diff options
context:
space:
mode:
authorJim Blandy <jimb@redhat.com>1992-08-19 03:54:46 +0000
committerJim Blandy <jimb@redhat.com>1992-08-19 03:54:46 +0000
commitfbfed6f05fdf5bf363ca5691aefde4d573ce8203 (patch)
tree726c22e6a55cb3e760a25f6aa60580d76c8de253 /lisp/calendar/solar.el
parent4d4c4e027fe376759227a6fb6b31a88be6e36347 (diff)
downloademacs-fbfed6f05fdf5bf363ca5691aefde4d573ce8203.tar.gz
entered into RCS
Diffstat (limited to 'lisp/calendar/solar.el')
-rw-r--r--lisp/calendar/solar.el46
1 files changed, 23 insertions, 23 deletions
diff --git a/lisp/calendar/solar.el b/lisp/calendar/solar.el
index 6a6956ad81d..84b9dfe6ffb 100644
--- a/lisp/calendar/solar.el
+++ b/lisp/calendar/solar.el
@@ -328,40 +328,40 @@ latitude, time zone, and date.
This function is suitable for execution in a .emacs file."
(interactive "p")
- (if (< arg 16)
- (if (not (and calendar-latitude calendar-longitude calendar-time-zone))
- (solar-setup)))
+ (if (and (< arg 16)
+ (not (and calendar-latitude calendar-longitude calendar-time-zone)))
+ (solar-setup))
(let* ((calendar-longitude
- (if (< arg 16)
- calendar-longitude
+ (if (< arg 16) calendar-longitude
(solar-get-number
"Enter longitude (decimal fraction; + east, - west): ")))
(calendar-latitude
- (if (< arg 16)
- calendar-latitude
+ (if (< arg 16) calendar-latitude
(solar-get-number
"Enter latitude (decimal fraction; + north, - south): ")))
(calendar-time-zone
- (if (< arg 16)
- calendar-time-zone
+ (if (< arg 16) calendar-time-zone
(solar-get-number
"Enter difference from Universal Time (in minutes): ")))
(calendar-location-name
- (let ((float-output-format "%.1f"))
- (format "%s%s, %s%s"
- (abs calendar-latitude)
- (if (> calendar-latitude 0) "N" "S")
- (abs calendar-longitude)
- (if (> calendar-longitude 0) "E" "W"))))
+ (if (< arg 16) calendar-location-name
+ (let ((float-output-format "%.1f"))
+ (format "%s%s, %s%s"
+ (abs calendar-latitude)
+ (if (> calendar-latitude 0) "N" "S")
+ (abs calendar-longitude)
+ (if (> calendar-longitude 0) "E" "W")))))
(calendar-standard-time-zone-name
- (cond ((= calendar-time-zone 0) "UT")
- ((< calendar-time-zone 0) (format "UT%dmin" calendar-time-zone))
- (t (format "UT+%dmin" calendar-time-zone))))
- (calendar-daylight-savings-starts nil)
- (calendar-daylight-savings-ends nil)
- (date (if (< arg 4)
- (calendar-current-date)
- (calendar-read-date)))
+ (if (< arg 16) calendar-standard-time-zone-name
+ (cond ((= calendar-time-zone 0) "UT")
+ ((< calendar-time-zone 0)
+ (format "UT%dmin" calendar-time-zone))
+ (t (format "UT+%dmin" calendar-time-zone)))))
+ (calendar-daylight-savings-starts
+ (if (< arg 16) calendar-daylight-savings-starts))
+ (calendar-daylight-savings-ends
+ (if (< arg 16) calendar-daylight-savings-ends))
+ (date (if (< arg 4) (calendar-current-date) (calendar-read-date)))
(date-string (calendar-date-string date t))
(time-string (solar-sunrise-sunset date))
(msg (format "%s: %s" date-string time-string))