diff options
author | Edward M. Reingold <reingold@emr.cs.iit.edu> | 1995-06-02 14:44:34 +0000 |
---|---|---|
committer | Edward M. Reingold <reingold@emr.cs.iit.edu> | 1995-06-02 14:44:34 +0000 |
commit | 33ed6bbf9fda2cfea562bbb25b0526ad1d31eca5 (patch) | |
tree | d72ad3e787081cc44ffed717ae1e6d2785c19a83 /lisp/=diary-lib.el | |
parent | ecaac826eae652021b9df7cd733df98c459ba0b8 (diff) | |
download | emacs-33ed6bbf9fda2cfea562bbb25b0526ad1d31eca5.tar.gz |
New function to create (but not fill) the fancy diary buffer.
Diffstat (limited to 'lisp/=diary-lib.el')
-rw-r--r-- | lisp/=diary-lib.el | 17 |
1 files changed, 13 insertions, 4 deletions
diff --git a/lisp/=diary-lib.el b/lisp/=diary-lib.el index ccf80d44de6..a78475bc916 100644 --- a/lisp/=diary-lib.el +++ b/lisp/=diary-lib.el @@ -357,11 +357,8 @@ This function is provided for optional use as the `diary-display-hook'." (display-buffer holiday-buffer) (message "No diary entries for %s" date-string))) (save-excursion;; Prepare the fancy diary buffer. - (set-buffer (get-buffer-create fancy-diary-buffer)) + (set-buffer (make-fancy-diary-buffer)) (setq buffer-read-only nil) - (make-local-variable 'mode-line-format) - (calendar-set-mode-line "Diary Entries") - (erase-buffer) (let ((entry-list diary-entries-list) (holiday-list) (holiday-list-last-month 1) @@ -418,6 +415,18 @@ This function is provided for optional use as the `diary-display-hook'." (display-buffer fancy-diary-buffer) (message "Preparing diary...done")))) +(defun make-fancy-diary-buffer () + "Create and return the initial fancy diary buffer." + (save-excursion + (set-buffer (get-buffer-create fancy-diary-buffer)) + (setq buffer-read-only nil) + (make-local-variable 'mode-line-format) + (calendar-set-mode-line "Diary Entries") + (erase-buffer) + (set-buffer-modified-p nil) + (setq buffer-read-only t) + (get-buffer fancy-diary-buffer))) + (defun print-diary-entries () "Print a hard copy of the diary display. |