Template:MacroFunction: Difference between revisions
Jump to navigation
Jump to search
Verisimilar (talk | contribs) mNo edit summary |
Verisimilar (talk | contribs) (→Template Usage: added example using subtemplates) |
||
Line 40: | Line 40: | ||
</source> | </source> | ||
| | |changes= | ||
In version X.N this function also didn't exist. | In version X.N this function also didn't exist. | ||
}}</pre> | |||
===Example Using Subtemplates=== | |||
<pre>{{MacroFunction | |||
|name=exampleFunction | |||
|trusted=true | |||
|version=1.3b52 | |||
|compatibility=1.3b52 | |||
|description=This is the description of this exampleFunction. This is the description of this exampleFunction. This is the description of this exampleFunction. | |||
|usage= | |||
{{FunctionUsage | |||
|name=Standard Usage | |||
|description=This is the description for the standard usage block. This is the description for the standard usage block. This is the description for the standard usage block. | |||
|syntax=exampleFunction(param1, param2) | |||
}} | |||
|example= | |||
{{FunctionExample | |||
|name=Standard Example | |||
|description=This is the description for the standard example block. This is the description for the standard example block. This is the description for the standard example block. | |||
|syntax=[h: exampleVariable = 10] | |||
[exampleFunction(exampleVariable, "string")] | |||
|return=s t r i n g | |||
}} | |||
|changes=This function is new! | |||
}}</pre> | }}</pre> | ||
</noinclude> | </noinclude> |
Revision as of 05:04, 6 March 2009
Function {{{name}}}
Usage
{{{usage}}}
Template Usage
Example
{{MacroFunction |name=NameOfMacro |version=X.Y |description= NameOfMacro is an example of a macro function. It doesn't actually exist as a function in MapTool. |usage= <source lang="mtmacro" line> [h: NameOfMacro()] </source> |examples= This example doesn't really do anything. <source lang="mtmacro" line> [h: NameOfMacro()] </source> |changes= In version X.N this function also didn't exist. }}
Example Using Subtemplates
{{MacroFunction |name=exampleFunction |trusted=true |version=1.3b52 |compatibility=1.3b52 |description=This is the description of this exampleFunction. This is the description of this exampleFunction. This is the description of this exampleFunction. |usage= {{FunctionUsage |name=Standard Usage |description=This is the description for the standard usage block. This is the description for the standard usage block. This is the description for the standard usage block. |syntax=exampleFunction(param1, param2) }} |example= {{FunctionExample |name=Standard Example |description=This is the description for the standard example block. This is the description for the standard example block. This is the description for the standard example block. |syntax=[h: exampleVariable = 10] [exampleFunction(exampleVariable, "string")] |return=s t r i n g }} |changes=This function is new! }}