diff options
author | Glenn Morris <rgm@gnu.org> | 2008-03-29 02:42:52 +0000 |
---|---|---|
committer | Glenn Morris <rgm@gnu.org> | 2008-03-29 02:42:52 +0000 |
commit | 8743fe88edade8cbf5e9cca2dac9729c181fb75a (patch) | |
tree | f9e4994f200c73b9eaccb4523b7ddf580a047889 /lisp | |
parent | 146df8458679fd5043ce585655dadf03a5f152b2 (diff) | |
download | emacs-8743fe88edade8cbf5e9cca2dac9729c181fb75a.tar.gz |
Autoload diary-insert-entry-1.
(diary-bahai-insert-entry, diary-bahai-insert-monthly-entry)
(diary-bahai-insert-yearly-entry): Use diary-insert-entry-1.
Diffstat (limited to 'lisp')
-rw-r--r-- | lisp/calendar/cal-bahai.el | 42 |
1 files changed, 13 insertions, 29 deletions
diff --git a/lisp/calendar/cal-bahai.el b/lisp/calendar/cal-bahai.el index 25387972a91..21978cacbf4 100644 --- a/lisp/calendar/cal-bahai.el +++ b/lisp/calendar/cal-bahai.el @@ -206,7 +206,7 @@ nil if it is not visible in the current calendar window." (list displayed-month 15 displayed-year)))) (m (extract-calendar-month bahai-date)) (y (extract-calendar-year bahai-date)) - (date)) + date) (unless (< m 1) ; Bahá'í calendar doesn't apply (increment-calendar-month m y (- 10 month)) (if (> m 7) ; Bahá'í date might be visible @@ -264,20 +264,18 @@ window. See `diary-bahai-list-entries' for more information." (define-obsolete-function-alias 'mark-bahai-diary-entries 'diary-bahai-mark-entries "23.1") + +(autoload 'diary-insert-entry-1 "diary-lib") + ;;;###cal-autoload (defun diary-bahai-insert-entry (arg) "Insert a diary entry. For the Bahá'í date corresponding to the date indicated by point. Prefix argument ARG makes the entry nonmarking." (interactive "P") - (let ((calendar-month-name-array calendar-bahai-month-name-array)) - (make-diary-entry - (concat bahai-diary-entry-symbol - (calendar-date-string - (calendar-bahai-from-absolute - (calendar-absolute-from-gregorian (calendar-cursor-to-date t))) - nil t)) - arg))) + (diary-insert-entry-1 nil arg calendar-bahai-month-name-array + bahai-diary-entry-symbol + 'calendar-bahai-from-absolute)) (define-obsolete-function-alias 'insert-bahai-diary-entry 'diary-bahai-insert-entry "23.1") @@ -288,16 +286,9 @@ Prefix argument ARG makes the entry nonmarking." For the day of the Bahá'í month corresponding to the date indicated by point. Prefix argument ARG makes the entry nonmarking." (interactive "P") - (let ((calendar-date-display-form (if european-calendar-style - '(day " * ") - '("* " day ))) - (calendar-month-name-array calendar-bahai-month-name-array)) - (make-diary-entry - (concat bahai-diary-entry-symbol - (calendar-date-string - (calendar-bahai-from-absolute - (calendar-absolute-from-gregorian (calendar-cursor-to-date t))))) - arg))) + (diary-insert-entry-1 'monthly arg calendar-bahai-month-name-array + bahai-diary-entry-symbol + 'calendar-bahai-from-absolute)) (define-obsolete-function-alias 'insert-monthly-bahai-diary-entry 'diary-bahai-insert-monthly-entry "23.1") @@ -308,16 +299,9 @@ Prefix argument ARG makes the entry nonmarking." For the day of the Bahá'í year corresponding to the date indicated by point. Prefix argument ARG will make the entry nonmarking." (interactive "P") - (let ((calendar-date-display-form (if european-calendar-style - '(day " " monthname) - '(monthname " " day))) - (calendar-month-name-array calendar-bahai-month-name-array)) - (make-diary-entry - (concat bahai-diary-entry-symbol - (calendar-date-string - (calendar-bahai-from-absolute - (calendar-absolute-from-gregorian (calendar-cursor-to-date t))))) - arg))) + (diary-insert-entry-1 'yearly arg calendar-bahai-month-name-array + bahai-diary-entry-symbol + 'calendar-bahai-from-absolute)) (define-obsolete-function-alias 'insert-yearly-bahai-diary-entry 'diary-bahai-insert-yearly-entry "23.1") |