diff --git a/gfx/thebes/gfxFont.cpp b/gfx/thebes/gfxFont.cpp index 6b7ecb9f3add..724e08bdff64 100644 --- a/gfx/thebes/gfxFont.cpp +++ b/gfx/thebes/gfxFont.cpp @@ -4580,20 +4580,7 @@ gfxFontGroup::MakeSpaceTextRun(const Parameters *aParams, uint32_t aFlags) textRun->AddGlyphRun(font, gfxTextRange::kFontGroup, 0, false); } else { - if (font->GetSpaceGlyph()) { - // Normally, the font has a cached space glyph, so we can avoid - // the cost of calling FindFontForChar. - textRun->SetSpaceGlyph(font, aParams->mContext, 0); - } else { - // In case the primary font doesn't have (bug 970891), - // find one that does. - uint8_t matchType; - nsRefPtr spaceFont = - FindFontForChar(' ', 0, MOZ_SCRIPT_LATIN, nullptr, &matchType); - if (spaceFont) { - textRun->SetSpaceGlyph(spaceFont, aParams->mContext, 0); - } - } + textRun->SetSpaceGlyph(font, aParams->mContext, 0); } // Note that the gfxGlyphExtents glyph bounds storage for the font will diff --git a/layout/reftests/text/reftest.list b/layout/reftests/text/reftest.list index 343537b08c1e..395039a16326 100644 --- a/layout/reftests/text/reftest.list +++ b/layout/reftests/text/reftest.list @@ -295,6 +295,3 @@ pref(layout.css.text-align-true-value.enabled,true) == text-align-true.html text != control-chars-02.html control-chars-02-notref.html == control-chars-03a.html control-chars-03-ref.html == control-chars-03b.html control-chars-03-ref.html - -# font fallback for when not supported in the primary font family - bug 970891 -HTTP(..) == space-font-1.html space-font-1-ref.html diff --git a/layout/reftests/text/space-font-1-ref.html b/layout/reftests/text/space-font-1-ref.html deleted file mode 100644 index 486ebf806073..000000000000 --- a/layout/reftests/text/space-font-1-ref.html +++ /dev/null @@ -1,26 +0,0 @@ - - - - - Bug 970891 - - - - -
A A A A
- - - diff --git a/layout/reftests/text/space-font-1.html b/layout/reftests/text/space-font-1.html deleted file mode 100644 index 534d6cab5af4..000000000000 --- a/layout/reftests/text/space-font-1.html +++ /dev/null @@ -1,25 +0,0 @@ - - - - - Bug 970891 - - - - - -
A A A A
- - -