You're hoping that the template transclusion will allow OOPS style
inheritance. That would be cool. But apparently when using a tiddler as a
template, it only uses the *final* (Zaphod) tiddler as the field source.
To make fields work the way you want, you would need to chain at the field
level.
In other words, in Ford you would have
In field dolphin: Fish
In field mice: {{Arthur!!mice}}
In Zaphod you would have:
In field dolphin: pan-galactic
In field mice: {{Ford!!mice}}
Then, instead of using "Arthur" as a template, clone Arthur as "Template"
and use {{||Template}} in each character tiddler (if you use {{||Arthur}}
you may get a recursion error)
I guess what would be needed to automate this process is a button that
could take tiddler A and make tiddler B, where are the fields are populated
by {{A!!field}}. Then fields in tiddler B could be overwritten with new
values as needed.
-- Mark
On Thursday, October 18, 2018 at 7:23:34 AM UTC-7, Andrés Pérez wrote:
>
> I have attached a TW which has both the WikiText transclusion attempt at
> overloading and the macro attempt.
>
> On Wednesday, October 17, 2018 at 10:01:40 AM UTC-4, Andrés Pérez wrote:
>>
>> I think I am doing something unorthodox.
>>
>> I want to use a template tiddler (call it Arthur) inside another template
>> tiddler (call it Ford).
>> Arthur will display the transcluded fields 'dolphins' and 'mice'
>> If I set define field 'dolphins' to "fish" inside of Ford, that template
>> displays it due to Arthur displaying it (and 'mice' remains predictably
>> blank).
>> If I then transclude Ford as a template inside tiddler Zaphod, but only
>> set 'mice' and not 'dolphins', then 'dolphins' is blank but 'mice' displays
>> the value I set.
>>
>> Essentially, I want to arrest the transclusion of the 'dolphins' field at
>> Ford without having to specify that in Arthur.
>>
>
--
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/d3348f38-bc94-4b1a-9abf-48e9ec47484f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.