emacs-pretest-bug
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Org mode and view-calendar-holidays-initially.


From: Matt Hodges
Subject: Org mode and view-calendar-holidays-initially.
Date: Wed, 10 May 2006 14:39:26 +0100
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux)

In GNU Emacs 22.0.50.49 (i686-pc-linux-gnu, GTK+ Version 2.8.17)
 of 2006-05-10 on escpc40
configured using `configure '--with-gtk''

With non-nil view-calendar-holidays-initially, org-schedule results in
an error.  This is reproducible with emacs -Q and:

    (load-library "org.el")
    (with-temp-buffer
      (org-mode)
      (let ((view-calendar-holidays-initially t))
        (org-schedule)))

which gives the following backtrace:

    Debugger entered--Lisp error: (void-variable displayed-month)
      calendar-cursor-to-date()
      (if (calendar-cursor-to-date) (progn (let* ... ...)))
      (when (calendar-cursor-to-date) (let* (... ...) (setq ans2 ...)))
      (let ((sw ...)) (select-window (get-buffer-window "*Calendar*")) (eval 
form) (when (calendar-cursor-to-date) (let* ... ...)) (org-move-overlay 
org-date-ovl (1- ...) (1+ ...) (current-buffer)) (select-window sw))
      org-eval-in-calendar(nil)
      (save-window-excursion (calendar) (calendar-forward-day (- ... ...)) 
(org-eval-in-calendar nil) (let* (... ... ...) (define-key map ... ...) 
(define-key map ... ...) (define-key map ... ...) (define-key 
minibuffer-local-map [...] ...) (define-key minibuffer-local-map [...] ...) 
(define-key minibuffer-local-map [...] ...) (define-key minibuffer-local-map 
[...] ...) (define-key minibuffer-local-map [...] ...) (define-key 
minibuffer-local-map [...] ...) (define-key minibuffer-local-map ">" ...) 
(define-key minibuffer-local-map "<" ...) (unwind-protect ... ...)))
      (save-excursion (save-window-excursion (calendar) (calendar-forward-day 
...) (org-eval-in-calendar nil) (let* ... ... ... ... ... ... ... ... ... ... 
... ... ...)))
      (if org-popup-calendar-for-date-prompt (save-excursion 
(save-window-excursion ... ... ... ...)) (setq ans (read-string prompt "" nil 
timestr)))
      (let* ((org-time-stamp-rounding-minutes ...) (ct ...) (default-time ...) 
(calendar-move-hook nil) (view-diary-entries-initially nil) (timestr ...) 
(prompt ...) ans ans1 ans2 second minute hour day month year tl wday wday1) (if 
org-popup-calendar-for-date-prompt (save-excursion ...) (setq ans ...)) 
(org-detatch-overlay org-date-ovl) (if (string-match "^ 
*\\(\\([0-9]+\\)-\\)?\\([0-1]?[0-9]\\)-\\([0-3]?[0-9]\\)\\([^-0-9]\\|$\\)" ans) 
(progn ... ... ...)) (setq tl (parse-time-string ans) year (or ... ...) month 
(or ... ...) day (or ... ...) hour (or ... ...) minute (or ... ...) second (or 
... 0) wday (nth 6 tl)) (when (and wday ...) (setq wday1 ...) (unless ... ...)) 
(if (and ... ...) (setq org-time-was-given t)) (if (< year 100) (setq year 
...)) (if to-time (encode-time second minute hour day month year) (if ... ... 
...)))
      org-read-date(nil to-time)
      (format-time-string (car org-time-stamp-formats) (org-read-date nil 
(quote to-time)))
      (insert org-scheduled-string " " (format-time-string (car 
org-time-stamp-formats) (org-read-date nil ...)))
      org-schedule()
      (let ((view-calendar-holidays-initially t)) (org-schedule))
      (save-current-buffer (set-buffer temp-buffer) (org-mode) (let (...) 
(org-schedule)))
      (with-current-buffer temp-buffer (org-mode) (let (...) (org-schedule)))
      (unwind-protect (with-current-buffer temp-buffer (org-mode) (let ... 
...)) (and (buffer-name temp-buffer) (kill-buffer temp-buffer)))
      (let ((temp-buffer ...)) (unwind-protect (with-current-buffer temp-buffer 
... ...) (and ... ...)))
      (with-temp-buffer (org-mode) (let (...) (org-schedule)))
      (progn (load-library "org.el") (with-temp-buffer (org-mode) (let ... 
...)))
      eval((progn (load-library "org.el") (with-temp-buffer (org-mode) (let ... 
...))))
      eval-last-sexp-1(nil)
      eval-last-sexp(nil)
      call-interactively(eval-last-sexp)

It looks like binding view-calendar-holidays-initially to nil in
org-read-date (cf. view-diary-entries-initially) may be the right fix:

Attachment: txtMhoNiffBGs.txt
Description: org.el patch.

Thanks,

Matt

reply via email to

[Prev in Thread] Current Thread [Next in Thread]