Function: org-funcall-in-calendar
org-funcall-in-calendar is a byte-compiled function defined in
org.el.gz.
Signature
(org-funcall-in-calendar FUNC &optional KEEPDATE &rest ARGS)
Documentation
Call FUNC in the calendar window and return to current window.
Unless KEEPDATE is non-nil, update org-ans2 to the cursor date.
Source Code
;; Defined in /usr/src/emacs/lisp/org/org.el.gz
(defun org-funcall-in-calendar (func &optional keepdate &rest args)
"Call FUNC in the calendar window and return to current window.
Unless KEEPDATE is non-nil, update `org-ans2' to the cursor date."
(with-selected-window (get-buffer-window calendar-buffer t)
(apply func args)
(when (and (not keepdate) (calendar-cursor-to-date))
(let* ((date (calendar-cursor-to-date))
(time (org-encode-time 0 0 0 (nth 1 date) (nth 0 date) (nth 2 date))))
(setq org-ans2 (format-time-string "%Y-%m-%d" time))))
(move-overlay org-date-ovl (1- (point)) (1+ (point)) (current-buffer))))