Bimlas,
Here is a pair of macros that uses recursion to "iterate" the toc
hierarchy, but only display the items that also meet the filter provided.
\define each-level(filter)
<$list filter="$filter$" variable=nul>
[[$(currentTiddler)$]]<br>
</$list>
<$list filter="[is[current]tagging[]]">
<<each-level $filter$>>
</$list>
\end
\define list-toc(tiddlername filter)
<$tiddler tiddler="$tiddlername$">
<$list filter="[is[current]tagging[]]">
<<each-level $filter$>>
</$list>
</$tiddler>
\end
<<list-toc TableOfContents "[is[current]!tag[test]]">>
Note the use of !tag[test] you would use tag[Another Tag]]
The next thing to do is to find easy to understand methods of taking the
filtered results, a list one 0 or more tiddlers and using them in other
ways.
Regards
Tony
On Wednesday, October 17, 2018 at 9:43:38 AM UTC+11, TonyM wrote:
>
> Bimlas,
>
> Thanks that is very nicely presented. I understand now. Recent discussion
> about TOC's and applying a filter may not exactly solve this.
>
> Effectively you want to define the first set as the members found in a TOC
> or recursive function then find the members in that set that have "Another
> Tag"?
>
> This maps closely to work I have being doing lately. Rather that make
> specific solutions can we generalise it more. In this case we could have
> our own TOC macro that runs down the hierarchy but only displays items also
> tagged "Another Tag".
>
> Instead lets find the best way to generate a list of tiddlers from a TOC
> process that can be used in set filtering.
>
> I will contribute more today.
>
> Tony
>
> On Tuesday, October 16, 2018 at 7:24:23 PM UTC+11, bimlas wrote:
>>
>> Here's a concrete example:
>>
>> On the Tiddly website int the ToC there's an entry: Features -> Drag and
>> Drop -> DragAndDropMechanism. If I looking for Features,
>> DragAndDropMechanism is not listed, because it's not the direct child of
>> it.
>>
>>
>> https://tiddlywiki.com/#Features:Features%20[[Drag%20and%20Drop]]%20DragAndDropMechanism
>>
>> I would like to find a way that shows me everything which is associated
>> with Features (everything under this tag in the ToC), than I could apply
>> another tag filter on this list (by my plugin).
>>
>> For example if I looking for "Features" and "Another tag", it would look
>> like this as mathematical sets:
>>
>> https://i.imgur.com/fe3yNQ0.png
>>
>
--
You received this message because you are subscribed to the Google Groups
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit
https://groups.google.com/d/msgid/tiddlywiki/2e4037ac-1266-470a-9c7d-9d21c96dab15%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.