In the Fuzzy Matches pane, RTL segments are not displayed correctly (it is easy to see the issue when compared with the same segment displayed in the Editor).
Segments (source or target or both) should be displayed LTR or RTL according to the language of the TUV.
Didier
See also [#978].
Related
Bugs:
#978Screenshot that shows how the wrong directionality of the Arabic fuzzy matche affects readability as some parts of the text are misplaced (due to conflicts with characters with neutral or weak directionality or strong LTR directionality embedded in the Arabic text):

Last edit: msoutopico 2020-01-28
The same applies to results in the search dialog.
Would it be possible to add tags Arabic, RTL, bidi, directionality to this ticket so that it's easier to find?
The same applies to results in the Multiple Translations pane. See the screenshot (the arrows show the beginning of the sentence). In bidirectional sentences (mixing Arabic text with other elements such as non-alphanumeric characters or Latin text), this bug makes the match or the translation in the multiple translations pane very difficult to read and assess.
Is there any chance that this can be fixed soon? The code to change directionality is there for the editor, it should be possible to apply the same thing to other places in the UI where text has language tag
arorheetc. (or simply when the target language in the project settings isarorhe).Last edit: msoutopico 2020-11-13
Hi,
I'm trying to look into this but I'm having a hard time finding simple documents where I know that the problem is present.
Could you share two txt or html files that I could use to test? The shortest/simplest sentence possible, please, so I can see when things are in the right/wrong order easily.
Ideally with a picture illustrating the problem (pointing out what's expected and what's you're seeing instead) like the one you offered above.
Thanks in advance :)
@damien-rembert thanks a lot for looking into this.
You can find a sample project attached to ticket 977. That is a real example. Could you please have a look and tell me whether that helps? If not, I can try creating a simplified version.
You can unpack that project package from OmegaT if you install the OMT plugin or you can simply unzip the OMT package.
Let me know if you need help with bidirectionality or Arabic.
Last edit: msoutopico 2023-02-12
Aha that's the project I have been using so far (thank you by the way!) but I think we might disagree on what is a short sentence :)
I think I got a bit hung up on truncating the sentence myself as I might make it meaningless or something but I doubt anyone will actually hold it against me
I am attaching a new version, with a simplified version of the text and a translation that is simply a transliteration:
foo = فو
thud = ثود
bar = بار
But you can even see the issue by looking at the order of tags.
I hope that helps.
Last edit: msoutopico 2023-02-12
That's much better than the one I made, thank you!
In any case, I would say that the fix for the matches pane, the multiple translations pane and the search dialog would be to implement in those parts of the UI whatever was done to apply RTL directionality in the editor.
Just a little update: sadly it's not that simple, the editor of the main panel is quite complex and cannot be copy/pasted to other components. For now, the best I got is to define the orientation using the target language, which is probably better than the current state. Not quite what we want but hey we'll get there
Hi Damien. I think by “orientation” you mean text alignment. That is really
not that important, RTL is better right-aligned but it’s not an issue if
it’s left-aligned, just as it’s not an issue to right-align LTR text. What
matters here is the direction of the text, which must be RTL for languages
using the Arabic or Hebrew scripts. I hope this helps and thanks for your
efforts.
The default Java GUI elements used in OmegaT have an "orientation" property that defines how the text "flows", its direction (LTR or RTL). I'm not sure how common or current this naming is to be honest. This orientation seems to impact the alignment by default but that's a side effect. The alignment should be an easy fix and a little bit of investigation should do hopefully.
I'm a bit unsure about what would be the correct look for the line indicating the matching levels and file path. I'm guessing that it should depend on the language of the system (rather than the source or target languages). Would that also be your expectation?
In the case of the screenshot above, a LTR source language and a RTL target language on a LTR system, would you expect each of them to be aligned according to their own "orientation"?
This might look like details but if we want this change to be accepted, it will need to be somewhat polished :)
Last edit: Damien Rembert 2023-02-17
Could you try out the changes I have made, please?
Here is a link to an OmegaT without JRE.zip (acloud2.zaclys.com).
I'm not trying to get the alignment right at the moment, just the functionality.
You would basically need to try the UI changes with projects that include RTL languages (ideally RTL to LTR and the opposite but also RTL to RTL).
I would appreciate any user experience knowledge/guidance as I cannot really use OmegaT with an RTL locale and, as I have never had to work with texts where RTL and LTR were present, I do not know what the expectations are and I would rather not rely on assumptions only. Thanks in advance!
Hi @damien-rembert. I can try but your zip is no longer available. Do you have a fork of omegat's repo that I can clone and use a branch for testing this? Feel free tag me if you like.
Hello @msoutopico
That's great news!
Here is the branch I have been working on:
https://github.com/damien-rembert/omegat/tree/BUG-SF558-incorrect-display-of-RTL-segments-in-fuzzy-match-pane
The fork I have been working on can be found here. And the branch name is
BUG-SF558-incorrect-display-of-RTL-segments-in-fuzzy-match-pane.I don't know why but when I try to tag you, your name is not available in the suggestions, hopefully it will work all the same but I'll try to message you directly otherwise.
Thanks!