1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2024-07-01 01:33:16 +00:00
TiddlyWiki5/editions/tw5.com/tiddlers/widgets/MacroCallWidget.tid
Jeremy Ruston fbc1f5e5f6 Lots and lots and lots of docs updates
Now we've got up-to-date skeleton documentation for all the widgets
2013-10-31 22:03:40 +00:00

27 lines
878 B
Plaintext

title: MacroCallWidget
created: 201310241419
creator: JeremyRuston
modified: 201310300837
modifier: JeremyRuston
tags: widget
! Introduction
The macro call widget provides an alternative syntax for invoking macros. The advantage of the widget form is that it allows macro parameters to be specified as widget attributes, thus allowing indirection and macro values to be set.
For example, a macro called `italicise` that takes a single parameter called `text` can be invoked in any of these ways:
```
<<italicise "Text to be made into italics">>
<<italicise text:"Text to be made into italics">>
<$macrocall $name="italicise" text="Text to be made into italics"/>
```
! Content and Attributes
The content of the `<$macrocall>` widget is ignored.
|!Attribute |!Description |
|$name |Name of the macro to invoke |
|//parameters// |Macro parameters specified as attributes |