### 6.4.4 New markup list command definition

Markup list commands are defined with the `define-markup-list-command` Scheme macro, which is similar to the `define-markup-command` macro described in New markup command definition, except that where the latter returns a single stencil, the former returns a list stencils.

In the following example, a `\paragraph` markup list command is defined, which returns a list of justified lines, the first one being indented. The indent width is taken from the `props` argument.

```#(define-markup-list-command (paragraph layout props args) (markup-list?)
(let ((indent (chain-assoc-get 'par-indent props 2)))
(interpret-markup-list layout props
(make-justified-lines-markup-list (cons (make-hspace-markup indent)
args)))))
```

Besides the usual `layout` and `props` arguments, the `paragraph` markup list command takes a markup list argument, named `args`. The predicate for markup lists is `markup-list?`.

First, the function gets the indent width, a property here named `par-indent`, from the property list `props` If the property is not found, the default value is `2`. Then, a list of justified lines is made using the `make-justified-lines-markup-list` function, which is related to the `\justified-lines` built-in markup list command. An horizontal space is added at the beginning using the `make-hspace-markup` function. Finally, the markup list is interpreted using the `interpret-markup-list` function.

This new markup list command can be used as follows:

```\markuplines {
\paragraph {
The art of music typography is called \italic {(plate) engraving.}
The term derives from the traditional process of music printing.
Just a few decades ago, sheet music was made by cutting and stamping
the music into a zinc or pewter plate in mirror image.
}
\override-lines #'(par-indent . 4) \paragraph {
The plate would be inked, the depressions caused by the cutting
and stamping would hold ink.  An image was formed by pressing paper
to the plate.  The stamping and cutting was completely done by
hand.
}
}
```

Other languages: español.