summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarsten Dominik <carsten.dominik@gmail.com>2009-02-25 13:01:28 +0100
committerCarsten Dominik <carsten.dominik@gmail.com>2009-02-25 13:01:28 +0100
commit3dba115548cf71d18ef05bd520de6b0a24cee70d (patch)
tree1fade57989f1078fe723cd0f07c43c49eab636e2
parentf44631e70fcb4f238ddf6f541ad45e74125f6a21 (diff)
downloadorg-mode-3dba115548cf71d18ef05bd520de6b0a24cee70d.tar.gz
Agenda: New option to stop searching headline for a time.
If the headline contains a time-of-day in one format or another, it will be used to sort the entry into the time sequence of items for a day. Some people have time stamps in the headline that refer to the creation time or so, and then this produces an unwanted side effect. If this is the case for your, use the new option `org-agenda-search-headline-for-time' to turn off searching the headline for a time.
-rwxr-xr-xlisp/ChangeLog3
-rw-r--r--lisp/org-agenda.el15
2 files changed, 17 insertions, 1 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 55a13c6..e257d2f 100755
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,6 +1,9 @@
2009-02-25 Carsten Dominik <carsten.dominik@gmail.com>
* org-agenda.el (org-agenda): Make prefix arg optional.
+ (org-agenda-search-headline-for-time): New option.
+ (org-format-agenda-item): Honor
+ `org-agenda-search-headline-for-time'.
* org-table.el (orgtbl-self-insert-command): Cluster undo for 20
characters.
diff --git a/lisp/org-agenda.el b/lisp/org-agenda.el
index 864061b..5b82e92 100644
--- a/lisp/org-agenda.el
+++ b/lisp/org-agenda.el
@@ -749,6 +749,17 @@ current display in the agenda."
:tag "Org Agenda Time Grid"
:group 'org-agenda)
+(defcustom org-agenda-search-headline-for-time t
+ "Non-nil means, search headline for a time-of-day.
+If the headline contains a time-of-day in one format or another, it will
+be used to sort the entry into the time sequence of items for a day.
+Some people have time stamps in the headline that refer to the creation
+time or so, and then this produces an unwanted side effect. If this is
+the case for your, use this variable to turn off searching the headline
+for a time."
+ :group 'org-agenda-time-grid
+ :type 'boolean)
+
(defcustom org-agenda-use-time-grid t
"Non-nil means, show a time grid in the agenda schedule.
A time grid is a set of lines for specific times (like every two hours between
@@ -3890,7 +3901,9 @@ Any match of REMOVE-RE will be removed from TXT."
;; time, tag, effort are needed for the eval of the prefix format
(tag (if tags (nth (1- (length tags)) tags) ""))
time effort neffort
- (ts (if dotime (concat (if (stringp dotime) dotime "") txt)))
+ (ts (if dotime (concat
+ (if (stringp dotime) dotime "")
+ (and org-agenda-search-headline-for-time txt))))
(time-of-day (and dotime (org-get-time-of-day ts)))
stamp plain s0 s1 s2 t1 t2 rtn srp
duration)