Menu

#558 Incorrect display of RTL segments in the Fuzzy Matches pane

5.4
open
nobody
5
2023-04-03
2013-01-23
No

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

Related

Bugs: #978

Discussion

  • Didier Briel

    Didier Briel - 2020-01-28

    See also [#978].

     
    👍
    1

    Related

    Bugs: #978

  • msoutopico

    msoutopico - 2020-01-28

    Screenshot 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
  • msoutopico

    msoutopico - 2020-01-29

    The same applies to results in the search dialog.

     
  • msoutopico

    msoutopico - 2020-11-13

    Would it be possible to add tags Arabic, RTL, bidi, directionality to this ticket so that it's easier to find?

     
  • Kos Ivantsov

    Kos Ivantsov - 2020-11-13
    • labels: Interface --> Interface, Hebrew, Arabic, bidi, RTL, directionality
    • Group: --> 5.4
     
  • Kos Ivantsov

    Kos Ivantsov - 2020-11-13
    • labels: Interface --> Interface, Hebrew, Arabic, bidi, RTL, directionality
    • Group: --> 5.4
     
  • msoutopico

    msoutopico - 2020-11-13

    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.

     
  • msoutopico

    msoutopico - 2020-11-13

    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 ar or he etc. (or simply when the target language in the project settings is ar or he).

     

    Last edit: msoutopico 2020-11-13
    • Damien Rembert

      Damien Rembert - 2023-02-12

      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 :)

       
      • msoutopico

        msoutopico - 2023-02-12

        @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
        • Damien Rembert

          Damien Rembert - 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

           
          • msoutopico

            msoutopico - 2023-02-12

            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
            • Damien Rembert

              Damien Rembert - 2023-02-12

              That's much better than the one I made, thank you!

               
      • msoutopico

        msoutopico - 2023-02-12

        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.

         
        • Damien Rembert

          Damien Rembert - 2023-02-15

          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

           
          • msoutopico

            msoutopico - 2023-02-16

            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.

             
            • Damien Rembert

              Damien Rembert - 2023-02-17

              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
    • Damien Rembert

      Damien Rembert - 2023-03-14

      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!

       
      • msoutopico

        msoutopico - 2023-04-03

        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.

         
        • Damien Rembert

          Damien Rembert - 2023-04-03

          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!

           

Log in to post a comment.

MongoDB Logo MongoDB