[ << ] | [ < ] | [ Up ] | [ > ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
1.9 General Syntactic Conventions
This section describes the general conventions used in all Texinfo documents.
- All printable ASCII characters except ‘@’, ‘{’ and ‘}’ can appear in a Texinfo file and stand for themselves. ‘@’ is the escape character which introduces commands, while ‘{’ and ‘}’ are used to surround arguments to certain commands. To put one of these special characters into the document, put an ‘@’ character in front of it, like this: ‘@@’, ‘@{’, and ‘@}’.
- Texinfo supports the usual quotation marks used in English and in other languages; see Inserting Quotation Marks.
-
Use three hyphens in a row, ‘---’, to produce a long dash—like
this (called an em dash), used for punctuation in sentences.
Use two hyphens, ‘--’, to produce a medium dash (called an
en dash), used primarily for numeric ranges, as in “June
25–26”. Use a single hyphen, ‘-’, to produce a standard hyphen
used in compound words. For display on the screen, Info reduces three
hyphens to two and two hyphens to one (not transitively!). Of course,
any number of hyphens in the source remain as they are in literal
contexts, such as
@code
and@example
. -
Form feed (CTRL-l) characters in the input are handled as
follows:
- PDF/DVI
In normal text, treated as ending any open paragraph; essentially ignored between paragraphs.
- Info
Output as-is between paragraphs (their most common use); in other contexts, they may be treated as regular spaces (and thus consolidated with surrounding whitespace).
- HTML
Written as a numeric entity except contexts where spaces are ignored; for example, in ‘@footnote{ ^L foo}’, the form feed is ignored.
- XML
Keep them everywhere; in attributes, escaped as ‘\f’; also, ‘\’ is escaped as ‘\\’ and newline as ‘\n’.
- Docbook
Completely removed, as they are not allowed.
As you can see, because of these differing requirements of the output formats, it’s not possible to use form feeds completely portably.
-
Caution: Last, do not use tab characters in a Texinfo file!
(Except perhaps in verbatim modes.) TeX uses variable-width fonts,
which means that it is impractical at best to define a tab to work in
all circumstances. Consequently, TeX treats tabs like single
spaces, and that is not what they look like in the source.
Furthermore,
makeinfo
does nothing special with tabs, and thus a tab character in your input file will usually have a different appearance in the output.To avoid this problem, Texinfo mode in GNU Emacs inserts multiple spaces when you press the <TAB> key. Also, you can run
untabify
in Emacs to convert tabs in a region to multiple spaces, or use theunexpand
command from the shell.
[ << ] | [ < ] | [ Up ] | [ > ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
This document was generated on October 2, 2013 using texi2html 5.0.