Commit cea82f86 authored by Glenn Morris's avatar Glenn Morris
Browse files

(redraw-calendar): Work from any buffer, not just the calendar.

parent a46c339d
......@@ -2169,11 +2169,13 @@ the inserted text. Value is always t."
t)
(defun redraw-calendar ()
"Redraw the calendar display."
"Redraw the calendar display, if `calendar-buffer' is live."
(interactive)
(let ((cursor-date (calendar-cursor-to-nearest-date)))
(generate-calendar-window displayed-month displayed-year)
(calendar-cursor-to-visible-date cursor-date)))
(if (get-buffer calendar-buffer)
(with-current-buffer calendar-buffer
(let ((cursor-date (calendar-cursor-to-nearest-date)))
(generate-calendar-window displayed-month displayed-year)
(calendar-cursor-to-visible-date cursor-date)))))
(defcustom calendar-debug-sexp nil
"*Turn debugging on when evaluating a sexp in the diary or holiday list."
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment