3. addAttribute

Parameter syntax:

[ '[implicitElement]' ]? [ '[empty]'|'[none]'|'[id]' ]? attribute_name [ attribute_value ]?

This command is only useful to write macro commands.

Adds attribute attribute_name in explicitly or implicitly selected element if grammar constraining the document allows to do so.

This command is similar to putAttribute except that it will not replace the attribute if it already exists.

Examples:

addAttribute [implicitElement] cols
addAttribute linkend "chapter 1"
addAttribute [dummy] cols
addAttribute [implicitElement] [dummy] cols