Macros are userdefined placeholders that you can use for different purposes.
When using the !macro command you tell UDO the name of the macro in first place. The name of the macro is followed by its contents which may be empty, too.
Let me show you some examples:
Macros can help you to save time when typing often used long words. Furthermore macros can help you to change the contents of your file by simply changing the contents for macros (e.g. if your program name changed and you use a macro for the name of your program). Another example is the usage of standardized text (e.g. a standard disclaimer) where you use macros instead of the name of the program etc. These standardized texts can be included with !include. In the following example a disclaimer is included and the name of the program is defined by a macro:
[doku.u] !macro PRG Windows95 [disclaim.u] (!PRG) is provided ""as is"" without a warranty of any kind. Use it on your own risk.
Since UDO Release 6 you can use macros with parameters. You can
set the position of the parameters in the !macro command by
(!9). To call a macro with parameters
you have to write brackets (
[...]) around them.
The following small example shows how to use a macro for text that shall be printed in bold-italic style:
(!1) in the macro line will be replaced by the words
bold and italic.
nl. If you don't you will get problems with bold text ((!B)) or the newline command ((!nl)).