[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]
Subject: RE: [okapi-devel] Global <gls:glossary> element in XLIFF 2.0?
Hi Martin, Actually there is another way to point to glossary data. The Term annotation, which is part of the Core, can use the ref attribute to point to information about the denoted term (See http://docs.oasis-open.org/xliff/xliff-core/v2.0/xliff-core-v2.0.html#termAnnotation) so you could do something like this: <xliff xmlns='urn:oasis:names:tc:xliff:document:2.0' version='2.0' srcLang='en' trgLang='fr' xmlns:gls="urn:oasis:names:tc:xliff:glossary:2.0"> <file id='1'> <unit id="1"> <gls:glossary> <gls:glossEntry id='g1'> <gls:term source="publicTermbase">TAB key</gls:term> <gls:translation id="1" source="myTermbase">Tabstopptaste </gls:translation> <gls:translation source="myTermbase">TAB-TASTE </gls:translation> <gls:definition source="publicTermbase">A keyboard key that is traditionally used to insert tab characters into a document. </gls:definition> </gls:glossEntry> </gls:glossary> <segment> <source>Press the <mrk id="m1" type="term" ref="#gls=g1">TAB key</mrk>.</source> <target>Drücken Sie die <mrk id="m2" type="term" ref="#gls=g1">TAB-TASTE</mrk>. </target> </segment> </unit> </file> </xliff> As you can see the pointing is done from the <mrk> to the glossary entry, rather than the reverse. That allows several occurrences of the same term in a single unit to refer to a single glossary entry. The tricky part is to remember to use a URI in the ref of the <mrk>, not just an ID. In this case ref="#gls=g1" will be resolved as "f=1/u=1/gls=g1" and will point to the corresponding <gls:glosEntry> element. You can verify this online here: http://okapi-lynx.appspot.com/fragments Or you can use the –vr command of Lynx, the little tool that comes with the XLIFF2 toolkit distribution (https://bintray.com/okapi/Distribution/Okapi_XLIFF_Toolkit, (BTW we need to release 1.0.1 there)). I hope this helps, -yves From: Yves Savourel [mailto:ysavourel@enlaso.com] Hi Martin, Yes, I suppose: pointing to the first occurrence is the only option. It’s not great as the several occurrences may be in separate segments, and thus treated separately from the user viewpoint. Maybe someone in the XLIFF TC has some idea how to address that use case? Cheers, -yves From: okapi-devel@googlegroups.com [mailto:okapi-devel@googlegroups.com] On Behalf Of Martin Wunderlich Hi, |
[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]