Fix: Don't treat an element's :begin property as a marker

Only markers are markers.  Also add FIXME about tag inheritance when
no marker is used (although see caveat in it...).
This commit is contained in:
Adam Porter 2018-08-22 13:32:44 -05:00
parent b4ba9e78fd
commit cdbe750b7c
2 changed files with 13 additions and 10 deletions

View file

@ -37,15 +37,15 @@ If MARKERS is non-nil, `org-agenda-ng--add-markers' is used to
add markers to each item, pointing to the item in its source
buffer. In this case, ACTION should return an Org element."
(declare (indent defun))
(setq action (cl-ecase markers
('t `(lambda ()
;; FIXME: Document that, when markers is t, `action' should return an Org
;; headline element, which --add-markers works with. On the other hand,
;; maybe this should be on the agenda-ng side.
(->> ,action
org-ql--add-agenda-markers)))
(setq action (pcase markers
('nil `(lambda ()
,action))))
,action))
(_ `(lambda ()
;; FIXME: Document that, when markers is t, `action' should return an Org
;; headline element, which --add-markers works with. On the other hand,
;; maybe this should be on the agenda-ng side.
(->> ,action
org-ql--add-agenda-markers)))))
`(org-ql--query ,buffers-or-files
',pred-body
:action ,action