Node Path Tag Attribute Search - Basic Question

I’ve got a basic question about node path search. When I have this simple document:

penguin @today
giraffe @tomorrow
- penguin @today

Evaluating the node path @today returns only the first line and not the third. I’m sure I’m missing something simple… but what is it?


FoldingText queries are outline aware.

All you have missed is the first segment of the search string, which indicates the outline context to search in.

//@today means nodes at any level of outline indentation which are tagged @today
/@today is top level nodes flagged @today
/*/*/@today would be level 3 nodes flagged as @today

if you skip the prefix, it is interpreted, by default, as a search for top level nodes only, i.e. @today is assumed to be a shorthand for ‘/@today’, so only the first two nodes (level 1) are matched, and the third node (a level 2 child) is not.

(See FT > Help > Nodepaths Guide > Axes)

Ah. I assumed FT would interpret no prefix as “all levels.” But this makes perfect sense, and my search is working smoothly now. Thank you!

Ah. I assumed FT would interpret no prefix as “all levels.”

I think people may well find that the most intuitive default when FT acquires its own UI for node paths.

( In the meanwhile, under the hood, the xpath default axis is always the child axis, and the search starts at the top of the tree … )