<?xml version='1.0'?>
<schema
  xmlns='http://www.w3.org/1999/XMLSchema'
  targetNamespace='http://www.w3.org/XML/2000/04schema-hacking/html-renamed'
  xmlns:t='http://www.w3.org/XML/2000/04schema-hacking/html-renamed'>

  <import namespace="http://www.w3.org/XML/1998/namespace"/>

 <element name='html'>
  <complexType content='elementOnly'>
   <element ref='t:head'/>
   <element ref='t:body'/>
   <attributeGroup ref='t:i18n'/>
  </complexType>
 </element>

 <attributeGroup name='i18n'>
   <attribute ref='xml:lang'/> <!-- LanguageCode -->
   <attribute name='lang'/>
   <attribute name='dir'>
     <simpleType base='string'>
       <enumeration value='ltr'/>
       <enumeration value='rtl'/>
     </simpleType>
   </attribute>
 </attributeGroup>

 <element name='head'>
  <complexType content='elementOnly'>
   <element ref='t:title'/>
  </complexType>
 </element>

 <element name='title'>
  <complexType content='mixed'>
  </complexType>
 </element>

 <element name='body'>
  <complexType content='elementOnly'>
   <choice minOccurs='0' maxOccurs='unbounded'>
    <element ref='t:block'/>
   </choice>
  </complexType>
 </element>

 <element name='block' abstract='true'/>

 <element name='h1' equivClass='t:block'>
  <complexType content='mixed'>
   <sequence minOccurs='0' maxOccurs='unbounded'>
    <element ref='t:a'/>
   </sequence>
  </complexType>
 </element>

 <element name='h2' equivClass='t:block'>
  <complexType content='mixed'>
   <sequence minOccurs='0' maxOccurs='unbounded'>
    <element ref='t:a'/>
   </sequence>
  </complexType>
 </element>

 <element name='h3' equivClass='t:block'>
  <complexType content='mixed'>
   <sequence minOccurs='0' maxOccurs='unbounded'>
    <element ref='t:a'/>
   </sequence>
  </complexType>
 </element>

 <element name='p' equivClass='t:block'>
  <complexType content='mixed'>
   <sequence minOccurs='0' maxOccurs='unbounded'>
    <element ref='t:a'/>
   </sequence>
   <anyAttribute namespace="##other" processContents="strict"/>
  </complexType>
 </element>

 <element name='address' equivClass='t:block'>
  <complexType content='mixed'>
   <choice minOccurs='0' maxOccurs='unbounded'>
    <element ref='t:a'/>
    <element ref='t:img'/>
   </choice>
  </complexType>
 </element>

 <element name='a'>
  <complexType content='mixed'>
   <attribute name='href' type='string' use='optional'/>
   <attribute name='name' type='NMTOKENS' use='optional'/>
  </complexType>
 </element>

 <element name='img'>
  <complexType content='empty'>
   <attribute name='src' type='string' use='required'/>
  </complexType>
 </element>
</schema>
