Mercurial > emacs
changeset 9767:787ae425ae22
New function to display an alternative diary file.
author | Edward M. Reingold <reingold@emr.cs.iit.edu> |
---|---|
date | Tue, 01 Nov 1994 02:18:56 +0000 |
parents | 71c37f31a02d |
children | 61b41f223695 |
files | lisp/=diary-lib.el |
diffstat | 1 files changed, 14 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/=diary-lib.el Tue Nov 01 02:17:53 1994 +0000 +++ b/lisp/=diary-lib.el Tue Nov 01 02:18:56 1994 +0000 @@ -67,16 +67,28 @@ (if (and d-file (file-exists-p d-file)) (if (file-readable-p d-file) (list-diary-entries (calendar-cursor-to-date t) arg) - (error "Your diary file is not readable!")) + (error "Diary file is not readable!")) (error "You don't have a diary file!")))) +(defun view-other-diary-entries (arg diary-file) + "Prepare and display buffer of diary entries from an alternative diary file. +Prompts for a file name and searches that file for entries that match ARG +days starting with the date indicated by the cursor position in the displayed +three-month calendar." + (interactive + (list (cond ((null current-prefix-arg) 1) + ((listp current-prefix-arg) (car current-prefix-arg)) + (t current-prefix-arg)) + (setq diary-file (read-file-name "Enter diary file name: " + default-directory nil t)))) + (view-diary-entries arg)) + (autoload 'check-calendar-holidays "holidays" "Check the list of holidays for any that occur on DATE. The value returned is a list of strings of relevant holiday descriptions. The holidays are those in the list `calendar-holidays'." t) - (autoload 'calendar-holiday-list "holidays" "Form the list of holidays that occur on dates in the calendar window. The holidays are those in the list `calendar-holidays'."