From: Paul Eggert Date: Fri, 30 Dec 2022 03:16:09 +0000 (-0800) Subject: In cal-dst, be consistent re default to UTC X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=73769dc2b872441eb0b8565e1090e97fc0b5d521;p=emacs.git In cal-dst, be consistent re default to UTC * lisp/calendar/cal-dst.el (calendar-standard-time-zone-name) (calendar-daylight-time-zone-name): When using alphabetic time zone abbreviations, default to "UTC" rather than to "EST" or "EDT", to be consistent with the behavior when using numeric time zone abbreviations. Also, in the numeric time zone use "-0000" rather than "+0000" to show that the time zone is unknown; this is the RFC 5322 standard. --- diff --git a/lisp/calendar/cal-dst.el b/lisp/calendar/cal-dst.el index 5f601f24d24..c8a65126a49 100644 --- a/lisp/calendar/cal-dst.el +++ b/lisp/calendar/cal-dst.el @@ -354,10 +354,10 @@ If the locale never uses daylight saving time, set this to 0." (if calendar-current-time-zone-cache (format-time-string "%z" 0 (* 60 (car calendar-current-time-zone-cache))) - "+0000") - (or (nth 2 calendar-current-time-zone-cache) "EST")) + "-0000") + (or (nth 2 calendar-current-time-zone-cache) "UTC")) "Abbreviated name of standard time zone at `calendar-location-name'. -For example, \"EST\" in New York City, \"PST\" for Los Angeles." +For example, \"-0500\" or \"EST\" in New York City." :type 'string :version "28.1" :set-after '(calendar-time-zone-style) @@ -368,10 +368,10 @@ For example, \"EST\" in New York City, \"PST\" for Los Angeles." (if calendar-current-time-zone-cache (format-time-string "%z" 0 (* 60 (cadr calendar-current-time-zone-cache))) - "+0000") - (or (nth 3 calendar-current-time-zone-cache) "EDT")) + "-0000") + (or (nth 3 calendar-current-time-zone-cache) "UTC")) "Abbreviated name of daylight saving time zone at `calendar-location-name'. -For example, \"EDT\" in New York City, \"PDT\" for Los Angeles." +For example, \"-0400\" or \"EDT\" in New York City." :type 'string :version "28.1" :set-after '(calendar-time-zone-style)