Backed out changeset 45fb48dc681c (bug 1687426) for arabic-final-ligature-spacing.html failures CLOSED TREE

This commit is contained in:
Bogdan Tara 2021-02-01 05:35:30 +02:00
Родитель 0b49bad602
Коммит ed210ffba0
6 изменённых файлов: 4 добавлений и 46 удалений

Просмотреть файл

@ -1784,8 +1784,7 @@ void gfxPlatformFontList::GetFontFamiliesFromGenericFamilies(
gfxPlatformFontList::PrefFontList* gfxPlatformFontList::GetPrefFontsLangGroup(
StyleGenericFontFamily aGenericType, eFontPrefLang aPrefLang) {
if (aGenericType == StyleGenericFontFamily::MozEmoji ||
aPrefLang == eFontPrefLang_Emoji) {
if (aGenericType == StyleGenericFontFamily::MozEmoji) {
// Emoji font has no lang
PrefFontList* prefFonts = mEmojiPrefFont.get();
if (MOZ_UNLIKELY(!prefFonts)) {

Просмотреть файл

@ -1872,9 +1872,6 @@ void gfxFontGroup::BuildFontList() {
MOZ_ASSERT_UNREACHABLE("broken FontFamilyName, no atom!");
}
} else {
if (mFirstGeneric == StyleGenericFontFamily::None) {
mFirstGeneric = name.mGeneric;
}
pfl->AddGenericFonts(name.mGeneric, mLanguage, fonts);
if (mTextPerf) {
mTextPerf->current.genericLookups++;
@ -3675,15 +3672,9 @@ gfxFont* gfxFontGroup::WhichPrefFontSupportsChar(
for (i = 0; i < numLangs; i++) {
eFontPrefLang currentLang = prefLangs[i];
gfxPlatformFontList::PrefFontList* families = nullptr;
if (mFirstGeneric != StyleGenericFontFamily::None) {
families = pfl->GetPrefFontsLangGroup(mFirstGeneric, currentLang);
}
if (!families) {
StyleGenericFontFamily defaultGeneric =
pfl->GetDefaultGeneric(currentLang);
families = pfl->GetPrefFontsLangGroup(defaultGeneric, currentLang);
}
StyleGenericFontFamily defaultGeneric = pfl->GetDefaultGeneric(currentLang);
gfxPlatformFontList::PrefFontList* families =
pfl->GetPrefFontsLangGroup(defaultGeneric, currentLang);
NS_ASSERTION(families, "no pref font families found");
// find the first pref font that includes the character

Просмотреть файл

@ -1412,11 +1412,6 @@ class gfxFontGroup final : public gfxTextRunFactory {
bool mExplicitLanguage; // Does mLanguage come from an explicit attribute?
// First CSS generic in the list, if any (used to select among font prefs
// during fallback)
mozilla::StyleGenericFontFamily mFirstGeneric =
mozilla::StyleGenericFontFamily::None;
uint32_t mFontListGeneration = 0; // platform font list generation for this
// fontgroup

Просмотреть файл

@ -1,12 +0,0 @@
<!DOCTYPE html>
<html lang="en-US">
<meta charset="utf-8">
<style>
.a { font: 32px serif; }
.b { font: 32px sans-serif; }
strut { font-size: 2em; }
</style>
<p>The first Chinese line should use the <tt>serif</tt> font setting from prefs;
the second should use the <tt>sans-serif</tt> font setting.</p>
<p class="a"><span lang="zh-CN">你好吗?</span><strut>&nbsp;</strut></p>
<p class="b"><span lang="zh-CN">你好吗?</span><strut>&nbsp;</strut></p>

Просмотреть файл

@ -1,12 +0,0 @@
<!DOCTYPE html>
<html lang="en-US">
<meta charset="utf-8">
<style>
.a { font: 32px serif; }
.b { font: 32px sans-serif; }
strut { font-size: 2em; } /* to force stable line height/baseline position */
</style>
<p>The first Chinese line should use the <tt>serif</tt> font setting from prefs;
the second should use the <tt>sans-serif</tt> font setting.</p>
<p class="a">你好吗?<strut>&nbsp;</strut></p>
<p class="b">你好吗?<strut>&nbsp;</strut></p>

Просмотреть файл

@ -160,8 +160,5 @@ skip-if(!winWidget) == legacy-family-names-2.html legacy-family-names-2-ref.html
random-if(/^Windows\x20NT\x206\.1/.test(http.oscpu)) == descriptor-ranges.html descriptor-ranges-ref.html # Bug 1392106
# Test that prefs font fallback respects the CSS generic from content (bug 1687426)
== fallback-respects-generic-1.html fallback-respects-generic-1-ref.html
# Reset default prefs.
defaults