Skip to content

Commit

Permalink
Merge pull request #311 from w3c/issue-0186-value-expression-conventions
Browse files Browse the repository at this point in the history
Issue 0186 value expression conventions
  • Loading branch information
skynavga committed May 17, 2017
2 parents 938fa27 + d3bb69f commit 2c3bf6e
Showing 1 changed file with 38 additions and 0 deletions.
38 changes: 38 additions & 0 deletions spec/ttml2.xml
Original file line number Diff line number Diff line change
Expand Up @@ -1831,6 +1831,44 @@ own illustration.</p>
<p>The term linear white-space (LWSP) is to be interpreted as a non-empty sequence of
SPACE (U+0020), TAB (U+0009), CARRIAGE RETURN (U+000D), or LINE FEED (U+000A),
which corresponds to production [3] <code>S</code> as defined by <bibref ref="xml10"/>.</p>
<p>The following conventions are used in the specification of value syntax expressions:</p>
<ulist>
<item><p>a literal term (specified within quotation marks), when present, must appear exactly as specified
(excluding the quotation marks themselves);</p></item>
<item><p>concatenated (juxtaposed) terms mean that all terms must appear in the stated order, e.g., <code>a b</code> means that the terms
<code>a</code> and <code>b</code> are present and the former precedes the latter;</p></item>
<item><p>a vertical bar (<code>|</code>) separates two or more alternatives, of which exactly one must appear;</p></item>
<item><p>a double vertical bar (<code>||</code>) separates two or more options, of which one or more must appear in any order;</p></item>
<item><p>a double ampersand (<code>&amp;&amp;</code>) separates two or more terms, all of which must appear in any order;</p></item>
<item><p>open and close parenthesis (<code>()</code>) are used for grouping and resolving operator precedence;</p></item>
<item><p>open and close square brackets (<code>[]</code>) are used to express character classes;</p></item>
<item><p>open and close curly braces (<code>{}</code>) are used in two ways, where the context is generally sufficient to determine which
applies (and, if not, then the surrounding prose will make clear which applies):</p>
<ulist>
<item><p>to express a repetition count or range, which takes one of the following forms:</p>
<ulist>
<item><p><code>{</code><emph><code>count</code></emph><code>}</code></p></item>
<item><p><code>{</code><emph><code>minimum</code></emph><code>,</code><emph><code>maximum</code></emph><code>}</code></p></item>
</ulist>
</item>
<item><p>to express a collection of characters, one of which must appear; in
addition, a collection may be specified as a difference of collections, such as <code>{char-{specials}}</code>,
which denotes all XML characters minus a collection of <emph>special</emph> characters.</p></item>
</ulist>
</item>
<item><p>the Kleene operators <code>?</code>, <code>*</code>, and <code>+</code> respectively express zero or one,
zero or more, and one or more of the preceding term;</p></item>
<item>
<p>operator precedence (from highest to lowest) is as follows, all of which have left to right associativity</p>
<olist>
<item><p>grouping</p></item>
<item><p>concatenation (juxtaposition)</p></item>
<item><p><code>&amp;&amp;</code></p></item>
<item><p><code>||</code></p></item>
<item><p><code>|</code></p></item>
</olist>
</item>
</ulist>
<p>Unless stated to the contrary, the terms <emph>horizontal</emph> and <emph>vertical</emph> are interpreted in an absolute sense, not relative to writing mode, while
<emph>width</emph> refers to a dimension along the <emph>horizontal</emph> axis and
<emph>height</emph> refers to a dimension along the <emph>vertical</emph> axis. All exceptions are explicitly noted in the text.</p>
Expand Down

0 comments on commit 2c3bf6e

Please sign in to comment.