- From: Yves Savourel <ysavourel@translate.com>
- Date: Mon, 13 Mar 2006 14:07:41 -0700
- To: <public-i18n-its@w3.org>
ITS and XHTML 1.0 Here is a try at XHTML with ITS. I've used the proposed notation. This is a possible ITS documentRule to handle XHTML files: (I though I had posted this altready, but can't find it in the mail archives, so here is it) <?xml version="1.0"?> <its:documentRules xmlns:its="http://www.w3.org/2005/11/its"> <!-- Namespace --> <its:ns its:prefix="h" its:uri="http://www.w3.org/1999/xhtml"/> <!-- Elements not to translate --> <its:translateRule its:selector="//h:del" its:translate="no"/> <its:translateRule its:selector="//h:script" its:translate="no"/> <its:translateRule its:selector="//h:style" its:translate="no"/> <!-- Special attributes: Note that some choices are just guess based on personal experience, for example I think hidden <input> fields are usually not transltable, but that may not be the case all the time. --> <its:translateRule its:selector="//h:*/@abbr" its:translate="yes"/> <its:translateRule its:selector="//h:*/@accesskey" its:translate="yes"/> <its:translateRule its:selector="//h:*/@alt" its:translate="yes"/> <its:translateRule its:selector="//h:*/@prompt" its:translate="yes"/> <its:translateRule its:selector="//h:*/@standby" its:translate="yes"/> <its:translateRule its:selector="//h:*/@summary" its:translate="yes"/> <its:translateRule its:selector="//h:*/@title" its:translate="yes"/> <its:translateRule its:selector="//h:input/@value" its:translate="yes"/> <its:translateRule its:selector="//h:input[@type='hidden']/@value" its:translate="no"/> <!-- Often-used translatable meta content. --> <its:translateRule its:selector="//h:meta[@name='keywords']/@content" its:translate="yes"/> <its:translateRule its:selector="//h:meta[@name='description']/@content" its:translate="yes"/> <!-- Terminology helper --> <its:termRule its:selector="//h:dt" its:term="yes"/> <!-- XHTML 1.1 bidi markup --> <its:dirRule its:selector="//h:*[@dir='ltr']" its:dir="ltr"/> <its:dirRule its:selector="//h:*[@dir='rtl']" its:dir="rtl"/> <its:dirRule its:selector="//h:bdo[@dir='ltr']" its:dir="lro"/> <its:dirRule its:selector="//h:bdo[@dir='rtl']" its:dir="rlo"/> <!-- Elements within text --> <its:withinTextRule its:selector="//h:abbr | //h:acronym | //h:br | //h:cite"/> <its:withinTextRule its:selector="//h:code | //h:dfn //h:em | //h:strike | //h:u"/> <its:withinTextRule its:selector="//h:kbd | //h:q | //h:samp | //h:span"/> <its:withinTextRule its:selector="//h:strong | //h:var | //h:b | //h:isindex"/> <its:withinTextRule its:selector="//h:big | //h:hr | //h:i | //h:small | //h:sub"/> <its:withinTextRule its:selector="//h:sup | //h:tt" //h:del | //h:ins | //h:bdo"/> <its:withinTextRule its:selector="//h:img | //h:a | //h:font | //h:center | //h:s"/> <!-- Language mapping not sure about the value for langMap, shouldn't it "//*/@lang"? --> <its:langRule its:langMap="@lang" /> <!-- There is no ruby markup in XHTML 1.0 --> </its:documentRules>
Received on Monday, 13 March 2006 21:08:09 UTC