* org-agenda.el (org-format-agenda-item): Convert category to a string
if it is a symbol. This fixes the following call to
org-agenda-get-category-icon which fails if category is not a string.
Signed-off-by: Julien Danjou <julien@danjou.info>
* lisp/org-agenda.el (org-agenda-timegrid-use-ampm): New option.
(org-agenda-time-of-day-to-ampm): New function.
(org-agenda-time-of-day-to-ampm-maybe): New function.
(org-format-agenda-item): Call org-agenda-time-of-day-to-ampm-maybe.
Patch by Christoph Allen Webber
* lisp/org-agenda.el (org-agenda-today): New function.
(org-agenda-get-day-face): New function.
(org-timeline): Use org-agenda-today and org-agenda-get-day-face.
(org-agenda-list): Use org-agenda-today and org-agenda-get-day-face.
(org-todo-list): Use org-agenda-today.
(org-get-all-dates): Use org-agenda-today.
(org-agenda-day-face-function): New variable.
(org-agenda-get-day-face): Use org-agenda-day-face-function.
Signed-off-by: Julien Danjou <julien@danjou.info>
Signed-off-by: Julien Danjou <julien@danjou.info>
* doc/org.texi (Categories): Document category icons.
* lisp/org-agenda.el (org-agenda-prefix-format): Insert place holder for icon.
(org-agenda-category-icon-alist): New option.
(org-agenda-get-category-icon): New function.
(org-format-agenda-item): Support for icons.
(org-compile-prefix-format): Support for icons.
* lisp/org.el (org-shorten-string): New function.
* lisp/org-exp.el (org-export-convert-protected-spaces): New function.
(org-export-preprocess-string): Call
`org-export-convert-protected-spaces' to handle new hard spaces.
* lisp/org-clock.el (org-clocktable): New customization group.
(org-clocktable-defaults): New option.
(org-clock-clocktable-formatter): New option.
(org-clock-clocktable-default-properties): New option.
(org-dblock-write:clocktable): Rewrite to split out functionality
into separate functions.
(org-clocktable-write-default):
(org-clocktable-indent-string):
(org-clock-get-table-data): New functions.
* lisp/org-agenda.el (org-agenda-list):
(org-agenda-redo):
(org-agenda-clockreport-mode):
(org-agenda-set-mode-name): Rewrite to implement filtered clock tables.
* doc/org.texi (Clocking commands):
(The clock table): New sections.
(Agenda commands): Document filtered clock reports.
* lisp/org-agenda.el (org-agenda-get-sexps): Handle lists as return values
from diary entries
* lisp/org-bbdb.el (org-bbdb-anniversaries): Handle lists of anniversaries
* lisp/org.el (org-diary-sexp-entry): Handle lists as return values
from diary entries.
ukasz Stelmach <lukasz.stelmach@iem.pw.edu.pl> writes:
> I've disovered, that %%(org-bbdb-anniversaries) returns (as every other
> sexp) a string. Which is OK if there is only one.
>
> Anniversaries: John Doe's 10th wedding anniversary
>
> Unfortunately the agenda view becomes awful if we have noted Jane's
> weeding date too
>
> Anniversaries: John Doe's 10th wedding anniversary; Jane Doe's 10th wedding anniversary
>
> And what if we know 3 Eves and 5 Adams and it's Christmas Eve? (Hint:
> their name day)
[...]
As Thomas Bauman pointed out, there are functions that can be used in
sexps which return cons cells like this
(nil . "Full Moon 3:35am (CEST)")
(this one is diary-lunar-phases), these aren't properly supported by the
previous version of my patch. This one can distinguish between such a
cons cell and a "real" list.
("John Doe's 10th wedding anniversary"
"Jane Doe's 10th wedding anniversary")
This is because
(consp (cdr '(a . b))) ; => nil
so org-diary-sexp-entry can be made return (cdr result) only in case of
the former cons cell. The third condition in the `cond' block is IMHO
enough as it is now, but if you think adding
(listp (cdr result))
may help then be it.
* lisp/org-agenda.el (org-agenda-add-time-grid-maybe): Pad clock times
with zeros. Start applying face earlier.
Hello,
Here a tiny patch to:
- have padding with 0 for the clock time
- begin applying face org-time-grid from position 2, in order to be properly
aligned with the rest of the agenda (you don't see that if you don't have a
face with background color)
[My apologies, but I'm afraid my first attempt at this patch mistook a
necessary second check for redundancy. Here is an improved version.]
* lisp/org-agenda.el (org-prepare-agenda): If the agenda is called
from within the agenda via an elisp link, such as
[[elisp:(org-agenda-list)]], org-prepare-agenda erases the buffer of
the file containing the link, since that buffer is current during
org-prepare agenda (due to a with-current-buffer in
org-agenda-open-link). An additional test now ensures that the
agenda buffer is in fact current when the buffer is erased and local
variables for the agenda are set.
* lisp/org-agenda.el (org-agenda-add-entry-text): Make sure we move
forward even if there is no text to be added.
Adding entry text with org-agenda-add-entry-text-maxlines greater than
0 could result in an infinite loop.
* org-agenda.el (org-agenda-clock-goto): Use `\C-c\C-x\C-j' for
`org-clock-goto' and `J' for `org-agenda-clock-goto'. If the heading
currently clocked in is not listed in the agenda, display this entry
in another buffer. If there is no running clock, display a help
message.
* org-clock.el (org-clock-set-current): append the filename after the
heading.
* lisp/org-agenda.el (org-agenda-menu-show-match): New option.
(org-agenda-menu-two-column): New option.
(org-agenda-get-restriction-and-command): Implement dispatch menu
without showing the matcher, and with two-column display.
This command jumps to the headline of the clocking task within the
agenda buffer. `org-agenda-clock-goto' is bound to `C-c C-x C-j'.
It is different from `org-clock-goto', which jumps to the currently
clocking entry itself (bound to `J').