I am couldn't exactly understand what is being asked but the way I 
understand, you want to select text that comes between two tags.

When I wanted to select that text that comes between <p> tags in a tiddler 
and discard the other text the filter I used was 

[{Tiddler 1}split[<p>]splitbefore[</p>]removesuffix[</p>]!is[blank]]

Shouldn't this work for selecting between section tags as well?

Now you could add another split for spliting into separate lines if you 
want I think.

On Sunday, 26 July 2020 07:04:11 UTC+5:30, TW Tones wrote:
>
> Folks,
>
> The following objective I believe exposes a limitation in tiddlywiki I 
> would like to resolve; however I wish to find at least a work around for 
> now.
>
> I am just writing a macro to process lines in a tiddler
> <$tiddler tiddler=<<tiddlername>> >
> <$list filter="[all[current]get[text]splitregexp[\n]]" variable=line>
>
> </$list>
> </$tiddler> 
>
> However inside the list, I want to process each line, 
>
>    - However I wish to detect a start and end condition and display only 
>    the lines including and between the start and end condition.
>    - This start and end condition may occur more than once in the same 
>    tiddler.
>    - A real world example may be extracting the content between an open 
>    and close html div or section tag.
>
> To do this my first idea so far is 
>
>    - setting a flag at the start of when the condition is met, 
>    - displaying each line when this flag is on
>    - and turning the flag off when the end condition is met.
>
> However this flag would be a variable in the traditional (non tiddlywiki 
> sense) and I do not believe we have one in, tiddlywiki that does not 
> require a trigger to set a text reference to that value. This is a gap I 
> have recognised for some time but had trouble communicating.
>
> A second idea is to "call a sub-routine", while the condition is met, 
>
>    - but to do this we need to have the ability to request the next line 
>    from the source tiddler
>    - We can not do this to my knowledge because the flow must return to 
>    the next item in the list that calls the subroutine.
>
>
> Can anyone share a solution to this issues please?
>
> thanks in advance for considering this
> TW Tones
>
>
>

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/48de5753-f48d-4510-8c42-571debfc5defo%40googlegroups.com.

Reply via email to