Creating an XLIFF file that preserves inline tags with Tikal

109 views
Skip to first unread message

Ruediger Landmann

unread,
Nov 6, 2020, 2:25:42 AM11/6/20
to okapi-users
Hi -- 

I'm completely new to Okapi and am trying to use Tikal to prepare some DocBook documentation for translation. 

When I run: 

tikal -x Release_Notes.xml

Tikal creates Release_Notes.xml.xlf as expected. However, the strings in the original XML document are segmented whenever an inline tag appears. For example,

<para>You can perform an in-place upgrade using the <literal>Leapp</literal> utility.</para>

appears in the xliff file as three separate units:

<trans-unit id="21">
<source xml:lang="en">You can perform an in-place upgrade using the  </source>
<target xml:lang="fr"></target>
</trans-unit>
<trans-unit id="22">
<source xml:lang="en">Leapp</source>
<target xml:lang="fr"></target>
</trans-unit>
<trans-unit id="23">
<source xml:lang="en"> utility.</source>
<target xml:lang="fr"></target>
</trans-unit>

and I was hoping to see the bpt/ept notation used, like in this entry from our translation memory: 

<seg>You can perform an in-place upgrade using the  <bpt i="1" x="1"/>Leapp<ept i="1"/> utility.</seg>

What am I doing wrong please?

--Rudi


Yves Savourel

unread,
Nov 6, 2020, 2:41:40 AM11/6/20
to Ruediger Landmann, okapi-users

Hi Rudi,

 

Because the filter cannot guess what the tags of your XML file corresponds to, you have to provide rules for them. For example, tell which elements should be treated as inline vs which ones denote hard breaks in the content.

 

See details on the configuration of the filter here: https://okapiframework.org/wiki/index.php/XML_Filter

And more information about ITS here: https://www.w3.org/TR/its20/.

 

For instance, your <literal> elements should be declared as “element-within-text” to not break the sentences.

See ITS case for that here: https://www.w3.org/TR/its20/#elements-within-text (Example 47 shows a rule making some elements inline).

 

Hope this helps.

-yves

--
You received this message because you are subscribed to the Google Groups "okapi-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to okapi-users...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/okapi-users/17be68c9-fa3f-42fe-bd6b-f549aeb999ffn%40googlegroups.com.

Ruediger Landmann

unread,
Nov 7, 2020, 12:18:32 AM11/7/20
to okapi-users
Thanks Yves for the quick reply! This opens the door for me to venture further! :) 
Reply all
Reply to author
Forward
0 new messages