haikuwebkit/LayoutTests/fast/text/font-lookup-dot-prefix-case...

15 lines
272 B
HTML
Raw Permalink Normal View History

[macOS] Reeder's defaults font is Times instead of San Francisco https://bugs.webkit.org/show_bug.cgi?id=174885 <rdar://problem/33462483> Reviewed by Simon Fraser. Source/WebCore: Reeder uses explicit dot-prefixed names in its source code. Within Core Text, dot-prefixed names cannot be matched case insensitively. The solution is to not case-fold these family names, and to make our caches case sensitive for these special names. Tests: fast/text/font-lookup-dot-prefix-case-sensitive-2.html fast/text/font-lookup-dot-prefix-case-sensitive.html * platform/graphics/FontCache.cpp: (WebCore::FontPlatformDataCacheKey::operator==): (WebCore::FontPlatformDataCacheKeyHash::hash): * platform/graphics/FontCascade.cpp: (WebCore::keysMatch): (WebCore::computeFontCascadeCacheHash): * platform/graphics/FontDescription.cpp: (WebCore::FontCascadeDescription::familyNamesAreEqual): (WebCore::FontCascadeDescription::familyNameHash): (WebCore::FontCascadeDescription::foldedFamilyName): * platform/graphics/FontDescription.h: * platform/graphics/cocoa/FontCacheCoreText.cpp: (WebCore::FontDatabase::fontForPostScriptName): LayoutTests: * fast/text/font-lookup-dot-prefix-case-sensitive-2-expected.html: Added. * fast/text/font-lookup-dot-prefix-case-sensitive-2.html: Added. * fast/text/font-lookup-dot-prefix-case-sensitive-expected-mismatch.html: Added. * fast/text/font-lookup-dot-prefix-case-sensitive.html: Added. Canonical link: https://commits.webkit.org/191738@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@220009 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2017-07-28 18:36:37 +00:00
<!DOCTYPE html>
<html>
<head>
<script>
if (window.internals) {
internals.invalidateFontCache();
</script>
</head>
<body>
<div style="font: 100px '.apPLesysTemUiFontMEDium';">Hello</div>
<div style="font: 100px '.AppleSystemUIFontMedium';">Hello</div>
</body>
</html>