grammars/basicdoc.rng in relaton-omg-1.17.0 vs grammars/basicdoc.rng in relaton-omg-1.18.0
- old
+ new
@@ -93,12 +93,93 @@
<ref name="pre"/>
<ref name="note"/>
<ref name="pagebreak"/>
<ref name="hr"/>
<ref name="bookmark"/>
+ <ref name="amend"/>
</choice>
</define>
+ <define name="amend">
+ <element name="amend">
+ <ref name="AmendType"/>
+ </element>
+ </define>
+ <define name="AmendType">
+ <optional>
+ <attribute name="id">
+ <data type="ID"/>
+ </attribute>
+ </optional>
+ <attribute name="change">
+ <choice>
+ <value>add</value>
+ <value>modify</value>
+ <value>delete</value>
+ <value>replace</value>
+ </choice>
+ </attribute>
+ <optional>
+ <attribute name="path"/>
+ </optional>
+ <optional>
+ <attribute name="path_end"/>
+ </optional>
+ <optional>
+ <attribute name="title"/>
+ </optional>
+ <optional>
+ <element name="location">
+ <zeroOrMore>
+ <choice>
+ <ref name="locality"/>
+ <ref name="localityStack"/>
+ </choice>
+ </zeroOrMore>
+ </element>
+ </optional>
+ <optional>
+ <element name="description">
+ <zeroOrMore>
+ <ref name="BasicBlock"/>
+ </zeroOrMore>
+ </element>
+ </optional>
+ <optional>
+ <element name="newcontent">
+ <optional>
+ <attribute name="id">
+ <data type="ID"/>
+ </attribute>
+ </optional>
+ <zeroOrMore>
+ <ref name="BasicBlock"/>
+ </zeroOrMore>
+ </element>
+ </optional>
+ <zeroOrMore>
+ <ref name="classification"/>
+ </zeroOrMore>
+ <zeroOrMore>
+ <ref name="contributor"/>
+ </zeroOrMore>
+ </define>
+ <define name="classification">
+ <element name="classification">
+ <ref name="classification_tag"/>
+ <ref name="classification_value"/>
+ </element>
+ </define>
+ <define name="classification_tag">
+ <element name="tag">
+ <text/>
+ </element>
+ </define>
+ <define name="classification_value">
+ <element name="value">
+ <text/>
+ </element>
+ </define>
<define name="paragraph">
<element name="p">
<ref name="ParagraphType"/>
</element>
</define>
@@ -713,31 +794,40 @@
</zeroOrMore>
</element>
</define>
<define name="ruby">
<element name="ruby">
- <zeroOrMore>
- <choice>
- <ref name="PureTextElement"/>
- <ref name="rp"/>
- <ref name="rt"/>
- </choice>
- </zeroOrMore>
+ <choice>
+ <ref name="ruby_pronunciation"/>
+ <ref name="ruby_annotation"/>
+ </choice>
+ <choice>
+ <text/>
+ <ref name="ruby"/>
+ </choice>
</element>
</define>
- <define name="rp">
- <element name="rp">
- <zeroOrMore>
- <ref name="PureTextElement"/>
- </zeroOrMore>
+ <define name="ruby_pronunciation">
+ <element name="pronunciation">
+ <attribute name="value"/>
+ <optional>
+ <attribute name="script"/>
+ </optional>
+ <optional>
+ <attribute name="lang"/>
+ </optional>
</element>
</define>
- <define name="rt">
- <element name="rt">
- <zeroOrMore>
- <ref name="PureTextElement"/>
- </zeroOrMore>
+ <define name="ruby_annotation">
+ <element name="annotation">
+ <attribute name="value"/>
+ <optional>
+ <attribute name="script"/>
+ </optional>
+ <optional>
+ <attribute name="lang"/>
+ </optional>
</element>
</define>
<define name="br">
<element name="br">
<empty/>
@@ -912,47 +1002,52 @@
so <callout target="xyz">1</callout>
corresponds to <xref type="callout" target="xyz">1</xref>
-->
<define name="image">
<element name="image">
- <attribute name="id">
- <data type="ID"/>
+ <ref name="Image"/>
+ </element>
+ </define>
+ <define name="Image">
+ <attribute name="id">
+ <data type="ID"/>
+ </attribute>
+ <attribute name="src">
+ <data type="anyURI"/>
+ </attribute>
+ <attribute name="mimetype"/>
+ <optional>
+ <attribute name="filename"/>
+ </optional>
+ <optional>
+ <attribute name="width">
+ <ref name="ImageSize"/>
</attribute>
- <attribute name="src">
+ </optional>
+ <optional>
+ <attribute name="height">
+ <ref name="ImageSize"/>
+ </attribute>
+ </optional>
+ <optional>
+ <attribute name="alt"/>
+ </optional>
+ <optional>
+ <attribute name="title"/>
+ </optional>
+ <optional>
+ <attribute name="longdesc">
<data type="anyURI"/>
</attribute>
- <attribute name="mimetype"/>
- <optional>
- <attribute name="filename"/>
- </optional>
- <optional>
- <attribute name="width">
- <choice>
- <data type="int"/>
- <value>auto</value>
- </choice>
- </attribute>
- </optional>
- <optional>
- <attribute name="height">
- <choice>
- <data type="int"/>
- <value>auto</value>
- </choice>
- </attribute>
- </optional>
- <optional>
- <attribute name="alt"/>
- </optional>
- <optional>
- <attribute name="title"/>
- </optional>
- <optional>
- <attribute name="longdesc">
- <data type="anyURI"/>
- </attribute>
- </optional>
- </element>
+ </optional>
+ </define>
+ <define name="ImageSize">
+ <choice>
+ <data type="string">
+ <param name="pattern">\d+([.]\d+)?(%?)</param>
+ </data>
+ <value>auto</value>
+ </choice>
</define>
<define name="video">
<element name="video">
<attribute name="id">
<data type="ID"/>