[tei-council] Wot is wrong with my ODD?

Martin Holmes mholmes at uvic.ca
Fri Jun 6 17:18:40 EDT 2014


I'm trying to create a content model for <seg> using the new TEI ODD 
elements. I want to allow any of a small number of elements, with text 
mixed in, or just text. I have this:

<elementSpec ident="seg" mode="change">
   <content>
     <alternate allowText="true">
       <macroRef key="data.text"/>
       <sequence allowText="true" preserveOrder="false" minOccurs="0">
         <elementRef key="orgName" maxOccurs="unbounded" minOccurs="0"/>
         <elementRef key="persName" maxOccurs="unbounded" minOccurs="0"/>
         <elementRef key="choice" maxOccurs="unbounded" minOccurs="0"/>
         <elementRef key="seg" maxOccurs="unbounded" minOccurs="0"/>
         <elementRef key="trait" maxOccurs="unbounded" minOccurs="0"/>
       </sequence>
     </alternate>
   </content>
</elementSpec>

but the result is a content model which does not allow text between 
elements.

I've also tried this:

<elementSpec ident="seg" mode="change">
   <content>
       <sequence allowText="true" preserveOrder="false" minOccurs="0">
	<macroRef key="data.text"/>
         <elementRef key="orgName" maxOccurs="unbounded" minOccurs="0"/>
         <elementRef key="persName" maxOccurs="unbounded" minOccurs="0"/>
         <elementRef key="choice" maxOccurs="unbounded" minOccurs="0"/>
         <elementRef key="seg" maxOccurs="unbounded" minOccurs="0"/>
         <elementRef key="trait" maxOccurs="unbounded" minOccurs="0"/>
       </sequence>
   </content>
</elementSpec>

but this does not allow only text content. I've tried it with and 
without the macroRef, with the same result.

It looks to me as though "allowText='true'" is not quite functioning the 
way it seems that it should. Am I missing something? What's the right 
way to do this?

Cheers,
Martin


More information about the tei-council mailing list