emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Possible bug in subtree matching with empty title + tags
@ 2020-05-02 12:49 Christian Heinrich
  2020-05-02 13:23 ` Nicolas Goaziou
  0 siblings, 1 reply; 2+ messages in thread
From: Christian Heinrich @ 2020-05-02 12:49 UTC (permalink / raw)
  To: emacs-orgmode

[-- Attachment #1: Type: text/plain, Size: 641 bytes --]

Hi,

I'm often using empty header titles that only contain tags, such as

> **    :foo:

In my case, this is sufficient (for instance for flashcards, where I never have to actually have to
use the agenda etc.). However, since Nicolas's refactoring in
be31a0c4595a6d68b03b5cfbcbcdbf2cd76d2b7f empty titles seem to be prohibited. In the above example,
using subtrees (C-/ m) on the "foo" tag will return nothing, even though the tag is in the file. Is
this a deliberate change? I didn't see a note in the manual saying that headings must not be empty
(this might be useful then).

Thanks for your help guys!

Cheers
Christian

[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

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

* Re: Possible bug in subtree matching with empty title + tags
  2020-05-02 12:49 Possible bug in subtree matching with empty title + tags Christian Heinrich
@ 2020-05-02 13:23 ` Nicolas Goaziou
  0 siblings, 0 replies; 2+ messages in thread
From: Nicolas Goaziou @ 2020-05-02 13:23 UTC (permalink / raw)
  To: Christian Heinrich; +Cc: emacs-orgmode

Hello,

Christian Heinrich <christian@gladbachcity.de> writes:

> I'm often using empty header titles that only contain tags, such as
>
>> **    :foo:
>
> In my case, this is sufficient (for instance for flashcards, where I never have to actually have to
> use the agenda etc.). However, since Nicolas's refactoring in
> be31a0c4595a6d68b03b5cfbcbcdbf2cd76d2b7f empty titles seem to be prohibited. In the above example,
> using subtrees (C-/ m) on the "foo" tag will return nothing, even though the tag is in the file. Is
> this a deliberate change? I didn't see a note in the manual saying that headings must not be empty
> (this might be useful then).

This is not totally about empty headings, which are fine in Org.

Your example is ambiguous. Is it an empty headline with tags, or
a headline titled ":foo:" with no tag? Since we cannot support both,
choosing one breaks support for the other. You could use, e.g.,
a NO-BREAK SPACE character in your headline and lift the ambiguity.

This is not a change, but rather and undefined corner-case. There was
a discussion about it a couple of years ago, IIRC. I don't remember what
the outcome was.

Regards,

-- 
Nicolas Goaziou


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

end of thread, other threads:[~2020-05-02 13:24 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-05-02 12:49 Possible bug in subtree matching with empty title + tags Christian Heinrich
2020-05-02 13:23 ` Nicolas Goaziou

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).