[xliff-tools] C-format annotations
Asgeir Frimannsson
asgeirf at redhat.com
Mon Feb 21 21:00:35 PST 2005
On Thu, 17 Feb 2005 01:06, Bruno Haible wrote:
> 1.4.1.4.2. C-format
>
> <x> seems to be a more suitable placeholder than <it>: it does not require
> a pos="open" attribute.
> Unsolved question: How does this deal with reordering (in C, the POSIX
> "%2$d" syntax)?
>
> Also it makes it impossible to replace %d with %Id - an option needed by
> Farsi translators.
Section 2.4 (Inline Elements) in the XLIFF spec has a good explaination of
inline elements:
There are three different types of inline elements:
1. Elements that have a content, and for which this content is the actual
native code of the original data (escaped for XML if necessary). These
elements are: <bpt>, <ept>, <it>, and <ph>.
2. Elements that are empty and act has placeholders for a native code that
is either in the Skeleton file or generated automatically. these elements
are: <g>, <bx/>, <ex/>, and <x/>.
3. The <sub> element, which can be inside <bpt>, <ept>, <it>, and <ph> to
delimit a translatable run of text within a native inline code, for example
the value of an ALT attribute in a <IMG> element in HTML.
Using <x/> would mean that translators can't change the code data. As you
mention, translators must be able to change the parameters, so we need to
choose one of the alternatives in option 1. After reading your comment on the
pos attribute, I would propose <ph> as the most ideal attribute, as this
doesn't have the consept of opening/closing tag, and can contain code data
which translators can edit.
> How does this relate to <context context-type="numparams"> ?
I guess it would make sense to set this to the number of parameters in
<source>? That would also make it possible for back-converters to check for
correct number of parameters.
cheers,
asgeir
More information about the xliff-tools
mailing list