Shaun McCance
shaunm@gnome.org 2008-2009
Create a list of terms and associated descriptions.

# Definition Lists

    mal_block_terms = element terms {
      attribute style { xsd:NMTOKENS } ?,
      attribute * - (mal:* | local:*) { text } *,

      mal_block_title ?,

      element item {
        attribute style { xsd:NMTOKENS } ?,
        attribute * - (mal:* | local:*) { text } *,

        mal_block_title +,
        mal_block +
      } +
    }

The `terms` element creates a list of terms and associated definitions or descriptions. This type of list is often called a definition list or a variable list.

# Notas

The `terms` element can contain an optional `title` element followed by one or more `item` elements. Each child `item` element can contain one or more `title` elements followed by a mixture of text and any general inline elements.

The `terms` element can occur in any general block context, including inside pages, sections, and certain block elements.

The `style` attribute takes a space-separated list of style hints. Processing tools should adjust their behavior according to those style hints they understand.

The `terms` element can have attributes from external namespaces. See for more information on external-namespace attributes.

# Ejemplos

Create a simple definition list with a title:

<terms> <title>Selected Basic Block Elements</title> <item> <title><code>code</code></title> <p>Mark up a block of code or the contents of a file.</p> </item> <item> <title><code>example</code></title> <p>Mark up a group of block elements as being part of a single example.</p> </item> <item> <title><code>screen</code></title> <p>Mark up a textual user interface or an interactive shell session.</p> </item> </terms>

## Selected Basic Block Elements

## `code`

Mark up a block of code or the contents of a file.

## `ejemplo`

Mark up a group of block elements as being part of a single example.

## `screen`

Mark up a textual user interface or an interactive shell session.

Create a definition list with multiple terms per entry:

<terms> <item> <title><code>comment</code></title> <title><code>quote</code></title> <p>Formal elements which allow a <code>cite</code> element.</p> </item> <item> <title><code>figure</code></title> <title><code>listing</code></title> <title><code>synopsis</code></title> <p>Formal elements which allow a <code>desc</code> element.</p> </item> <item> <title><code>note</code></title> <p>Formal elements which only allow a <code>title</code> element.</p> </item> </terms>

## `comentario`

## `comillas`

Formal elements which allow a `cite` element.

## `figure`

## `listing`

## `synopsis`

Formal elements which allow a `desc` element.

## `note`

Formal elements which only allow a `title` element.

# Processing Expectations

Definition lists are displayed as block elements, with each child `item` displayed as some number of list items. When present, the title should be displayed in a way that makes it clear that it is the title of the list. Each `title` element of each list item is treated as a term, and is displayed as a block element. The remaining block content is then treated as the description and displayed as normal. The description blocks should be indented from the terms.

# Comparison to Other Formats

The `terms` element is similar to `variablelist` element in DocBook. Like DocBook (and unlike HTML), Mallard groups terms with their corresponding entries. In DocBook, the entry must be wrapped with a `listitem` element inside the `varlistentry` element. In Mallard, the entry is simply all of the block content except the `title` elements.