@Rustem - while I solved the original problem in another way, I really 
appreciate your reply and know(!) that I'll use this later on so thank you!

FYI, this made me post a new issue 
<https://github.com/Jermolene/TiddlyWiki5/issues/1769> asking to extend 
splitbefore to allow for specified number of characters to split at.


@anyone else; Just for the record, if you instead use the following, it'll 
give the first sentence.

<$list filter="[{SomeTextyTiddler}splitbefore[. ]]" 
variable="firstLine"><$text text=<<firstLine>>/></$list>


<:-)



On Wednesday, June 3, 2015 at 11:17:17 PM UTC+2, Rustem wrote:
>
> This is a bit late, but here’s my solution that returns the first line 
> (not paragraph), using nothing but core functionality. Copy it literally 
> (including new line as splitbefore’s parameter) into a test tiddler.
>
> <$list filter="[{$:/ControlPanel}splitbefore[
> ]]" variable="firstLine"><$text text=<<firstLine>>/></$list>
>
> —R
>
> On Tuesday, May 12, 2015 at 4:41:40 AM UTC-7, Mat wrote:
>
> @Mike - thank you for your input and sorry for late reply.
>>
>> With your pointers it does work now; http://match.tiddlyspot.com/
>>
>> But I do suspect the use of $tw is inappropriate and he also comments 
>> that "/*global $tw: false */" which may be an indiction of this? I also 
>> get the surrounding brackets, which I'm guessing is a failed attempt att 
>> creating a link from the output?
>>
>> It seems like a very useful "Filter operator for picking parts out of 
>> fields using regular expressions"  so hopefully someone will create a 
>> fully satisfying version eventually.
>>
>> FYI, I intended to use it to transclude the first paragraph for the ToDo 
>> list <http://fastnewtiddler.tiddlyspot.com/#Todo%20(please%20help)> in 
>> fastnewtiddler but instead went with using a solution from Tobias to 
>> transclude a field into the text that then appears to be the first 
>> paragraph in the tiddler text and is reused in the ToDo-list. A bit 
>> backward but...
>>
>> <:-)
>>
> ​
>

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at http://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/ed65119a-d870-49e3-a1b8-02514ebc9341%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to