I have been trying to find a way to do this as well. I think that there may 
be a way to do this using the updated set widget in the prerelease and 
something like the combination lock in the Safe tiddler in the interactive 
fiction thing I am working on (http://zorklike.tiddlyspot.com/). I haven't 
had any success in actually getting it to work, but I have been poking it.

The tiddler EventTriggerTemplate from the zork-like wiki has an example of 
some simple nested reveal widgets that could probably be modified by using 
set, and you could put them in a macro that allows them to take different 
parameters. 
You can use this to put if/elseif/else functionality into displayed content 
using reveal widgets by using a filter and set to pick the state used by 
the reveal widget. But this is just for revealing content.

That is my progress on the problem, I have been lazily learning javascript, 
hopefully I will just make a plugin. So if you do get a good structure for 
the widget worked out I will at least try to implement it. It would be a 
good thing to learn with, but I just started teaching myself so don't 
expect anything too amazing. 

On Sunday, November 23, 2014 5:20:00 AM UTC-7, Tobias Beer wrote:
>
> Hi everyone,
>
> I'd like to be able to follow optional routes in a macro, for example...
>
>    - *if *it's value is defined take *<<variable>>*
>    - *else* take *$parameter$*
>
> I can certainly play with options to achieve this and
> once I figured something out myself, I will post here.
>
> Regardless, I'd love to know the possible ways
> you know or can think of in which to tackle this problem, so...
>
> If you've have something new in in mind,
> start your reply with a line that summarizes your concept:
>
> "CONCEPT: use foo bar..."
>
> That way it's easier to spot possible solutions.
>
> Could even be an idea for a new widget that doesn't even exist yet, e.g. 
> IfElseWidget...
> sketch out the design for it, someone might just jump at its 
> implementation.
>
> 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 [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/tiddlywiki.
For more options, visit https://groups.google.com/d/optout.

Reply via email to