W3C home > Mailing lists > Public > public-i18n-its@w3.org > January to March 2006

[ESW Wiki] Update of "its0601TechLangDev" by YvesSavourel

From: <w3t-archive+esw-wiki@w3.org>
Date: Tue, 31 Jan 2006 11:38:46 -0000
To: w3t-archive+esw-wiki@w3.org
Message-ID: <20060131113846.14730.15444@localhost.localdomain>
Dear Wiki user,

You have subscribed to a wiki page or wiki category on "ESW Wiki" for change notification.

The following page has been changed by YvesSavourel:
http://esw.w3.org/topic/its0601TechLangDev


------------------------------------------------------------------------------
  See the [http://www.w3.org/TR/REC-xml/#sec-lang-tag Language Identification] section in the XML Specification for more information.
  
  
- === How to include xml:lang in XML Schema ===
+ === Including xml:lang in XML Schema ===
  
  To include the xml:lang attribute in your XSD document, import the W3C xml.xsd schema in your own XSD schema using the <xsd:import> element as shown below:
  
@@ -39, +39 @@

   ...}}}
  
  
- === How to include xml:lang in Relax NG ===
+ === Including xml:lang in Relax NG ===
  
- '''[[YS-]] I Need help for this part: If any Relax-NG expert wants to volonteer, please do so.'''
+ In RELAX NG, declare xml:lang directly in your schema.
  
- '''[[FS-]] This example is based upon a schema from Sebastian, I hope he is fine with it.''']]]'''
+ {{{<define name="att.global.attribute.xmllang">
+  <optional>
+   <attribute name="xml:lang">
+    <a:documentation>indicates the language of the element content using the
+       codes from RFC 3066
+    </a:documentation>
+    <ref name="data.language"/>
+   </attribute>
+  </optional>
+ </define>
+ <define name="data.language">
+  <data type="language"/>
+ </define>}}}
  
- In RELAX NG, you don't have to import the XML namespace. You can declare xml:lang directly in your schema.
+ Then, you can reference this declaration in any of your element declarations.
  
- {{{
+ {{{<element name="myDoc">
+ ...
-  <define name="att.global.attribute.xmllang">
+  <ref name="att.global.attribute.xmllang"/>
+ </element>}}}
-     <optional>
-       <attribute name="xml:lang">
-         <a:documentation>indicates the language of the element content using the
-       codes from RFC
-       3066</a:documentation>
-         <ref name="data.language"/>
-       </attribute>
-     </optional>
-   </define>
-  <define name="data.language">
-     <data type="language"/>
-   </define>
- }}}
  
- You then can reference to this declaration in any of your element declarations.
- 
- {{{
- <element name="myDoc">
- ...
- <ref name="att.global.attribute.xmllang"/>
- </element>
- }}}
- 
- === How to include xml:lang in XML DTD ===
+ === Including xml:lang in XML DTD ===
  
  For example, to add xml:lang to a <para> element you can specify the following DTD constructs:
  
Received on Tuesday, 31 January 2006 18:24:01 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 20:43:06 UTC