Info Node: (texinfo)Defining New Texinfo Commands

CFHT HOME texinfo: Defining New Texinfo Commands


up: Top next: Include Files prev: Conditionals Back to Software Index

19 Defining New Texinfo Commands
********************************

Texinfo provides several ways to define new commands:

   * A Texinfo "macro" allows you to define a new Texinfo command as any
     sequence of text and/or existing commands (including other macros).
     The macro can have any number of "parameters"--text you supply each
     time you use the macro.

     Incidentally, these macros have nothing to do with the '@defmac'
     command, which is for documenting macros in the subject area of the
     manual (Note: Def Cmd Template).

   * '@alias' is a convenient way to define a new name for an existing
     command.

   * '@definfoenclose' allows you to define new commands with customized
     output for all non-TeX output formats.

  Most generally of all, not just for defining new commands, it is
possible to invoke an external macro processor and have Texinfo
recognize so-called '#line' directives for error reporting.

  If you want to do simple text substitution, '@set' and '@value' is the
simplest approach (Note: @set @clear @value).

* Defining Macros
Defining and undefining new commands.
* Invoking Macros
Using a macro, once you've defined it.
* Macro Details
Limitations of Texinfo macros.
* @alias
Command aliases.
* @definfoenclose
Customized highlighting.
* External Macro Processors
'#line' directives.

automatically generated by info2www version 1.2