Markups-Tags in XLIFF files seen as text not as tags

Hi,

I often received XLIFF files with texts that contains tags such as {1> SENTENCE.<1}, or {/b> SENTENCE.<\b} etc. These markups are not recognised as tags but as text. That means that I have to type manually {1> SENTENCE.<1}.

Is there a way to 'tell' Studio to treat those markups as tags to simplify the translation process.

Thank you for your response.

Manuella

emoji
Parents
  •  

    You can use the embedded content settings in the XLIFF Filetype.  You need to do this BEFORE you create your project and just create a single placeholder rule with an expression like this:

    {[^}]+}

    Trados Studio options menu with Embedded content selected, showing the AddEdit Embedded Content Rule dialog with a regular expression placeholder rule defined.

    Paul Filkin | RWS Group

    ________________________
    Design your own training!

    You've done the courses and still need to go a little further, or still not clear? 
    Tell us what you need in our Community Solutions Hub

    emoji


    Generated Image Alt-Text
    [edited by: Trados AI at 12:41 PM (GMT 0) on 29 Feb 2024]
  • Hi Paul,

    Thanks for your response but I am not very familiar with Regex rules. Do I need to create the rule as you have indicated {[^]+} or to mention each of the tags for ex. {<1 in between the brackets[.. ]. AND do I need to do it before EACH project or is it enough to go to options>Files type>Xliff>Embedded content and to do it for once and for all?

    emoji
  •  

    Do I need to create the rule as you have indicated {[^]+} or to mention each of the tags for ex. {<1 in between the brackets[.. ].

    As I indicated.  If all of your codes follow the same pattern as you have shown here then the regex I gave you will catch them all.  However, as I was writing the explanation for you I realised I didn't do this correctly.  That regex would have captured the entire string:

    {1> SENTENCE.<1}

    I read it too quickly and didn't notice you probably meant this to be a representation of something like this:

    {1> This is some text that needs to be translated.<1}

    {1> Here's some more translatable text.<1}

    {/b> Here's some bold text.<\b}

    It definitely helps to provide a proper snippet of code when you want help so it's 100% clear what your needs are.  However, there is another reason why a snippet is very important.  Tags like these are going to be invalid in XLIFF unless they are written in CDATA or use compliant tags.

    So, before I try to explain how to do this properly (the regex is the easy bit) can you provide a small snippet of the actual file?  Should be easy to replace the translatable text for a few lines with something that won't break an NDA.  Is it something like this:

    <trans-unit id="1">
    <source><ph id="1">{1&gt;</ph> This is some text that needs to be translated.<ph id="2">&lt;1}</ph></source>
    <target><ph id="1">{1&gt;</ph> This is some text that needs to be translated.<ph id="2">&lt;1}</ph></target>
    </trans-unit>

    Or this:

    <trans-unit id="1">
    <source><![CDATA[{1> This is some text that needs to be translated. <1}]]></source>
    <target><![CDATA[{1> This is some text that needs to be translated. <1} ]]></target>
    </trans-unit>

    for example?  Or something else altogether?

    If you can share a complete file it's even better, but this much at least would help provide you a better answer.

    Paul Filkin | RWS Group

    ________________________
    Design your own training!

    You've done the courses and still need to go a little further, or still not clear? 
    Tell us what you need in our Community Solutions Hub

    emoji
  • Here is an example of a source file. I have send the file via e-mail to your adress @sdl.com.

    Leadership is {u>not<u} a position or title.
    Leadership is {u>not<u} seniority in an organization.

    {b>Program Objectives <b}(continued)

    {i>www.businessdictionary.com<i}

    emoji
  •   

    Thanks for the file.  If you had opened it with a text editor to check what the filetype was so you could determine how to handle it you would have seen this:

    xmlns:m="www.memsource.com/.../2.0"

    This is telling you that the file comes from Memsource, or Phrase as they're called today.  In Studio we have an XLIFF filetype specifically for this customised version of XLIFF.  If you use this filetype you will see this:

    Screenshot showing two sentences correctly tagged in the editor.

    For some reason the filetype extension has been changed to XLIFF, when it was probably MXLIFF originally.  However, if you either change it to *.mxliff, or add *.xliff to the  "File dialog wildcard expression:" then you'll be able to use it:

    Screenshot of file type settings within a software's options menu, with a focus on the 'XLIFF: Memsource Xliff' type. Settings displayed include the file type name, identifier, and filename patterns for individual and category documents, with file extensions '.mxliff' and '.xliff' listed under the file dialog wildcard expression.

    If you decide to add *.xliff to the memource filetype rather than rename the extension then make sure you also uncheck the vanilla XLIFF filetype above the memsource filetype before creating your project.  If you don't the XLIFF filetype will continue to be used:

    Screenshot of the 'File Types' section within the Trados Studio options menu, showing a list of file types and their extensions. A red arrow points to the 'File Types' section, highlighting enabled options for various XLIFF file formats used for translation and localization.

    Paul Filkin | RWS Group

    ________________________
    Design your own training!

    You've done the courses and still need to go a little further, or still not clear? 
    Tell us what you need in our Community Solutions Hub

    emoji
Reply
  •   

    Thanks for the file.  If you had opened it with a text editor to check what the filetype was so you could determine how to handle it you would have seen this:

    xmlns:m="www.memsource.com/.../2.0"

    This is telling you that the file comes from Memsource, or Phrase as they're called today.  In Studio we have an XLIFF filetype specifically for this customised version of XLIFF.  If you use this filetype you will see this:

    Screenshot showing two sentences correctly tagged in the editor.

    For some reason the filetype extension has been changed to XLIFF, when it was probably MXLIFF originally.  However, if you either change it to *.mxliff, or add *.xliff to the  "File dialog wildcard expression:" then you'll be able to use it:

    Screenshot of file type settings within a software's options menu, with a focus on the 'XLIFF: Memsource Xliff' type. Settings displayed include the file type name, identifier, and filename patterns for individual and category documents, with file extensions '.mxliff' and '.xliff' listed under the file dialog wildcard expression.

    If you decide to add *.xliff to the memource filetype rather than rename the extension then make sure you also uncheck the vanilla XLIFF filetype above the memsource filetype before creating your project.  If you don't the XLIFF filetype will continue to be used:

    Screenshot of the 'File Types' section within the Trados Studio options menu, showing a list of file types and their extensions. A red arrow points to the 'File Types' section, highlighting enabled options for various XLIFF file formats used for translation and localization.

    Paul Filkin | RWS Group

    ________________________
    Design your own training!

    You've done the courses and still need to go a little further, or still not clear? 
    Tell us what you need in our Community Solutions Hub

    emoji
Children