Omni Systems, Inc.

  

Mif2Go User's Guide, Version 55

  

Valid HTML 4.01!

 

Made with Mif2Go

17 Converting to DocBook XML > 17.4 Configuring DocBook elements > 17.4.5 Assigning attributes other than ID to DocBook elements > 17.4.5.1 Specifying attribute values for a block element or ancestor


17.4.5.1 Specifying attribute values for a block element or ancestor

You can do any of the following for block elements:

Assign block element attributes

Override block element attributes

Assign interpolated parent attributes

Override interpolated parent attributes

When you want to override default or assigned attributes, keep in mind:

Where to use DocBook Attribute markers

Assign block element attributes

To apply attributes (other than id) to a block element (other than <xref>), assign attribute="value" pairs, separated by spaces, to the paragraph format(s) mapped to the element:

[DocBookParaAttributes]

; Frame para format (wildcards OK) = attributes

ParaFmt = attribute1="value1" attribute2="value2" ...

You can use Mif2Go macros for any part of the assignment, or even for the entire assignment. For example:

[DocBookParaAttributes]

ParaFmt = <$WriteAttrMacro>

Override block element attributes

To override a setting in [DocBookParaAttributes] or to override default attributes for a particular instance of a block element, place a DocBookAttribute marker in a paragraph mapped to the element, with content as follows:

elementname: attribute1="value1" attribute2="value2" ...

For example:

step: performance="optional"

The name of the element must be followed by a colon. Separate attribute="value" pairs with a space. Each value must be enclosed in double quotes. You can use Mif2Go macros for everything after the colon.

Assign interpolated parent attributes

To assign attributes to an interpolated parent of a block element:

[DocBookParentAttributes]

; Frame para format (wildcards OK) = parentname: attributes

ParaFmt = parentname: attribute1="value1" attribute2="value2" ...

You can use Mif2Go macros for the assignment.

Override interpolated parent attributes

To override a setting in [DocBookParentAttributes] or to override default attributes for an interpolated parent of a block element, place a DocBookAttribute marker in a paragraph mapped to the element, with content as follows:

parentname: attribute1="value1" attribute2="value2" ...

To apply attributes to more than one interpolated parent, use a separate marker for each parent.

Where to use DocBook Attribute markers

Use DocBookAttribute markers only to supply attribute values other than the DTD default values for an element, or to override attribute values specified in a configuration file. Do not use DocBookAttribute markers for either of the following:

The id attribute of the current element; use a DocBookElemID marker instead. See §17.4.4.4 Specifying an ID for an individual block element or parent.

The id attribute of an interpolated parent of the current element; use a DocBookParentID marker instead. See §17.4.4.4 Specifying an ID for an individual block element or parent.

A DocBookAttribute marker overrides settings in [DocBookParaAttributes] and [DocBookParentAttributes], but does not override settings in [DocBookCharAttributes] (see §17.4.5.2 Specifying attribute values for an inline element).



17 Converting to DocBook XML > 17.4 Configuring DocBook elements > 17.4.5 Assigning attributes other than ID to DocBook elements > 17.4.5.1 Specifying attribute values for a block element or ancestor