emacs-orgmode
[Top][All Lists]
Advanced

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

Re: [Orgmode] [PATCH v2] Fix agenda display for late scheduled and deadl


From: Carsten Dominik
Subject: Re: [Orgmode] [PATCH v2] Fix agenda display for late scheduled and deadline tasks
Date: Wed, 23 Jun 2010 17:26:03 +0200

Hi Bernt,

can you point me to the thread which discusses this issue?

Thanks.

- Carsten

On Jun 22, 2010, at 11:40 PM, Bernt Hansen wrote:

* lisp/org.el (org-time-string-to-absolute):

 Ignore the cyclic repeater when displaying items on today's agenda
 date.  If you have a weekly task and miss the date the agenda view
 will show more than a week late now instead of resetting on the
 cyclic repeating date.  This makes it much more obvious when you
 missed a repeating task after the repeater.
---
Here's a new version of this patch which I think addresses Matt's issue and it's simpler
which is always a bonus.

The patch is available at git://git.norang.ca/org-mode.git fix- agenda-late-tasks

-Bernt


lisp/org.el |   21 +++++++++++----------
1 files changed, 11 insertions(+), 10 deletions(-)

diff --git a/lisp/org.el b/lisp/org.el
index 2628152..4ebf31d 100644
--- a/lisp/org.el
+++ b/lisp/org.el
@@ -14700,16 +14700,17 @@ If there is a specifyer for a cyclic time stamp, get the closest date to
DAYNR.
PREFER and SHOW-ALL are passed through to `org-closest-date'.
the variable date is bound by the calendar when this is called."
-  (cond
-   ((and daynr (string-match "\\`%%\\((.*)\\)" s))
-    (if (org-diary-sexp-entry (match-string 1 s) "" date)
-       daynr
-      (+ daynr 1000)))
-   ((and daynr (string-match "\\+[0-9]+[dwmy]" s))
- (org-closest-date s (if (and (boundp 'daynr) (integerp daynr)) daynr
-                         (time-to-days (current-time))) (match-string 0 s)
-                         prefer show-all))
- (t (time-to-days (apply 'encode-time (org-parse-time-string s)))))) + (let ((today (calendar-absolute-from-gregorian (calendar-current- date))))
+    (cond
+     ((and daynr (string-match "\\`%%\\((.*)\\)" s))
+      (if (org-diary-sexp-entry (match-string 1 s) "" date)
+         daynr
+       (+ daynr 1000)))
+ ((and daynr (not (eq daynr today)) (string-match "\\+[0-9]+ [dwmy]" s)) + (org-closest-date s (if (and (boundp 'daynr) (integerp daynr)) daynr
+                                (time-to-days (current-time))) (match-string 0 
s)
+                                prefer show-all))
+ (t (time-to-days (apply 'encode-time (org-parse-time-string s)))))))

(defun org-days-to-iso-week (days)
  "Return the iso week number."
--
1.7.1.359.gd0b8d


_______________________________________________
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
address@hidden
http://lists.gnu.org/mailman/listinfo/emacs-orgmode

- Carsten






reply via email to

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