> You said, the toc-caption here will override the one in the core! Can I > conclude that: > > If a macro is called in a scope of a tiddler and it calls a macro internally > say maymac, then if the maymac is existed in the scope of calling tiddler, > it will override the core or other scope macros! Is this kind of overloading? >
Yes, exactly that. It’s the same mechanism by which the following example renders “Ringo”: <$set name="foo" value="John"> <$set name="foo" value="Paul"> <$set name="foo" value="George"> <$set name="foo" value="Ringo"> <$text text=<<foo>>/> </$set> </$set> </$set> </$set> Best wishes Jeremy > --Mohammad > > On Thursday, February 7, 2019 at 2:59:01 PM UTC+3:30, Jeremy Ruston wrote: > I’m not sure if it will let you do exactly what you want in this situation, > but the reason that the toc-caption macro is separated out is so that it can > be redefined for a particular instantiation of the TOC. For example, here we > have a tabbed internal navigation TOC where the toc-caption macro has been > modified to put a percentage sign before each caption. The toc-caption macro > defined in this tiddler will override the one in the core. > > \define toc-caption() > <$set name="tv-wikilinks" value="no"> > % <$transclude field="caption"> > <$view field="title"/> > </$transclude> > </$set> > \end > > <$macrocall > $name="toc-tabbed-internal-nav" > tag="TableOfContents" > selectedTiddler="$:/temp/toc/selectedTiddler" > unselectedText="<p>Select a topic in the table of contents. Click the > arrow to expand a topic.</p>" > missingText="<p>Missing tiddler.</p>" > /> > > Best wishes > > Jeremy. > > >> On 7 Feb 2019, at 04:32, S. S. <sachde...@ <>gmail.com <http://gmail.com/>> >> wrote: >> >> >> David, >> >> Open the shadow tiddler: $:/core/macros/toc >> Find this line : \define toc-tabbed-external-nav >> Yes, this is the correct line for modifying the toc-tabbed-internal-nav - as >> that macro calls it. >> >> Find this line: >> <h1><<toc-caption>></h1> >> >> Change it to this : >> <h1><$view field="title"/></h1> >> >> Should work! >> Regards >> >> >> On Thursday, February 7, 2019 at 6:43:02 AM UTC+7, David Gifford wrote: >> Hi all >> >> How would I tweak $:/core/macros/toc (or something else) so that each tab in >> the toc would show the caption field of the tiddler, but the title within >> the tab contents would show the longer title field of the tiddler? >> >> -- >> 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 <http://googlegroups.com/>. >> To post to this group, send email to tiddl...@ <>googlegroups.com >> <http://googlegroups.com/>. >> Visit this group at https://groups.google.com/group/tiddlywiki >> <https://groups.google.com/group/tiddlywiki>. >> To view this discussion on the web visit >> https://groups.google.com/d/msgid/tiddlywiki/e3fc8dd3-8791-4db0-9860-3ca129fcf26d%40googlegroups.com >> >> <https://groups.google.com/d/msgid/tiddlywiki/e3fc8dd3-8791-4db0-9860-3ca129fcf26d%40googlegroups.com?utm_medium=email&utm_source=footer>. >> For more options, visit https://groups.google.com/d/optout >> <https://groups.google.com/d/optout>. > > > -- > 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] > <mailto:[email protected]>. > To post to this group, send email to [email protected] > <mailto:[email protected]>. > Visit this group at https://groups.google.com/group/tiddlywiki > <https://groups.google.com/group/tiddlywiki>. > To view this discussion on the web visit > https://groups.google.com/d/msgid/tiddlywiki/c19bf7dd-d88c-4160-8ce6-1a16b6fffba0%40googlegroups.com > > <https://groups.google.com/d/msgid/tiddlywiki/c19bf7dd-d88c-4160-8ce6-1a16b6fffba0%40googlegroups.com?utm_medium=email&utm_source=footer>. > For more options, visit https://groups.google.com/d/optout > <https://groups.google.com/d/optout>. -- 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/56307062-9758-4679-998A-6E70C9032CC4%40gmail.com. For more options, visit https://groups.google.com/d/optout.

