How to hide some segments of the source text

Hi, 

I have a source text in which there are segments in English mixed with previously translated segments (Spanish).

Can I hide the already translated text in the editor and see only English segments in the source text column?

Thanks, 

Marta 

emoji
  •  

    I hope your research goes well.

    A couple of things:

    • When I said that Trados was extracting both English and Spanish, I was wrong: Trados Studio is extracting only Spanish (whether already localised or to be localised).
    • I remember there was a plugin for JSON files more advanced than the built-in file type. I can’t find it now.

    If nothing works, I’d prepare it in the old way, when there were not so many useful filetypes: In Excel!

    And this is the way:

    Copy the whole content of the JSON file and paste it to the first column of an empty Excel spread sheet. Use the columns on the right to extract both the English and Spanish strings, and compare them. If they are the exactly the same string, set that cell with the content of the English text; if they are different, it means that they have been already translated, so leave that cell empty. You can do this via Excel formulas.

    At this point you have a column with only English strings to be translated, correct? Copy and paste this column to an empty TXT, save it and open it in Studio. You’ll need to set some placeholders as tags in Studio, such as {{SOMETHING_GOES_HERE}}.

    After translation of the TXT, copy and paste the translated text into another column in the previous Excel spread sheet. Now use more formulas to merge the original line with your translation. The logic behind is that if English and Spanish original strings are different, then the original line goes to the cell; if they are the same, then your translation shoud be used instead of the original Spanish string. If you have followed me till here, now you just need to copy that final column and replace the content of the original JSON file, and that's it!

    You can have this working in one hour. Not fun, but maybe better that locking segments in Trados Studio.

    emoji
  • You can try this regex replacement in Notepad++ (make a copy before you proceed with replacing):

    Find what: ("[<>\.\,\;\:\?\!\(\)\{\}\[\]0-9\w+_\s-]+"):\s((?>(?!\1))"([^"]+)")
    Replace with: \1: "\3 @@@"

    Then import the new file into Trados. 
    The translated segments in Spanish would be marked with " @@@" . Then you can filter for @@@ in source, copy source to target and lock all with Ctrl+L.
    Then translate the unlocked segments and save target as *.json. Open the target file with Notepad++ again and delete all instances of " @@@" by replacing it with nothing (blank Replace with field).

    If there are some characters in your strings that are not present in the find what regex, the replacement won't work for that string and you may need to modify the regex by adding the missing characters.

    emoji
  •  

    Getting it into Studio is 1 matter.
    Delivering back out is another.

    What is your goal?

    • Translate and give them a TM?
    • Translate source and over write your target?
    • More like a review of source/target and therefore get Studio to respect current JSON content
    • Give a reviewed file back in any format
    • Give an updated/reviewed JSON back?

    Without overthinking - I can easily tell you how to get Studio to respect your current JSON content.
    Respecting source segments which align with target translations. But the format will ultimately not be JSON 

    However before I open options up I want to hear what is your end goal because I need to be mindful of the file formats and evaluate if we are limited 

    Lyds

    Lydia Simplicio | 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
  • Hi Jesús, 
    Thank you for your answer.
    In this case, I don't think it is worth investigating how to separate the source texts.
    I'll leave it as it is. 
    Many thanks for your and everyone's help. 

    Marta 

    emoji