"\" is not parsed in Java Properties file

Hello everybody

I think my problem might be similar to https://community.rws.com/product-groups/trados-portfolio/passolo/f/passolo-general/7960/escape-character-and-unicode-spaces-not-visible-in-passolo, so I don't know whether there's a solution, but I'll try to describe it as clearly as possible:

I have to translate German Java Properties files into English, French and Italian. They contain strings such as these:

Screenshot of Trados Studio interface showing JAVA PROPERTIES 'Strings' with blue highlights on source text and corresponding target segments in German and English. A warning symbol is visible next to a segment.

See my blue marks: The resource contains the character "\" that is inserted to break the line in the source, as far as I understand for pure readability reasons. In the translation, the text of the element with the same ID should be kept together, so no further segmentation -  which Passolo does correctly.

However, the "\" character is escaped and shown neither in the source segment, nor in the target segment. When I generate the target file, the "\" character is also not rendered, which results in a different number of lines in the target source and thus a compilation error. I therefore have to re-insert the "\" characters by hand. On top, every time a string in the string list is changed and I generate the target file, all the strings with "\" are overwritten once more and I end up spending hours on manually re-inserting the "\" character in the java file.

Is there an elegant way of avoiding that Passolo escapes the "\" character and renders it properly so I can also place it in the target segment?



Generated Image Alt-Text
[edited by: Trados AI at 5:48 AM (GMT 0) on 5 Mar 2024]
emoji
Parents
  • I would suggest to check with the provider of the files as they do not seem to be valid properties files.

    As Achim mentioned in the post you linked "\" is a special character and is used to escape certain values. For example \\ would generate a single \ char. Or equal sign needs to be escaped as \=.

    If the file contains a single backslash then it will be dropped by Passolo. You could try to escape them using \\ format but the best would be to check with the provider of those files and use proper format.

Reply
  • I would suggest to check with the provider of the files as they do not seem to be valid properties files.

    As Achim mentioned in the post you linked "\" is a special character and is used to escape certain values. For example \\ would generate a single \ char. Or equal sign needs to be escaped as \=.

    If the file contains a single backslash then it will be dropped by Passolo. You could try to escape them using \\ format but the best would be to check with the provider of those files and use proper format.

Children
No Data