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] | [List Home]


Subject: RE: [xliff] Discussion: XLIFF inline elements attribute...


Andrzej,

My notes indicate that the attribute would be available in inline tags, but
not for tags that contain translatable text. I think the attribute is not
applicable to the <sub> tag because it always contains translatable text.

So the example becomes:

<source>Start<bpt id="2" lex-equiv="_">code<sub>Text</sub></bpt>end<ept
id="2">code</ept></source>

As you pointed out, it's unclear what to do with the text in the <sub>
element.

Here are the options:

1. Replace bpt element, but <sub> text is lost: 

"Start_end"

2. Replace bpt open tag and keep <sub>: 

"Start_Textend"

3. Replace both open and close bpt tags and keep <sub> text:

"Start_Text_end"

Of course, the bpt may contain more than one <sub> or no <sub> elements at
all.

If not <sub> element is present, then option 1 (or 2) is preferred.

1. if no <sub> text, simply replace btp element:

"Start_end"

If multiple <sub> elements are present, then it's more complicated, but
option 3 is probably preferred.

3. if more than one <sub>, surround each with the equiv text:

"Start_Text1_Text2_end"

In the extraction filters I've written for XHTML, I don't use <sub>. If
there's translatable text in an attribute, such as <img alt="translatable
text"/>, then another <trans-unit> is made for it. But I can imagine cases
where the <sub> text should be inline.

In summary, here's a proposed algorithm.

For inline tags that may contain <sub> elements, replace the open tag with
the equivalent text. For each <sub> tag, emit the text of the <sub> tag
FOLLOWED BY the equivalent text.

Example XSLT,

<?xml version='1.0'?>
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform";>

<xsl:template match="source">
	<xsl:apply-templates select="*|text()"/>
</xsl:template>

<xsl:template match="bpt|ept">
	<xsl:variable name="equiv-text" select="@lex-equiv"/>
	<xsl:value-of select="$equiv-text"/>
	<xsl:for-each select="sub">
		<xsl:copy-of select="text()"/>
		<xsl:value-of select="$equiv-text"/>
	</xsl:for-each>
</xsl:template>

</xsl:stylesheet>



Regards,
 
Doug Domeny
Software Analyst
 
Ektron, Inc.
+1 603 594-0249 x212
http://www.ektron.com
 

-----Original Message-----
From: Andrzej Zydron [mailto:azydron@xml-intl.com] 
Sent: Friday, March 10, 2006 11:14 AM
Cc: xliff@lists.oasis-open.org
Subject: Re: [xliff] Discussion: XLIFF inline elements attribute...

Hi Everyone,

I have been doing the write up on this issue and have hit the following 
problem:

<source>Start<bpt id="2">code<sub 
lex-replace="_">Text</sub></bpt>end<ept id="2">code</ept></source>

Will require that the replacement value is applied logically to both 
start and end tags:

<source>Start<bpt/><sub>_Text_</sub><bpt/>end<ept/></source>

This is fine for spaces, but could be a problem with say string values 
such as 'abc'. We may require two attributes. One for white space and 
one for other values.

Any ideas/comments?

Thanks in advance,

AZ

Tony Jewtushenko wrote:
> As per discussion proposed by Andzrej:
> 
>  
> 
> XLIFF inline elements with spacial characteristics: 
> http://lists.oasis-open.org/archives/xliff/200603/msg00001.html
> 
> Response from Florian: 
> http://lists.oasis-open.org/archives/xliff/200603/msg00005.html
> 
> Response from Andzrej: 
> http://lists.oasis-open.org/archives/xliff/200603/msg00006.html
> 
>  
> 
> We need to select an appropriate name for the attribute.  Suggestions so 
> far are:
> 
>  
> 
>     * rawreplace
>     * textequivalent
>     * textapproximation
>     * subst
>     * equiv
>     * equiv-lex
>     * lev-equiv
>     * lex-replace
> 
> *Please submit opinions on which suggestions are not suitable (ie.,  
> should not be considered),  and any new additions.  I would like to 
> submit a ballot on Tuesday with a recommendation.*
> 
> *Regards,*
> 
> *Tony*
> 
> * *
> 
> *Tony Jewtushenko*
> 
> Director- R&D - Product Innovator Ltd. (Ireland)
> 
> P: +353.1.8875183; M: +353.87.2479057; W: www.productinnovator.com 
> <http://www.productinnovator.com/>
> 
>  
> 
> 
>
----------------------------------------------------------------------------
-----------------------
> *Text inserted by Panda Platinum 2005 Internet Security:*
> 
> This message has NOT been classified as spam. If it is unsolicited mail 
> (spam), click on the following link to reclassify it: It is spam! 
> <http://127.0.0.1:6083/Panda?ID=pav_47692&SPAM=true>
>
----------------------------------------------------------------------------
-----------------------


-- 


email - azydron@xml-intl.com
smail - c/o Mr. A.Zydron
	PO Box 2167
         Gerrards Cross
         Bucks SL9 8XF
	United Kingdom
Mobile +(44) 7966 477 181
FAX    +(44) 1753 480 465
www - http://www.xml-intl.com

This message contains confidential information and is intended only
for the individual named.  If you are not the named addressee you
may not disseminate, distribute or copy this e-mail.  Please
notify the sender immediately by e-mail if you have received this
e-mail by mistake and delete this e-mail from your system.
E-mail transmission cannot be guaranteed to be secure or error-free
as information could be intercepted, corrupted, lost, destroyed,
arrive late or incomplete, or contain viruses.  The sender therefore
does not accept liability for any errors or omissions in the contents
of this message which arise as a result of e-mail transmission.  If
verification is required please request a hard-copy version. Unless
explicitly stated otherwise this message is provided for informational
purposes only and should not be construed as a solicitation or offer.





---------------------------------------------------------------------
To unsubscribe from this mail list, you must leave the OASIS TC that
generates this mail.  You may a link to this group and all your TCs in OASIS
at:
https://www.oasis-open.org/apps/org/workgroup/portal/my_workgroups.php 




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