Next: , Up: Floats


12.1.1 @float [type][,label]: Floating material

To produce floating material, enclose the material you want to be displayed separate between @float and @end float commands, on lines by themselves.

Floating material uses @image to display an already-existing graphic (see Images), or @multitable to display a table (see Multi-column Tables). However, the contents of the float can be anything. Here's an example with simple text:

     @float Figure,fig:ex1
     This is an example float.
     @end float

And the output:

This is an example float.

Figure 12.1

As shown in the example, @float takes two arguments (separated by a comma), type and label. Both are optional.

type
Specifies the sort of float this is; typically a word such as “Figure”, “Table”, etc. If not given, and label is, any cross-referencing will simply use a bare number.
label
Specifies a cross-reference label for this float. If given, this float is automatically given a number, and will appear in any @listofloats output (see listoffloats). Cross-references to label are allowed.

On the other hand, if label is not given, then the float will not be numbered and consequently will not appear in the @listoffloats output or be cross-referenceable.

Normally, you specify both type and label, to get a labeled and numbered float.

In Texinfo, all floats are numbered the same way: with the chapter number (or appendix letter), a period, and the float number, which simply counts 1, 2, 3, ..., and is reset at each chapter. Each float type is counted independently.

Floats within an @unnumbered are numbered, or outside of any chapter, are simply numbered consecutively from 1.

These numbering conventions are not, at present, changeable.