[OpenJDK 2D-Dev] RFR: 7017058: Malayalam glyph substitution is failing for Malayalam with Windows Kartika font.

Sergey Bylokhov Sergey.Bylokhov at oracle.com
Tue Sep 11 00:56:20 UTC 2018


Looks fine.

On 04/09/2018 17:40, Philip Race wrote:
> This fixes 3 submitted bugs
> https://bugs.openjdk.java.net/browse/JDK-7017058 : the Malayalam bug above
> And also
> https://bugs.openjdk.java.net/browse/JDK-8191130 :
> Sinhala text rendering problem with C+VIRAMA+ZWJ+RA/YA+V
> and
> https://bugs.openjdk.java.net/browse/JDK-8195836:
> opentype:Bengali: "Khanda Ta" shaping issue with U+09A4 TA, U+09CD 
> virama, U+200D ZWJ
> 
> Webrev: http://cr.openjdk.java.net/~prr/7017058/
> 
> As discussed in the evaluation of 7017058, this is because of some code 
> which
> always maps several unicode formatting characters to the invisible glyph to
> ensure it is never rendered as a missing glyph box.
> But if the opentype tables in a font have glyph substitution looks ups that
> depend on that font's actual mapping of those glyphs then they are broken.
> We have had several reports of this (above) and also complaints this breaks
> Emoji family ligature substitution.
> 
> The fix changes this to first consult the font to see if it does map 
> these codepoints.
> If it does not then we still will map to the empty glyph in which case 
> clearly the
> font can't have any lookup that depends on it.
> 
> The variable origCharCode is added because several of the methods mutate 
> charCode
> and we avoid risk with this approach.
> 
> The tab, NL and CR code points are still always mapped to the empty glyph
> since they are never going to be used by layout in this way and some fonts
> map TAB to a space char which is not what we want.
> 
> -phil.
> 
> 


-- 
Best regards, Sergey.


More information about the 2d-dev mailing list