OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.


Help: OASIS Mailing Lists Help | MarkMail Help

xliff message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [Elist Home]

Subject: [xliff] element 'defaults' proposal

Hi all,

Many specifications in the XML realm do mention defaulting mechanisms. The XML specification itself,
for example, does this wrt. 'xml:lang':

>The intent declared with xml:lang is considered to apply to all attributes and content of the
>element where it is specified, unless overridden with an instance of xml:lang on another 
>element within that content.

If I understand correctly, we do not currently have a home in XLIFF for defaults. Saying sth. like

>'maxwidth' for every 'trans-unit' should be '72', unless overridden.

at the moment does not seem to be possible.

Accordingly, I would like to suggest the following (I realize that it is quite late to discuss this
for 1.1 but it would ensure that it isn't just another prop):

A. Add an element 'default' to XLIFF which is further specified by the XSD/DTD code
   fragment given below. Furthermore, add an element 'defaults' which holds one or more
   'default' elements. The mandatory 'item' attribute for 'default' designates the
   object(s) to which a default applies (the designator is an Xpath expression). The
   default setting itself is the content of the 'default' element.


		<default item="//trans-unit/@maxwidth>72</default>
		<default item="//trans-unit/reformat/@edit">yes</default>
   Two defaults encoded here are: 'maxwidth=72' for all trans-units, and 'edit=yes' for
   all 'reformat' elements of trans-units.

B. The semantics and use of the 'default' element are as follows:

	The intent declared with 'default' is considered to apply to all objects designated
	by the 'item' attribute, unless overridden at the object itself.

C. The element may appear as a child of both 'xliff' and 'header'.

D. XLIFF processors may use the information in the 'default' element.

E. XSD/DTD code fragment

	<!ELEMENT defaults (default+)>
	<!ELEMENT default (#PCDATA)>
	<!ATTLIST default
		item	CDATA #required>

	<xs:element name="default">
			<xs:documentation> container element</xs:documentation>
			<xs:attribute name="item" type="xs:string" use="required">
					<xs:documentation source="designate the object(s) to which a default applies"/>
	<xs:element name="defaults">
			<xs:documentation> designates a default setting for an item (for example the value of an attribute)</xs:documentation>
				<xs:element ref="default" maxOccurs="unbounded"/>

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [Elist Home]

Powered by eList eXpress LLC