* Customizing agenda line format
@ 2010-09-13 13:48 Norbert Zeh
2010-09-13 19:12 ` Matt Lundin
0 siblings, 1 reply; 7+ messages in thread
From: Norbert Zeh @ 2010-09-13 13:48 UTC (permalink / raw)
To: Org Mode Mailing List
Hi folks,
Is there a way to freely customize the format of lines in the weekly
agenda or todo list. I know of the different formatting settings I can
use, but they don't do what I want. Here's a simple use case, but more
complicated ones are possible.
I have a bunch of todo items that have a special todo state, say SPECIAL.
I don't want those included in my weekly agenda, but rather have a block
agenda where one of the blocks lists all todo items with todo state
SPECIAL. Clearly, since this block includes only items that are
SPECIAL, listing this tag at the beginning of each entry's line is
redundant information. So I'd like to remove the TODO state. For
example, the org file entry
* SPECIAL Call mom
should appear simply as
Call mom
in that block of my agenda. Can this be done? I'm even willing to
override some fairly low-level line formatting function for this block.
I simply don't know where to start looking. So any pointer would be
appreciated.
Cheers,
Norbert
--
() ascii ribbon campaign - against html e-mail
/\ www.asciiribbon.org - against proprietary attachments
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Customizing agenda line format
2010-09-13 13:48 Customizing agenda line format Norbert Zeh
@ 2010-09-13 19:12 ` Matt Lundin
2010-09-13 21:15 ` Norbert Zeh
0 siblings, 1 reply; 7+ messages in thread
From: Matt Lundin @ 2010-09-13 19:12 UTC (permalink / raw)
To: Norbert Zeh; +Cc: Org Mode Mailing List
Norbert Zeh <nzeh@cs.dal.ca> writes:
> Is there a way to freely customize the format of lines in the weekly
> agenda or todo list.
...
> I have a bunch of todo items that have a special todo state, say SPECIAL.
> I don't want those included in my weekly agenda, but rather have a block
> agenda where one of the blocks lists all todo items with todo state
> SPECIAL. Clearly, since this block includes only items that are
> SPECIAL, listing this tag at the beginning of each entry's line is
> redundant information. So I'd like to remove the TODO state. For
> example, the org file entry
>
> * SPECIAL Call mom
>
> should appear simply as
>
> Call mom
>
> in that block of my agenda. Can this be done?
Check out the variable org-agenda-todo-keyword-format.
E.g.,
--8<---------------cut here---------------start------------->8---
(setq org-agenda-custom-commands
'(("x" "Special" todo "SPECIAL"
((org-agenda-todo-keyword-format "")))))
--8<---------------cut here---------------end--------------->8---
The variable org-agenda-prefix-format might also be of interest.
Best,
Matt
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Customizing agenda line format
2010-09-13 19:12 ` Matt Lundin
@ 2010-09-13 21:15 ` Norbert Zeh
2010-09-13 23:16 ` Matt Lundin
0 siblings, 1 reply; 7+ messages in thread
From: Norbert Zeh @ 2010-09-13 21:15 UTC (permalink / raw)
To: Org Mode Mailing List
Matt Lundin [2010.09.13 1512 -0400]:
> Norbert Zeh <nzeh@cs.dal.ca> writes:
>
> > Is there a way to freely customize the format of lines in the weekly
> > agenda or todo list.
> ...
> > I have a bunch of todo items that have a special todo state, say SPECIAL.
> > I don't want those included in my weekly agenda, but rather have a block
> > agenda where one of the blocks lists all todo items with todo state
> > SPECIAL. Clearly, since this block includes only items that are
> > SPECIAL, listing this tag at the beginning of each entry's line is
> > redundant information. So I'd like to remove the TODO state. For
> > example, the org file entry
> >
> > * SPECIAL Call mom
> >
> > should appear simply as
> >
> > Call mom
> >
> > in that block of my agenda. Can this be done?
>
> Check out the variable org-agenda-todo-keyword-format.
>
> E.g.,
>
> --8<---------------cut here---------------start------------->8---
> (setq org-agenda-custom-commands
> '(("x" "Special" todo "SPECIAL"
> ((org-agenda-todo-keyword-format "")))))
> --8<---------------cut here---------------end--------------->8---
>
> The variable org-agenda-prefix-format might also be of interest.
Well, I tried setting org-agenda-todo-keyword-format to "%0s", which
didn't work, but I didn't think about the above. So I tried this now.
It does remove the todo keyword, but it does only that. In particular,
there is now a space at the beginning of each line, which I assume is
simply the space in the headline that succeeds the todo keyword. Any
way of getting rid of that? Thanks for the pointer so far.
- Norbert
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Customizing agenda line format
2010-09-13 21:15 ` Norbert Zeh
@ 2010-09-13 23:16 ` Matt Lundin
2010-09-14 17:21 ` Norbert Zeh
0 siblings, 1 reply; 7+ messages in thread
From: Matt Lundin @ 2010-09-13 23:16 UTC (permalink / raw)
To: Norbert Zeh; +Cc: Org Mode Mailing List
Norbert Zeh <nzeh@cs.dal.ca> writes:
> Matt Lundin [2010.09.13 1512 -0400]:
>> Norbert Zeh <nzeh@cs.dal.ca> writes:
>>
>> > Is there a way to freely customize the format of lines in the weekly
>> > agenda or todo list.
>> ...
>> > I have a bunch of todo items that have a special todo state, say SPECIAL.
>> > I don't want those included in my weekly agenda, but rather have a block
>> > agenda where one of the blocks lists all todo items with todo state
>> > SPECIAL. Clearly, since this block includes only items that are
>> > SPECIAL, listing this tag at the beginning of each entry's line is
>> > redundant information. So I'd like to remove the TODO state. For
>> > example, the org file entry
>> >
>> > * SPECIAL Call mom
>> >
>> > should appear simply as
>> >
>> > Call mom
>> >
>> > in that block of my agenda. Can this be done?
>>
>> Check out the variable org-agenda-todo-keyword-format.
>>
>> E.g.,
>>
>> --8<---------------cut here---------------start------------->8---
>> (setq org-agenda-custom-commands
>> '(("x" "Special" todo "SPECIAL"
>> ((org-agenda-todo-keyword-format "")))))
>> --8<---------------cut here---------------end--------------->8---
>>
>> The variable org-agenda-prefix-format might also be of interest.
>
> Well, I tried setting org-agenda-todo-keyword-format to "%0s", which
> didn't work, but I didn't think about the above. So I tried this now.
> It does remove the todo keyword, but it does only that. In particular,
> there is now a space at the beginning of each line, which I assume is
> simply the space in the headline that succeeds the todo keyword. Any
> way of getting rid of that? Thanks for the pointer so far.
>
The information at the beginning of the line is controlled by
org-agenda-prefix-format. What is the value of org-agenda-prefix-format
on your machine?
What happens if you set org-agenda-prefix-format to "" in the command
above?
Best,
Matt
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Customizing agenda line format
2010-09-13 23:16 ` Matt Lundin
@ 2010-09-14 17:21 ` Norbert Zeh
2010-09-16 4:52 ` Matt Lundin
0 siblings, 1 reply; 7+ messages in thread
From: Norbert Zeh @ 2010-09-14 17:21 UTC (permalink / raw)
To: Org Mode Mailing List
Matt Lundin [2010.09.13 1916 -0400]:
> Norbert Zeh <nzeh@cs.dal.ca> writes:
>
> > Matt Lundin [2010.09.13 1512 -0400]:
> >> Norbert Zeh <nzeh@cs.dal.ca> writes:
> >>
> >> > Is there a way to freely customize the format of lines in the weekly
> >> > agenda or todo list.
> >> ...
> >> > I have a bunch of todo items that have a special todo state, say SPECIAL.
> >> > I don't want those included in my weekly agenda, but rather have a block
> >> > agenda where one of the blocks lists all todo items with todo state
> >> > SPECIAL. Clearly, since this block includes only items that are
> >> > SPECIAL, listing this tag at the beginning of each entry's line is
> >> > redundant information. So I'd like to remove the TODO state. For
> >> > example, the org file entry
> >> >
> >> > * SPECIAL Call mom
> >> >
> >> > should appear simply as
> >> >
> >> > Call mom
> >> >
> >> > in that block of my agenda. Can this be done?
> >>
> >> Check out the variable org-agenda-todo-keyword-format.
> >>
> >> E.g.,
> >>
> >> --8<---------------cut here---------------start------------->8---
> >> (setq org-agenda-custom-commands
> >> '(("x" "Special" todo "SPECIAL"
> >> ((org-agenda-todo-keyword-format "")))))
> >> --8<---------------cut here---------------end--------------->8---
> >>
> >> The variable org-agenda-prefix-format might also be of interest.
> >
> > Well, I tried setting org-agenda-todo-keyword-format to "%0s", which
> > didn't work, but I didn't think about the above. So I tried this now.
> > It does remove the todo keyword, but it does only that. In particular,
> > there is now a space at the beginning of each line, which I assume is
> > simply the space in the headline that succeeds the todo keyword. Any
> > way of getting rid of that? Thanks for the pointer so far.
> >
>
> The information at the beginning of the line is controlled by
> org-agenda-prefix-format. What is the value of org-agenda-prefix-format
> on your machine?
It seems to be more complicated than that. Here's what I found out by
tinkering around with settings a little. Setting
org-agenda-prefix-format to "" (as I already did before) correctly
removes the prefix *before* the TODO keyword. The formatting function
for everything starting with the TODO keyword, however, seems to
unconditionally insert a space between the TODO keyword and the rest of
the line. Thus, even if the TODO keyword is empty (by setting
org-agenda-todo-keyword-format to ""), there is still a space after the
now empty TODO keyword. Hence, the extra space at the beginning of the
line. To me it seems like there's no way around this with the standard
org mode settings.
Cheers,
Norbert
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Customizing agenda line format
2010-09-14 17:21 ` Norbert Zeh
@ 2010-09-16 4:52 ` Matt Lundin
2010-09-16 8:21 ` Carsten Dominik
0 siblings, 1 reply; 7+ messages in thread
From: Matt Lundin @ 2010-09-16 4:52 UTC (permalink / raw)
To: Norbert Zeh; +Cc: Org Mode Mailing List
Norbert Zeh <nzeh@cs.dal.ca> writes:
> Here's what I found out by tinkering around with settings a little.
> Setting org-agenda-prefix-format to "" (as I already did before)
> correctly removes the prefix *before* the TODO keyword. The formatting
> function for everything starting with the TODO keyword, however, seems
> to unconditionally insert a space between the TODO keyword and the
> rest of the line. Thus, even if the TODO keyword is empty (by setting
> org-agenda-todo-keyword-format to ""), there is still a space after
> the now empty TODO keyword. Hence, the extra space at the beginning of
> the line. To me it seems like there's no way around this with the
> standard org mode settings.
After experimenting a bit, I've also come to conclusion that the initial
space is hard-coded.
Best,
Matt
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Re: Customizing agenda line format
2010-09-16 4:52 ` Matt Lundin
@ 2010-09-16 8:21 ` Carsten Dominik
0 siblings, 0 replies; 7+ messages in thread
From: Carsten Dominik @ 2010-09-16 8:21 UTC (permalink / raw)
To: Matt Lundin; +Cc: Org Mode Mailing List
On Sep 16, 2010, at 6:52 AM, Matt Lundin wrote:
> Norbert Zeh <nzeh@cs.dal.ca> writes:
>
>> Here's what I found out by tinkering around with settings a little.
>> Setting org-agenda-prefix-format to "" (as I already did before)
>> correctly removes the prefix *before* the TODO keyword. The
>> formatting
>> function for everything starting with the TODO keyword, however,
>> seems
>> to unconditionally insert a space between the TODO keyword and the
>> rest of the line. Thus, even if the TODO keyword is empty (by setting
>> org-agenda-todo-keyword-format to ""), there is still a space after
>> the now empty TODO keyword. Hence, the extra space at the beginning
>> of
>> the line. To me it seems like there's no way around this with the
>> standard org mode settings.
>
> After experimenting a bit, I've also come to conclusion that the
> initial
> space is hard-coded.
It is also used by some day-to-day motion commands, so it should
remain there
- Carsten
>
> Best,
> Matt
>
> _______________________________________________
> Emacs-orgmode mailing list
> Please use `Reply All' to send replies to the list.
> Emacs-orgmode@gnu.org
> http://lists.gnu.org/mailman/listinfo/emacs-orgmode
- Carsten
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2010-09-16 8:21 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-09-13 13:48 Customizing agenda line format Norbert Zeh
2010-09-13 19:12 ` Matt Lundin
2010-09-13 21:15 ` Norbert Zeh
2010-09-13 23:16 ` Matt Lundin
2010-09-14 17:21 ` Norbert Zeh
2010-09-16 4:52 ` Matt Lundin
2010-09-16 8:21 ` Carsten Dominik
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.