Mercurial > emacs
comparison lisp/calendar/calendar.el @ 93227:940127da5863
Provide calendar before requiring cal-menu.
(oriental-holidays, solar-holidays): Assume atan always bound.
(solar-holidays): Simplify holiday-sexp calls.
author | Glenn Morris <rgm@gnu.org> |
---|---|
date | Wed, 26 Mar 2008 03:13:55 +0000 |
parents | c68684b0a2d1 |
children | 58366e03a762 |
comparison
equal
deleted
inserted
replaced
93226:41e41843fac2 | 93227:940127da5863 |
---|---|
116 ;; (elisp) Eval During Compile: "Effectively `require' is | 116 ;; (elisp) Eval During Compile: "Effectively `require' is |
117 ;; automatically `eval-and-compile'" [but `load' is not] | 117 ;; automatically `eval-and-compile'" [but `load' is not] |
118 (eval-and-compile | 118 (eval-and-compile |
119 (load "cal-loaddefs" nil 'quiet)) | 119 (load "cal-loaddefs" nil 'quiet)) |
120 | 120 |
121 ;; Avoid recursive load of calendar when loading cal-menu. | |
122 (provide 'calendar) | |
121 (require 'cal-menu) | 123 (require 'cal-menu) |
122 | 124 |
123 | 125 |
124 (defgroup calendar nil | 126 (defgroup calendar nil |
125 "Calendar and time management support." | 127 "Calendar and time management support." |
712 ;;;###autoload | 714 ;;;###autoload |
713 (put 'general-holidays 'risky-local-variable t) | 715 (put 'general-holidays 'risky-local-variable t) |
714 | 716 |
715 ;;;###autoload | 717 ;;;###autoload |
716 (defcustom oriental-holidays | 718 (defcustom oriental-holidays |
717 '((if (fboundp 'atan) | 719 '((holiday-chinese-new-year)) |
718 (holiday-chinese-new-year))) | |
719 "Oriental holidays. | 720 "Oriental holidays. |
720 See the documentation for `calendar-holidays' for details." | 721 See the documentation for `calendar-holidays' for details." |
721 :type 'sexp | 722 :type 'sexp |
722 :group 'holidays) | 723 :group 'holidays) |
723 ;;;###autoload | 724 ;;;###autoload |
1006 ;;;###autoload | 1007 ;;;###autoload |
1007 (put 'bahai-holidays 'risky-local-variable t) | 1008 (put 'bahai-holidays 'risky-local-variable t) |
1008 | 1009 |
1009 ;;;###autoload | 1010 ;;;###autoload |
1010 (defcustom solar-holidays | 1011 (defcustom solar-holidays |
1011 '((if (fboundp 'atan) | 1012 '((solar-equinoxes-solstices) |
1012 (solar-equinoxes-solstices)) | 1013 (holiday-sexp calendar-daylight-savings-starts |
1013 (if (require 'cal-dst) | 1014 (format "Daylight Saving Time Begins %s" |
1014 (funcall | 1015 (solar-time-string |
1015 'holiday-sexp | 1016 (/ calendar-daylight-savings-starts-time (float 60)) |
1016 calendar-daylight-savings-starts | 1017 calendar-standard-time-zone-name))) |
1017 '(format "Daylight Saving Time Begins %s" | 1018 (holiday-sexp calendar-daylight-savings-ends |
1018 (if (fboundp 'atan) | 1019 (format "Daylight Saving Time Ends %s" |
1019 (solar-time-string | 1020 (solar-time-string |
1020 (/ calendar-daylight-savings-starts-time (float 60)) | 1021 (/ calendar-daylight-savings-ends-time (float 60)) |
1021 calendar-standard-time-zone-name) | 1022 calendar-daylight-time-zone-name)))) |
1022 "")))) | |
1023 (funcall | |
1024 'holiday-sexp | |
1025 calendar-daylight-savings-ends | |
1026 '(format "Daylight Saving Time Ends %s" | |
1027 (if (fboundp 'atan) | |
1028 (solar-time-string | |
1029 (/ calendar-daylight-savings-ends-time (float 60)) | |
1030 calendar-daylight-time-zone-name) | |
1031 "")))) | |
1032 "Sun-related holidays. | 1023 "Sun-related holidays. |
1033 See the documentation for `calendar-holidays' for details." | 1024 See the documentation for `calendar-holidays' for details." |
1034 :type 'sexp | 1025 :type 'sexp |
1035 :group 'holidays) | 1026 :group 'holidays) |
1036 ;;;###autoload | 1027 ;;;###autoload |