W3C home > Mailing lists > Public > public-i18n-its@w3.org > July to September 2005

[ESW Wiki] Update of "its0509ReqNestedElements" by YvesSavourel

From: <w3t-archive+esw-wiki@w3.org>
Date: Wed, 07 Sep 2005 00:49:59 -0000
To: w3t-archive+esw-wiki@w3.org
Message-ID: <20050907004959.31624.59576@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/its0509ReqNestedElements


------------------------------------------------------------------------------
  '''[http://www.w3.org/International/geo/2004/article-devt-process.html Status: Initial Draft]''' 
  ie. please focus on technical content, rather than wordsmithing at this stage.
  
+ Author: Yves Savourel
+ 
+ = Nested Elements =
+ 
+ 
+ == Summary ==
+ 
+ [R022] Great care must be taken when defining or using nested translatable elements.
+ 
+ 
+ == Challenges ==
+ 
+ An XML can allow the recursive nesting of the same elements. In some cases such structure is detrimental to the localization process as it creates problems when segmenting or extracting the text.
+ 
+ An example, the <footnote> in OpenOffice documents:
+ 
+ A {{{<text:p>}}} element can contain a {{{<text:footnote>}}} element. The {{{<text:footnote>}}} includes a {{{<text:footnote-body>}}} element, which in turn, can also contain a {{{<text:p>}}} element. This may lead to situation where one or more paragraphs are embedded within each other.
+ 
+ {{{<text:p text:style-name="Text body">Donec leo massa, porttitor non, laoreet et, tincidunt nec, 
+ turpis<text:footnote text:id="ftn0"><text:footnote-citation>1</text:footnote-citation><text:footnote-body><text:p
+ text:style-name="Footnote">Here comes the first footnote's text.</text:p></text:footnote-body></text:footnote>. 
+ Morbi ultricies imperdiet erat<text:footnote 
+ text:id="ftn1"><text:footnote-citation>2</text:footnote-citation><text:footnote-body><text:p 
+ text:style-name="Footnote">Here comes the second footnote's text.</text:p></text:footnote-body></text:footnote>. Nam 
+ aliquam, magna eget eleifend varius, orci quam condimentum enim, in consectetuer neque purus a massa. Mauris 
+ gravida felis et neque. Nullam tristique arcu sed nulla.</text:p>}}}
+ 
+ Having two {{{<text:p>}}} elements withing a parent {{{<text:p>}}} element makes processing of the data difficult. For example it is more difficult, for most localization tools, to decide if {{{<text:p>}}} should be treated as inline code or not.
+ 
+ 
+ == Quick Guidelines ==
+ 
+ Do not allow the definition of a reference inside the structure where it's referenced. In other words, {{{</text:footnote-body>}}} should be outside {{{<text:p>}}}.
+ 
Received on Wednesday, 7 September 2005 06:39:28 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 8 January 2008 14:12:45 GMT