Markup Compatibility Attributes and Elements

This specification defines attributes to express compatibility rules and elements to specify alternate content.

Note:
Table 1. 9–1. Whitespace characters in attribute values

Character

Syntax

space

#x20

tab

#x9

line feed

#xA

carriage return

#xD

Whitespace characters that appear in values of attributes defined in this specification shall be normalized by markup consumers before processing as follows:

  1. Replace each tab, line feed, and carriage return with a space.

  2. Collapse contiguous sequences of spaces into a single space.

  3. Remove leading and trailing spaces.

Note:
Table 2. 9–2. Compatibility-rule attributes

Name

Description

@Ignorable

A whitespace-delimited list of namespace prefixes that identify a set of namespaces whose elements and attributes should be silently ignored by markup consumers that do not understand the namespace of the element or attribute in question.

ProcessContent

A whitespace-delimited list of element-qualified names identifying the expanded names of elements whose content shall be processed, even if the elements themselves are ignored. In any qualified name in the list, the wildcard character “*” can replace the local name to indicate that the content of all elements in the namespace shall be processed.

PreserveElements

A whitespace-delimited list of element qualified names identifying the expanded names of elements that a markup producer suggests for preservation by markup editors, even if the elements themselves are ignored. In any qualified name in the list, the wildcard character “*” can replace the local name to indicate that all elements in the namespace should be preserved.

PreserveAttributes

A whitespace-delimited list of attribute qualified names identifying the expanded names of attributes that a markup producer suggests for preservation by markup editors. In any qualified name in the list, the wildcard character “*” can replace the local name to indicate that all attributes in the namespace should be preserved.

MustUnderstand

A whitespace-delimited list of namespace prefixes identifying a set of namespace names. Markup consumers that do not understand these namespaces shall not continue to process the markup document and shall generate an error.

Table 3. 9–3. Alternate-content elements

Name

Description

AlternateContent

Associates a set of possible markup alternatives that a markup consumer might choose based on that markup consumer’s understood namespaces. The markup consumer chooses the first alternative, in markup order, requiring only namespaces it understands.

Choice

This child of <AlternateContent c>ontains a single markup alternative and identifies the namespaces that the markup consumer needs to understand in order to choose and process that alternative. At least one <Choice> element is required.

Fallback

This child of <AlternateContent s>pecifies the fallback markup alternative a markup consumer chooses if the markup consumer cannot choose any <Choice> alternative. An <AlternateContent> element shall hold no more than one <Fallback> element, which if present, shall follow all <Choice> elements.