Translation of .ts files

Hi:

is it possible to translate .ts files with Studio 2022?

Regards,

Marta

emoji
Parents Reply
  • Good morning ,

    I guess I have a weakness for file types, so I tried this myself, and I could not get the Multilingual XML file type to work. I started out with your example TS file in the blog post you linked to:

    <?xml version="1.0" encoding="utf-8"?>
    <!DOCTYPE TS>
    <TS version="2.1" language="en_GB" sourcelanguage="es_ES">
      <context>
        <name>CutieCAT</name>
        <message>
          <location filename="multifarious/cutiecat.h"/>
          <source>Buscar las cinco patas al gato.</source>
          <translatorcomment>Means to attempt to solve an unsolvable situation
    or waste time looking for something that does not
    exist.</translatorcomment>
          <translation>Look for the five paws of the cat.</translation>
        </message>
        <message>
          <location/>
          <source>Aquí hay gato encerrado</source>
          <translation type="unfinished">Aquí hay gato encerrado</translation>
        </message>
      </context>
    </TS>

    Studio just won't use the Multilingual XML file type, although it's active and just under the SDLXLIFF file type. Studio takes the AnyXML file type or nothing, if I deactivate AnyXML (I gave the TS file an XML ending for this purpose):

    Trados Studio warning dialog box stating 'Cannot find file type settings for the preview file.' with a conversion progress bar in the background.

    I tried Okapi Rainbow, which supports TS, and it's a really simple out-of-the-box case which has really nice results:

    Trados Studio editor window showing a translation segment with a translator comment 'Means to attempt to solve an unsolvable situation or waste time looking for something that does not exist.'

    Notice how the translatorcomment content is imported as Studio comment? Nice! So Okapi -> XLIFF, the Studio (which was a bit reluctant to accept the XLF, see below), Studio will return an XLF which you would have to convert back to TS using Okapi.

    Studio did funny stuff:

    Trados Studio new project creation window with a warning message 'The file contains target language content in 'English (United Kingdom)'. The file cannot be added, since it is not one of the project target languages.'

    I overcame this by adding en-US to the target languages, at which Studio agreed to accept the file. Then I removed en-US from the target languages again and everything went smoothly.

    emoji


    Generated Image Alt-Text
    [edited by: RWS Community AI at 9:18 AM (GMT 0) on 22 Jan 2025]
Children
  •  

    Your settings are incorrect, you added a forward slash to the location of the target.  Try these:

    Screenshot of Trados Studio Project Settings showing Language Mapping for Multilingual XML with Spanish source and English translation.

    That works just fine:

    Trados Studio translation segment window with Spanish text 'Buscar las cinco patas al gato.' and its English translation 'Look for the five paws of the cat.'

    However, you don't get the comment... so probably better to either use QT Linguist (I just installed it using the links in my article on this new laptop and it still works), convert to XLF as then you get the comment as Daniel showed, or use Okapi as he also explained.

    I've always found Okapi to be a little clunky and it often causes me problems so I tend to steer clear of it unless necessary.  There are definitley featiures of the full toolset I really like, but in this case I think I'd go QT Linguist -> XLF -> Trados Studio and then back to QT Linguist to get the translated TS file.

    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: RWS Community AI at 11:09 AM (GMT 0) on 22 Jan 2025]