# HG changeset patch # User Patrick PIERRE # Date 1307881043 -7200 # Node ID e448c6a000e50b41262104b62e8489dd3d9e7163 # Parent ca367d4d080b363c1ab69322cd85da480aeec5d8 metadata spécialisé diff -r ca367d4d080b -r e448c6a000e5 RelaxNG/publidoc.rnc --- a/RelaxNG/publidoc.rnc sam. juin 11 20:35:18 2011 +0200 +++ b/RelaxNG/publidoc.rnc dim. juin 12 14:17:23 2011 +0200 @@ -30,12 +30,12 @@ document.id.attribute = attribute xml:id { xsd:ID } document.content = - metadata?, + top.metadata?, (division+ | topic+) # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ topic ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -top.topic = element topic { top.topic.attributes, topic.content } +top.topic = element topic { top.topic.attributes, top.topic.content } # ============================================================================= @@ -44,28 +44,49 @@ # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ metadata ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -metadata = element metadata { metadata.content } +top.metadata = element metadata { top.metadata.content } +division.metadata = element metadata { division.metadata.content } +component.metadata = element metadata { component.metadata.content } +section.metadata = element metadata { section.metadata.content } -metadata.content = - title - & subtitle? +top.metadata.content = + (title, subtitle?)? + & language? & author* & publisher? - & language? & date? & place? & source* & subjectset? & abstract? & annotation* +division.metadata.content = + (title, subtitle?)? + & language? + & annotation* +component.metadata.content = + (title, subtitle?)? + & language? + & author* + & annotation* +section.metadata.content = + (title, subtitle?)? + & language? + & annotation* # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ title, subtitle ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ title = element title { title.content } +subtitle = element subtitle { title.content } title.content = inlines -subtitle = element subtitle { title.content } +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ language ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +language = element language { language.attributes } + +language.attributes = lang.attribute +lang.attribute = attribute xml:lang { xsd:language } # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ author, publisher ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ @@ -91,13 +112,6 @@ lastname.content = inlines -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Language ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -language = element language { language.attributes } - -language.attributes = lang.attribute -lang.attribute = attribute xml:lang { xsd:language } - # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ place ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ place = element place { place.content } @@ -169,7 +183,7 @@ division = element division { division.content } division.content = - metadata?, + division.metadata?, (division+ | topic+) @@ -190,8 +204,11 @@ topic.id.attribute = attribute xml:id { xsd:ID } topic.type.attribute = attribute type { xsd:NCName } +top.topic.content = + top.metadata?, + section+ topic.content = - metadata?, + component.metadata?, section+ @@ -204,7 +221,7 @@ section = element section { section.content, section.attributes } section.content = - metadata?, + section.metadata?, (section+ | block+) section.attributes = @@ -218,7 +235,7 @@ # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ block ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -block = (parag | \list | table | speech | media) +block = (parag | speech | \list | table | media) # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ parag ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ @@ -228,6 +245,26 @@ inlines & link* +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 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 + # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ list ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ # ~~~~~~ list @@ -317,26 +354,6 @@ caption.content = parag+ -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 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 diff -r ca367d4d080b -r e448c6a000e5 RelaxNG/publiset.rnc --- a/RelaxNG/publiset.rnc sam. juin 11 20:35:18 2011 +0200 +++ b/RelaxNG/publiset.rnc dim. juin 12 14:17:23 2011 +0200 @@ -70,20 +70,25 @@ remap.attributes metadata.content = - title? - & subtitle? + (title, subtitle?)? + & language? & author* & publisher? - & language? & source? # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ title, subtitle ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ title = element title { title.content } +subtitle = element subtitle { title.content } title.content = inlines -subtitle = element subtitle { title.content } +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ language ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +language = element language { language.attributes } + +language.attributes = lang.attribute +lang.attribute = attribute xml:lang { xsd:language } # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ author, publisher ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ @@ -109,13 +114,6 @@ lastname.content = inlines -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Language ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -language = element language { language.attributes } - -language.attributes = lang.attribute -lang.attribute = attribute xml:lang { xsd:language } - # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ source ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ # ~~~~~~ source diff -r ca367d4d080b -r e448c6a000e5 Xml/Documents/demi-douce.xml --- a/Xml/Documents/demi-douce.xml sam. juin 11 20:35:18 2011 +0200 +++ b/Xml/Documents/demi-douce.xml dim. juin 12 14:17:23 2011 +0200 @@ -5,11 +5,11 @@ La demi-douce Récit + HenriOstrowiecki Les éditions des Rosiers - C'est l'histoire d'un petit garçon qui faillit ne jamais avoir 5 ans diff -r ca367d4d080b -r e448c6a000e5 Xml/Documents/torture_test.xml --- a/Xml/Documents/torture_test.xml sam. juin 11 20:35:18 2011 +0200 +++ b/Xml/Documents/torture_test.xml dim. juin 12 14:17:23 2011 +0200 @@ -44,9 +44,6 @@ Les misérables Extrait - - VictorHUGO - Cosette et Marius tombèrent à genoux, éperdus, étouffés de larmes, @@ -69,6 +66,34 @@ + Les dialogues + +
+ + Cyrano de Bergerac + Extrait + + + Le fâcheux + + Quoi, pas un grand seigneur pour couvrir de son nom ?… + + + + Cyrano + agacé + + Non, ai-je dit deux fois. Faut-il donc que je trisse ?… + + + Non, pas de protecteur…mais une protectrice ! + + +
+
+ + + Les listes
@@ -139,29 +164,35 @@ - Les dialogues + Les tableaux
- - Cyrano de Bergerac - Extrait - - - Le fâcheux - - Quoi, pas un grand seigneur pour couvrir de son nom ?… - - - - Cyrano - agacé - - Non, ai-je dit deux fois. Faut-il donc que je trisse ?… - - - Non, pas de protecteur…mais une protectrice ! - - + + + + + head 1.1 + head 1.2 + head 1.3 + + + + + cell 1.1 + cell 1.2 + cell 1.3 + + + cell 2.1 + cell 2.2 + cell 2.3 + + + + +
+ Légende du tableau +