<$list filter="[is[current]field:tags[]]"><$button set="!!tags" setTo="A">A</$button></$list>
<$list filter="[is[current]field:tags[A]]"><$button set="!!tags" setTo="B">B</$button></$list>
<$list filter="[is[current]field:tags[B]]"><$button set="!!tags" setTo="C">C</$button></$list>
<$list filter="[is[current]field:tags[C]]"><$button set="!!tags" setTo="">clear</$button></$list>
\define btn()
<$button set="$(transcluder)$!!tags" setTo={{!!title}}><$view field="title">clear</$view></$button>
\end
<$set name="transcluder" value={{!!title}}>
<$list filter="[[]] [is[current]list[!!tagcycle]] +[after{!!tags}] [[]] +[limit[1]]"><<btn>></$list>
<$set>{{!!title||cycleTags}}{{My Tiddler to tag||cycleTags}}
--
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+...@googlegroups.com.
To post to this group, send email to tiddl...@googlegroups.com.
Visit this group at http://groups.google.com/group/tiddlywiki.
For more options, visit https://groups.google.com/d/optout.
\define nexttag(now)
[list[Daylist]after[$(now)$]]
\end
\define swaptag(to, newtag, oldtag)
<$setfield set="$to$!!current" setTo="$newtag$">
<$mangletags find="$(oldtag)$" add="$newtag$" message="tw-set-field">
<$button message="tw-mangle-tags"> cycle </$button><br></$mangletags></$setfield>
\end
\define prepare2()
<$macrocall $name="swaptag" to={{!!title}} newtag=<<definenexttag>>/>
\end
<$set name="now" value={{!!current}} >
<$set name="oldtag" value=<<now>> >
<$list filter=<<nexttag>> variable="definenexttag" >
<$list filter="[all[current]]">
<$link>{{!!title}}</$link> <<prepare2>><br>
</$list>
</$list>
</$set>
</$set>
Hi Stephan{{!!title||cycleTags}} can be abbreviated to {{||cycleTags}}. See:
[list[Daylist]after[$(now)$]]
[list[Daylist]after[$now$]]
[list[Daylist]after[$now$]] [[list[Daylist]first[]] +[first[]]
[[list[Daylist]first[]]
+[first[]]
\define test(now)
|Brackets |$(now)$ |
|None |$now$ |
\end
! with a set
<$set name="now" value="I'm from a set">
<<test "I'm a parameter">>
</$set>
! without set
<<test "I'm a parameter">>
Look in the third tiddler: cycleTag
<$set name="now" value=[[!!current}}>\define nexttag()
...\define nexttag()
[list[Daylist]after[$(oldtag)$]][list[Daylist]first[]]+[first[]]
\end
\define swaptag(newtag)
<$setfield set="!!current" setTo="$newtag$">
<$mangletags find="$(oldtag)$" add="$newtag$" message="tw-set-field">
<$button message="tw-mangle-tags">Cycle Tags</$button>
</$mangletags></$setfield>
\end
<$set name="oldtag" value={{!!current}}>
<$list filter=<<nexttag>> variable="getnexttag" >
<$macrocall $name="swaptag" newtag=<<getnexttag>>/>
</$list>
</$set>days: Sun Mon Tue Wed Thu Fri Sat
months: Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec\define nexttag()
[list[lists##days]after[$(oldtag)$]][list[lists##days]first[]]+[first[]]
\endTo avoid the necessity for separate tiddlers for each list, lists may be stored as data entries in a data dictionary (here titled 'lists'):days: Sun Mon Tue Wed Thu Fri Sat
months: Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec-- then:\define nexttag()
[list[lists##days]after[$(oldtag)$]][list[lists##days]first[]]+[first[]]
\end
lists!!dayslists##days<$set name="list" value="lists!!days">
<$set name="target" value="Title"><$set name="list" value={{!!list}}>
<$set name="target" value={{!!title}}>\define nexttag()
[list[$(list)$]after[$(oldtag)$]][list[$(list)$]first[]]+[first[]]
\endHi Matabele
--
<$list filter="[list[lists!!days]after{!!current}][list[lists!!days]first[]]+[first[]]" variable="getnexttag">
<$setfield set="!!current" setTo=<<getnexttag>> >
<$mangletags find={{!!current}} add=<<getnexttag>> message="tw-set-field">
<$button message="tw-mangle-tags">Cycle Tags</$button>
</$mangletags></$setfield>
</$list><$list filter="[list[lists!!days]after{!!current}][list[lists!!days]first[]]+[first[]]" variable="getnexttag">
<$setfield set="!!current" setTo=<<getnexttag>> >
<$mangletags find={{!!current}} add=<<getnexttag>> message="tw-set-field">
<$button message="tw-mangle-tags">Cycle Tags</$button>
</$mangletags></$setfield>
</$list>
<$list filter="[list[lists!!days]after{!!current}][list[lists!!days]first[]]+[first[]]" variable="getnexttag">
<$setfield set="!!current" setTo=<<getnexttag>> >
<$mangletags find={{!!current}} add=<<getnexttag>> message="tw-set-field">
<$button message="tw-mangle-tags">Cycle Tags</$button>
</$mangletags>
</$setfield>
</$list>Sorry to say, but when I see this syntax I so miss TWc and plain JavaScript.
Not trying to judge anyone or anything... syntactically, this feels horrible and I don't even know where to start looking in the TW5 textbook.
Best wishes, Tobias.
--
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+...@googlegroups.com.
To post to this group, send email to tiddl...@googlegroups.com.
Visit this group at http://groups.google.com/group/tiddlywiki.
For more options, visit https://groups.google.com/d/optout.
Perhaps missing from the developer docs, what are the standards / recommendations for extending the system-tiddler namespace when it comes to plugin modules / components? Is the recommendation to simply put it all under $:/plugins/githubuser/pluginname/?
Best wishes, Tobias.
filter="[list[lists!!days]after{!!current}][list[lists!!days]first[]]+[first[]]"
-- I agree; would be nice if this was easier to understand! I suppose a widget that cycles through a space separated list might do the trick.
regards
--
You received this message because you are subscribed to a topic in the Google Groups "TiddlyWiki" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/tiddlywiki/P3cw2gILiFU/unsubscribe.
To unsubscribe from this group and all its topics, send an email to tiddlywiki+...@googlegroups.com.