mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-11 12:25:53 +00:00
bug 1012365 - workaround for Devanagari fonts that lack support for U+0972 on Android. r=jdaggett
This commit is contained in:
parent
78c2dc6adc
commit
e551329cb7
@ -515,6 +515,15 @@ FT2FontEntry::ReadCMAP(FontInfoData *aFontInfoData)
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef MOZ_WIDGET_ANDROID
|
||||
// Hack for the SamsungDevanagari font, bug 1012365:
|
||||
// pretend the font supports U+0972.
|
||||
if (!charmap->test(0x0972) &&
|
||||
charmap->test(0x0905) && charmap->test(0x0945)) {
|
||||
charmap->set(0x0972);
|
||||
}
|
||||
#endif
|
||||
|
||||
mHasCmapTable = NS_SUCCEEDED(rv);
|
||||
if (mHasCmapTable) {
|
||||
gfxPlatformFontList *pfl = gfxPlatformFontList::PlatformFontList();
|
||||
|
@ -795,6 +795,15 @@ HBUnicodeDecompose(hb_unicode_funcs_t *ufuncs,
|
||||
hb_codepoint_t *b,
|
||||
void *user_data)
|
||||
{
|
||||
#ifdef MOZ_WIDGET_ANDROID
|
||||
// Hack for the SamsungDevanagari font, bug 1012365:
|
||||
// support U+0972 by decomposing it.
|
||||
if (ab == 0x0972) {
|
||||
*a = 0x0905;
|
||||
*b = 0x0945;
|
||||
return true;
|
||||
}
|
||||
#endif
|
||||
return nsUnicodeNormalizer::DecomposeNonRecursively(ab, a, b);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user