<div dir="ltr">Hi, Johnathan,<div><br></div><div>In your patch:</div><div><br></div><div>







<p class="">+    /* XXX This hack belongs to the SEA shaper (for Tai Tham):</p>
<p class="">+       reorder SAKOT to ensure it comes after any tone marks. */</p>
<p class="">+    if (unlikely (unicode == 0x1A60)) return 254;</p><p class="">... could the return value be something a bit more symbolic?  Just so that people like me who don't really have time to delve into the details of HarfBuzz code will have a better hint about what the "254" represents in this case?</p>
<p class=""><br></p><p class="">Just my 2 cents, thanks! ;)</p><p class="">- Ed</p></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Fri, Dec 27, 2013 at 12:09 PM, Jonathan Kew <span dir="ltr"><<a href="mailto:jfkthame@googlemail.com" target="_blank">jfkthame@googlemail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="im">On 27/12/13 16:21, Ed Trager wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
Hi, Martin, Richard, and Danh Hong,<br>
<br>
With regard to forcing the re-ordering of the<br>
UCD-enforced-but-totally-<u></u>broken normalisation of TAI THAM TONE MARK plus<br>
U+1A60, does the following approach in the OpenType feature file make<br>
sense as the quickest and cleanest way to do it or not?:<br>
<br>
Basically the idea is to compose the out-of-order pair of characters<br>
into a ligature; and then take that ligature and decompose it back to a<br>
pair of characters that are in the correct order:<br>
<br>
If there is a better way to do this in OpenType, please enlighten me!<br>
:-)  I was trying to get this to work last night, so far without success:<br>
<br>
</blockquote>
<br></div>
The trouble with this idea (or at least one trouble with it!) is that by the time your lookups have a chance to do anything, harfbuzz has already inserted dotted-circle glyphs because it treated the (normalized) sequence as being a "broken" cluster. The pattern for a "consonant syllable" in the SEAsian shaper allows for a <sakot, consonant> pair (i.e. a subjoined consonant) among the various possible syllable-tail items, but it does not allow for the <sakot> and <cons> to be separated by other marks, which is what the normalization does.<br>

<br>
You -might- be able to work around this by explicitly including the dotted circles in your ligature-composition rules, though that will make them all more cumbersome. The better way forward is for us to fix harfbuzz, as previously suggested.<br>

<br>
Possible patch attached; Behdad, wdyt?<br>
<br>
<br>
</blockquote></div><br></div>