Change a segment, if the segment before has certain content

I have the following situation:

In Polish the name of the color will get a different ending, depending on the gender. So I have for example for "red" "czerwony, czerwona, czerwone".

This makes it impossible to translate red to one of those in a highly repetitive file, where I have partially >2000 such position. To make this translation fast, I translated all colors like this "red = kolor: czerwony" (which simply means adding the word "color" before each color name, what makes this repetitive again, as then the name of the color does not depend on gender). This was a good idea, until the customer has changed his file. Now in some places I have this structure:

Part name
color name

which translates perfectly to

Part name
color: name

But then he added

Part name
Color
color name

and I cannot now translate like above

Part name
Color
color: name

Using the advanced display filter I could display all segments, where I have in source either color or color name (for example (Color|red|blue<yellow<brown) in source and "^color: ..." in Polish. But the problem is, I need only to change this segments, where "Color" is followed by "color: ...".

But in my view sometimes the segments do not really follow each other.

Looks like this:

 

Does anyone have an idea, how to automate this?

_________________________________________________________

When asking for help here, please be as accurate as possible. Please always remember to give the exact version of product used and all possible error messages received. The better you describe your problem, the better help you will get.

Want to learn more about Trados Studio? Visit the Community Hub. Have a good idea to make Trados Studio better? Publish it here.

Parents
  • Hi Jerzy,

    Me again.

    How about thinking of the the colour as a noun instead of an adjective and using that instead on its own?
    Kolor
    Czerwony

    OR use a different word for 'colour' in each instance?
    Farba
    kolor niebieski
    or the other way round?

    I guess you've probably thought of and rejected all my ideas but it's worth asking...

    "OTOH translators should be intelligent creatures methinks" - I agree!

    All the best!
    Ali :)
  • Does not work that way.

    Again, the situation is:

    Noun here
    Color here

    With this, the name of the color in Polish must take the gender of the preceding noun.

    So we MUST have

    Samochód
    czerwony

    Sukienka
    czerwona

    But the color (czerwony/czerwona here) is ONE separate segment. So if I translate "red" to "czerwony", it goes autopropagated in the file (here more than thousand times). I cannot sit and click yes/no in the AP confirmation window. So first I've found the option to show ALL segments, containing the word "color" and the names of colors. This view is shown above. This way I could watch subsequent segments with "Kolor" and "kolor: anything" and remove the superfluous word "kolor:" from the second segment. But I'm afraid I might have missed some occurrences. So I will go for Notepad++ :)

    Best regards from miracle worker :)

    _________________________________________________________

    When asking for help here, please be as accurate as possible. Please always remember to give the exact version of product used and all possible error messages received. The better you describe your problem, the better help you will get.

    Want to learn more about Trados Studio? Visit the Community Hub. Have a good idea to make Trados Studio better? Publish it here.

  • Hi Jerzy, AKA Miracle Worker!

    The way I'd normally deal with this would be to simply use the 'Find' tool for 'Kolor', case sensitive, from the bottom upwards so that 'Kolor' appears at the top of the window and I can see what is under it and amend appropriately. However, I've never had this happen with thousands of entries. Would be pretty time-consuming.

    I think I understand now, the colour in each case is going to agree with the word 'Kolor/kolor' and not the dress/car/pen/etc before that.
    You just want to know when to delete 'kolor: '... Nora's right, Notepad ++

    All the best
    Ali (tired and ill so not thinking straight, sorry!)
Reply
  • Hi Jerzy, AKA Miracle Worker!

    The way I'd normally deal with this would be to simply use the 'Find' tool for 'Kolor', case sensitive, from the bottom upwards so that 'Kolor' appears at the top of the window and I can see what is under it and amend appropriately. However, I've never had this happen with thousands of entries. Would be pretty time-consuming.

    I think I understand now, the colour in each case is going to agree with the word 'Kolor/kolor' and not the dress/car/pen/etc before that.
    You just want to know when to delete 'kolor: '... Nora's right, Notepad ++

    All the best
    Ali (tired and ill so not thinking straight, sorry!)
Children
  • Hi Ali
    The way I'd normally deal with this would be to simply use the 'Find' tool for 'Kolor', case sensitive, from the bottom upwards so that 'Kolor' appears at the top of the window and I can see what is under it and amend appropriately

    In fact this is what I've done in that above filtered view. Search and replace for lower case "kolor: ".
    It could be so easy, would the customer not have inserted lines containing JUST and ONLY the word "Color".
    But I think I've found a solution here.
    This is in fact what I understand as "impossibilities are done immediately" ...
    Wonders are more the things we do, when beta testing - on production files :)
    Best regards, Jerzy

    _________________________________________________________

    When asking for help here, please be as accurate as possible. Please always remember to give the exact version of product used and all possible error messages received. The better you describe your problem, the better help you will get.

    Want to learn more about Trados Studio? Visit the Community Hub. Have a good idea to make Trados Studio better? Publish it here.