--- a/RelaxNG/publidoc.rnc sam. juin 11 00:33:24 2011 +0200
+++ b/RelaxNG/publidoc.rnc sam. juin 11 01:26:31 2011 +0200
@@ -218,7 +218,7 @@
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ blocks ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-block = (parag | \list | media | speech)
+block = (parag | \list | speech | media)
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ parag ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
@@ -235,8 +235,8 @@
\list.content =
title?,
- ( (attribute type {"ordered"} ?, item, item+)
- | (attribute type {"itemized"}, item, item+)
+ ( (attribute type {"itemized"} ?, item, item+)
+ | (attribute type {"ordered"}, item, item+)
| (attribute type {"glossary"}, glossary.item+) )
# ~~~~~~ item
@@ -256,6 +256,26 @@
label.content = inlines
+# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ speech ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+# ~~~~~~ speech
+speech = element speech { speech.content }
+
+speech.content =
+ speaker?,
+ stage?,
+ parag+
+
+# ~~~~~~ speaker
+speaker = element speaker { speaker.content }
+
+speaker.content = inlines
+
+# ~~~~~~ stage
+stage = element stage { stage.content }
+
+stage.content = inlines
+
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ media ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# ~~~~~~ media
@@ -288,27 +308,6 @@
copyright.content = inlines
-# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ speech ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-
-# ~~~~~~ speech
-speech = element speech { speech.content }
-
-speech.content =
- speaker?,
- stage?,
- parag+
-
-# ~~~~~~ speaker
-speaker = element speaker { speaker.content }
-
-speaker.content = inlines
-
-# ~~~~~~ stage
-stage = element stage { stage.content }
-
-stage.content = inlines
-
-
# =============================================================================
# Inline level
# =============================================================================
--- a/RelaxNG/publidoc.rng sam. juin 11 00:33:24 2011 +0200
+++ b/RelaxNG/publidoc.rng sam. juin 11 01:26:31 2011 +0200
@@ -405,8 +405,8 @@
<choice>
<ref name="parag"/>
<ref name="list"/>
+ <ref name="speech"/>
<ref name="media"/>
- <ref name="speech"/>
</choice>
</define>
<!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ parag ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
@@ -438,7 +438,7 @@
<group>
<optional>
<attribute name="type">
- <value>ordered</value>
+ <value>itemized</value>
</attribute>
</optional>
<ref name="item"/>
@@ -448,7 +448,7 @@
</group>
<group>
<attribute name="type">
- <value>itemized</value>
+ <value>ordered</value>
</attribute>
<ref name="item"/>
<oneOrMore>
@@ -497,6 +497,42 @@
<define name="label.content">
<ref name="inlines"/>
</define>
+ <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ speech ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <!-- ~~~~~~ speech -->
+ <define name="speech">
+ <element name="speech">
+ <ref name="speech.content"/>
+ </element>
+ </define>
+ <define name="speech.content">
+ <optional>
+ <ref name="speaker"/>
+ </optional>
+ <optional>
+ <ref name="stage"/>
+ </optional>
+ <oneOrMore>
+ <ref name="parag"/>
+ </oneOrMore>
+ </define>
+ <!-- ~~~~~~ speaker -->
+ <define name="speaker">
+ <element name="speaker">
+ <ref name="speaker.content"/>
+ </element>
+ </define>
+ <define name="speaker.content">
+ <ref name="inlines"/>
+ </define>
+ <!-- ~~~~~~ stage -->
+ <define name="stage">
+ <element name="stage">
+ <ref name="stage.content"/>
+ </element>
+ </define>
+ <define name="stage.content">
+ <ref name="inlines"/>
+ </define>
<!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ media ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
<!-- ~~~~~~ media -->
<define name="media">
@@ -552,42 +588,6 @@
<define name="copyright.content">
<ref name="inlines"/>
</define>
- <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ speech ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
- <!-- ~~~~~~ speech -->
- <define name="speech">
- <element name="speech">
- <ref name="speech.content"/>
- </element>
- </define>
- <define name="speech.content">
- <optional>
- <ref name="speaker"/>
- </optional>
- <optional>
- <ref name="stage"/>
- </optional>
- <oneOrMore>
- <ref name="parag"/>
- </oneOrMore>
- </define>
- <!-- ~~~~~~ speaker -->
- <define name="speaker">
- <element name="speaker">
- <ref name="speaker.content"/>
- </element>
- </define>
- <define name="speaker.content">
- <ref name="inlines"/>
- </define>
- <!-- ~~~~~~ stage -->
- <define name="stage">
- <element name="stage">
- <ref name="stage.content"/>
- </element>
- </define>
- <define name="stage.content">
- <ref name="inlines"/>
- </define>
<!--
=============================================================================
Inline level
--- a/Xml/Documents/torture_test.xml sam. juin 11 00:33:24 2011 +0200
+++ b/Xml/Documents/torture_test.xml sam. juin 11 01:26:31 2011 +0200
@@ -13,7 +13,7 @@
<date of="event">2011-06</date>
<place>Paris</place>
<source type="book" id="9782843550362">
- <title>Les misérables</title>
+ <title>Les Misérables</title>
<pagenumber value="312"/>
</source>
<source type="file" id="hugo_miserables.xml"/>
@@ -186,7 +186,10 @@
<title>Le niveau courant</title>
</metadata>
<topic>
- <section>
+ <metadata>
+ <title>Éléments divers</title>
+ </metadata>
+ <section>
<list type="glossary">
<item>
<label>Indices et exposants</label>
@@ -194,7 +197,7 @@
indice<sub>3</sub>.</parag>
</item>
<item>
- <label>Chiffres roamains</label>
+ <label>Chiffres romains</label>
<parag>En horlogerie, 4 est écrit <romannum>iiii</romannum> au
lieu de <romannum>iv</romannum>, essentiellement pour des raisons
de lisibilité sur un cadran rond. C'est ce qui lui vaut son nom
@@ -206,9 +209,15 @@
syllabe.</parag>
</item>
<item>
+ <label>Citations</label>
+ <parag>
+ <quote>Impossible de vous dire mon âge, il change tout le
+ temps.</quote> Allais Alphonse (1855-1905)</parag>
+ </item>
+ <item>
<label>Liens</label>
<parag>N'hésitez pas à visiter le site de
- <link uri="www.prismallia.fr">Prismallia</link>.</parag>
+ <link uri="http://www.prismallia.fr">Prismallia</link>.</parag>
</item>
</list>
</section>