emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* %? has no effect for org-agenda-prefix-format
@ 2016-03-16 21:58 Markus Heller
  2016-03-16 22:43 ` Christophe Schockaert
  0 siblings, 1 reply; 2+ messages in thread
From: Markus Heller @ 2016-03-16 21:58 UTC (permalink / raw)
  To: emacs-orgmode

Excerpt from describe-variable org-agenda-prefix-format:

If the first character after `%' is a question mark, the entire field
will only be included if the corresponding value applies to the current
entry.  This is useful for fields which should have fixed width when
present, but zero width when absent.  For example, "%?-12t" will
result in a 12 character time field if a time of the day is specified,
but will completely disappear in entries which do not contain a time.

This does not work for me (emacs 24.3, Org-mode version 8.2.10 (8.2.10-
41-g42228a-elpa)).

Excerpt from agenda view:

<excerpt agenda view>
Project Subtasks
  INFRA nil : TODO Purchase Fragment Library
</excerpt agenda view>

Excerpt from org file (Not that the task in question has no Property 
drawer at all):

<excerpt org file>
* Other Infrastructure Development
:PROPERTIES:
:CATEGORY: INFRA
:END:
** TODO NMR-based Fragment Screen
*** TODO Purchase Fragment Library
</excerpt org file>

Here's the definition of org-agenda-prefix-format from my .emacs:

<excerpt from .emacs>
((org-agenda-prefix-format "  %-5c %?-4(setq type (org-entry-get (point) 
\"Type\")): ")
</excerpt from .emacs>

There is a similar thread on stackexchange from March 10 on this 
(http://stackoverflow.com/questions/35910204/org-agenda-prefix-format-
does-not-work).

Is this a bug?

Thanks
Markus

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2016-03-16 22:43 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-03-16 21:58 %? has no effect for org-agenda-prefix-format Markus Heller
2016-03-16 22:43 ` Christophe Schockaert

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).