Re: ***UNCHECKED*** Re: bidi mirror
Eduardo Castiñeyra <[email protected]> Wed, 29 Mar 2017 13:05:24 +0200
| Newsgroups | gmane.comp.internationalization.fribidi |
|---|---|
| Message-ID | <[email protected]> |
This is a multi-part message in MIME format. --===============0858822994== Content-Type: multipart/alternative; boundary="------------4175206DDA0529A3DB87B2BF" This is a multi-part message in MIME format. --------------4175206DDA0529A3DB87B2BF Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Thanks Dov, that's clarifying! On 3/29/2017 12:39 PM, Dov Grobgeld wrote: > Unfortunately fribidi isn't Unicode 6.3 complient yet. > > You may want to test the following branch and see if it makes a > difference: > > https://github.com/dov/fribidi/tree/unicode63 > > But I'm in doubt as we have not yet implemented the N0 rule of the > Unicode6.3 standard, which seems to be relevant to your problem. It is > still (unfortunately far too slow) work in progress. > > Regards, > Dov > > > On Wed, Mar 29, 2017 at 1:13 PM, Eduardo Castiñeyra > <[email protected] <mailto:[email protected]>> wrote: > > > > On 3/28/2017 7:24 PM, Eli Zaretskii wrote: > > Consider this level 0 text: > > http://unicode.org/cldr/utility/bidi.jsp?a=sample+%28text%29&p=LTR > <http://unicode.org/cldr/utility/bidi.jsp?a=sample+%28text%29&p=LTR> > > Then, we change the Paragraph direction in the drop down > from LTR to RTL > > http://unicode.org/cldr/utility/bidi.jsp?a=sample+%28text%29&p=RTL > <http://unicode.org/cldr/utility/bidi.jsp?a=sample+%28text%29&p=RTL> > > Suddenly, all the L0 become L2 except the last parenthesis > and thus, the > reordered view shows the parenthesis at the beginning. > > That page says "Not yet updated for the changes in Unicode 6.3!", > which means the Bidirectional Parentheses Algorithm (BPA) is not > accounted for. The BPA causes the text to be rendered reasonably, > with parentheses mirrored as expected. E.g., try that in a recent > enough Emacs. > > I think I didn't ask the correct question. The problem is not the > parenthesis not flipping but the fact that the last parenthesis > level is odd, which causes: > > 1) The parenthesis being shown at the beginning of the sentence. > 2) fribidi_shape_mirroring flipping the parenthesis when it shouldn't > > So, in this regard I actually cannot complain about the behavior > of fribidi_shape_mirroring, in any case I should complain about > fribidi_log2vis but I don't think it is doing anything different > that what the BiDi algorithm says. I just would like to know how > to prevent this case. > > I have compared MS Notepad in Windows 10 and Windows 7 (pre-U6.3) > and you're right, Windows 7 puts the parenthesis at the beginning > and Windows 10 puts it at the end which is consistent with the > Unicode 6.3 explanation but... > > What about Fribidi? Doesn't it implement U6.3 ? Why am I seeing > the parenthesis also at the beginning in my application ? > > Thanks! > > > > > > _______________________________________________ > fribidi mailing list > [email protected] <mailto:[email protected]> > https://lists.freedesktop.org/mailman/listinfo/fribidi > <https://lists.freedesktop.org/mailman/listinfo/fribidi> > > --------------4175206DDA0529A3DB87B2BF Content-Type: text/html; charset=utf-8 Content-Transfer-Encoding: 8bit <html> <head> <meta content="text/html; charset=utf-8" http-equiv="Content-Type"> </head> <body bgcolor="#FFFFFF" text="#000000"> Thanks Dov, that's clarifying!<br> <br> <div class="moz-cite-prefix">On 3/29/2017 12:39 PM, Dov Grobgeld wrote:<br> </div> <blockquote cite="mid:CA++fsGFK4zM9B9HatyamV4d615QTWco=XxnA74ec+byWPQtrLQ@mail.gmail.com" type="cite"> <div dir="ltr"> <div class="gmail_default" style="font-family:arial,helvetica,sans-serif">Unfortunately fribidi isn't Unicode 6.3 complient yet.<br> <br> You may want to test the following branch and see if it makes a difference:<br> <br> <a moz-do-not-send="true" href="https://github.com/dov/fribidi/tree/unicode63">https://github.com/dov/fribidi/tree/unicode63</a><br> <br> </div> <div class="gmail_default" style="font-family:arial,helvetica,sans-serif">But I'm in doubt as we have not yet implemented the N0 rule of the Unicode6.3 standard, which seems to be relevant to your problem. It is still (unfortunately far too slow) work in progress.<br> <br> </div> <div class="gmail_default" style="font-family:arial,helvetica,sans-serif">Regards,<br> </div> <div class="gmail_default" style="font-family:arial,helvetica,sans-serif">Dov<br> <br> </div> </div> <div class="gmail_extra"><br> <div class="gmail_quote">On Wed, Mar 29, 2017 at 1:13 PM, Eduardo Castiñeyra <span dir="ltr"><<a moz-do-not-send="true" href="mailto:[email protected]" target="_blank">[email protected]</a>></span> wrote:<br> <blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class=""><br> <br> On 3/28/2017 7:24 PM, Eli Zaretskii wrote:<br> <blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"> <blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"> Consider this level 0 text:<br> <br> <a moz-do-not-send="true" href="http://unicode.org/cldr/utility/bidi.jsp?a=sample+%28text%29&p=LTR" rel="noreferrer" target="_blank">http://unicode.org/cldr/utilit<wbr>y/bidi.jsp?a=sample+%28text%<wbr>29&p=LTR</a><br> <br> Then, we change the Paragraph direction in the drop down from LTR to RTL<br> <br> <a moz-do-not-send="true" href="http://unicode.org/cldr/utility/bidi.jsp?a=sample+%28text%29&p=RTL" rel="noreferrer" target="_blank">http://unicode.org/cldr/utilit<wbr>y/bidi.jsp?a=sample+%28text%<wbr>29&p=RTL</a><br> <br> Suddenly, all the L0 become L2 except the last parenthesis and thus, the<br> reordered view shows the parenthesis at the beginning.<br> </blockquote> That page says "Not yet updated for the changes in Unicode 6.3!",<br> which means the Bidirectional Parentheses Algorithm (BPA) is not<br> accounted for. The BPA causes the text to be rendered reasonably,<br> with parentheses mirrored as expected. E.g., try that in a recent<br> enough Emacs.<br> <br> </blockquote> </span> I think I didn't ask the correct question. The problem is not the parenthesis not flipping but the fact that the last parenthesis level is odd, which causes:<br> <br> 1) The parenthesis being shown at the beginning of the sentence.<br> 2) fribidi_shape_mirroring flipping the parenthesis when it shouldn't<br> <br> So, in this regard I actually cannot complain about the behavior of fribidi_shape_mirroring, in any case I should complain about fribidi_log2vis but I don't think it is doing anything different that what the BiDi algorithm says. I just would like to know how to prevent this case.<br> <br> I have compared MS Notepad in Windows 10 and Windows 7 (pre-U6.3) and you're right, Windows 7 puts the parenthesis at the beginning and Windows 10 puts it at the end which is consistent with the Unicode 6.3 explanation but...<br> <br> What about Fribidi? Doesn't it implement U6.3 ? Why am I seeing the parenthesis also at the beginning in my application ?<br> <br> Thanks! <div class="HOEnZb"> <div class="h5"><br> <br> <br> <br> <br> ______________________________<wbr>_________________<br> fribidi mailing list<br> <a moz-do-not-send="true" href="mailto:[email protected]" target="_blank">[email protected]</a><br> <a moz-do-not-send="true" href="https://lists.freedesktop.org/mailman/listinfo/fribidi" rel="noreferrer" target="_blank">https://lists.freedesktop.org/<wbr>mailman/listinfo/fribidi</a><br> </div> </div> </blockquote> </div> <br> </div> </blockquote> <br> </body> </html> --------------4175206DDA0529A3DB87B2BF-- --===============0858822994== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX18KZnJpYmlkaSBt YWlsaW5nIGxpc3QKZnJpYmlkaUBsaXN0cy5mcmVlZGVza3RvcC5vcmcKaHR0cHM6Ly9saXN0cy5m cmVlZGVza3RvcC5vcmcvbWFpbG1hbi9saXN0aW5mby9mcmliaWRpCg== --===============0858822994==--