Transient markup

The tags described in this section are used to control the rendering of style files and style file elements. It both contains markup for activation and disactivation of content and for the rendering of tags.

<active|content>

<active*|content>

<inactive|content>

<inactive*|content>
(activation/disactivation of content)

These tags can be used to temporarily or permanently change the activity of the content . In usual documents, tags are by default active. In style files, they are by default inactive. For instance, an activated fraction is rendered as

1
2
; when deactivated, it is rendered as < frac | 1 | 2 > .

The active and inactive tags only activate or desactivate the root tag of the content. Typically, a tag which contains hidden information (like hlink) can be disactivated by positioning the cursor just behind it and pressing backspace. This action just disactivates the hyperlink, but not the potentially complicated body of the hyperlink. Therefore, the hyperlink is transformed into an inactive tag of the form <inactive|<hlink|body|ref>>.

The active* and inactive* variants are used to activate or disactivate the whole content (except when other (dis-)activation tags are found inside the content). The inactive* is used frequently inside the present documentation in order to show the inactive representation of TeXmacs content. Nevertheless, it is sometimes desirable to reactivate certain subtrees inside disactivated content. For instance, the following piece of disactivated code (using disactive*) contains the reactivated subexpression ♥♥♥ (using active*):

<assign|love|<macro|from|♥♥♥ from from.>>

<inline-tag|name|arg-1||arg-n>
(rendering of inline tags)

This tag is used for the default inline rendering of an inactive tag with a given name and arguments arg-1 until arg-n. For instance, <inline-tag|foo|x|y> produces <foo|x|y>. The style of the rendering may be customized in the DocumentViewSource tags menu, or by modifying the src-style, src-special, src-compact and src-close environment variables.

<open-tag|name|arg-1||arg-n>

<middle-tag|name|arg-1||arg-n>

<close-tag|name|arg-1||arg-n>
(rendering of multi-line tags)

These tags are similar to inline-tag, when some of the arguments of the tag run over several lines. Typical HTML-like tags would correspond to <open-tag|name> and <close-tag|name>. Since TeXmacs macros may take more than one argument, a middle-tag is provided for separating distinct multi-paragraph arguments. Moreover, the opening, middle and closing tags may take additional inline arguments for rendering in a compact fashion. For instance, the code

<document|<open-tag|theorem>|<indent|The weather should be nice today.>|<close-tag|theorem>>

is rendered by default as

<\theorem|

The weather should be nice today.

>

The rendering may be customized in a similar way as in the case of inline-tag.

<style-with|var-1|val-1||var-n|val-n|body>

<style-with*|var-1|val-1||var-n|val-n|body>
(alter presentation in style files only)

This tag may be used in order to temporarily modify the rendering of inactive tags, by setting each environment variable var-i to val-i in the local typesetting context of body. When importing a style file, each style-with/style-with* tag is replaced by its body. In the case of style-with, the modified rendering is only applied to the root tag of the body. In the case of style-with*, the rendering is modified for the entire body.

<style-only|<foo|content>>

<style-only*|<foo|content>>
(content for use in style files only)

This tag may be used in order to render an inactive tags as whether we applied the macro foo on it. When importing a style file, each style-only/style-only* tag is replaced by its content. In the case of style-only, the modified rendering is only applied to the root tag of the content. In the case of style-only*, the rendering is modified for the entire content.

<symbol|symbol>

<latex|cmd>

<hybrid|cmd>

<hybrid|cmd|arg>
(auxiliary tags for entering special content)

These tags are used only temporarily when entering special content.

When pressing C-q, a symbol tag is created. After entering the name of the symbol, or the ASCII-code of the symbol and pressing return, the symbol tag is replaced by the corresponding symbol (usually a string enclosed in <>).

When pressing \, a hybrid tag is created. After entering a string and pressing return, it is determined whether the string corresponds to a LaTeX command, a macro argument, a macro or an environment variable (in this order). If so, then the hybrid tag is replaced by the appropriate content. When pressing \ while a selection is active, then the selection automatically becomes the argument of the hybrid command (or the hybrid command itself, when recognized).

The latex tag behaves similarly as the hybrid tag except that it only recognizes LaTeX commands.

The rendering macros for source trees are built-in into TeXmacs. They should not really be considered as primitives, but they are not part of any style file either.

<indent|body>
(indent some content)

Typeset the body using some indentation.

<rightflush>
(indent some content)

Flush to the right. This macro is useful to make the end of a block environment run until the right margin. This allows for more natural cursor positioning and a better layout of the informative boxes.

<src-macro|macro-name>

<src-var|variable-name>

<src-arg|argument-name>

<src-tt|verbatim-content>

<src-integer|interger>

<src-length|length>

<src-error|message>
(syntactic highlighting on purpose)

These macros are used for the syntactic highlighting of source trees. They determine how to render subtrees which correspond to macro names, variable names, argument names, verbatim content, integers, lengths and error messages.

<src-title|title>

<src-style-file|name|version>

<src-package|name|version>

<src-package-dtd|name|version|dtd|dtd-version>
(style and package administration)

These macros are used for the identification of style files and packages and their corresponding D.T.D.s. The src-title is a container for src-style-file, src-package, src-package-dtd as well as src-license and src-copyright macros.

The src-style-file tag specifies the name and version of a style file and sets the environment variable with name-style to version. The src-package-dtd specifies the name and version of a package, as well as the corresponding dtd and its version dtd-version. It sets the environment variable name-package to version and dtd-dtd to dtd-version. The src-package tag is a shorthand for src-package-dtd when the name of the D.T.D. coincides with the name of the package.

Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.1 or any later version published by the Free Software Foundation; with no Invariant Sections, with no Front-Cover Texts, and with no Back-Cover Texts. A copy of the license is included in the section entitled "GNU Free Documentation License".