Unreviewed, rolling out r218524.
authorryanhaddad@apple.com <ryanhaddad@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 20 Jun 2017 23:22:16 +0000 (23:22 +0000)
committerryanhaddad@apple.com <ryanhaddad@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 20 Jun 2017 23:22:16 +0000 (23:22 +0000)
This change broke internal builds.

Reverted changeset:

"[Cocoa] The system Japanese font cannot be italicized"
https://bugs.webkit.org/show_bug.cgi?id=173300
http://trac.webkit.org/changeset/218524

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@218614 268f45cc-cd09-0410-ab3c-d52691b4dbfc

LayoutTests/ChangeLog
LayoutTests/fast/text/system-font-japanese-synthetic-italic-expected-mismatch.html [deleted file]
LayoutTests/fast/text/system-font-japanese-synthetic-italic.html [deleted file]
LayoutTests/platform/mac/TestExpectations
Source/WebCore/ChangeLog
Source/WebCore/platform/graphics/cocoa/FontCacheCoreText.cpp
Source/WebCore/platform/graphics/cocoa/FontFamilySpecificationCoreText.cpp

index 3557019..8f77cb8 100644 (file)
@@ -1,3 +1,15 @@
+2017-06-20  Ryan Haddad  <ryanhaddad@apple.com>
+
+        Unreviewed, rolling out r218524.
+
+        This change broke internal builds.
+
+        Reverted changeset:
+
+        "[Cocoa] The system Japanese font cannot be italicized"
+        https://bugs.webkit.org/show_bug.cgi?id=173300
+        http://trac.webkit.org/changeset/218524
+
 2017-06-20  Simon Fraser  <simon.fraser@apple.com>
 
         <rdar://problem/32862652> [REGRESSION] r218374: fast/events/ios/rotation/layout-viewport-during-safari-type-rotation.html
diff --git a/LayoutTests/fast/text/system-font-japanese-synthetic-italic-expected-mismatch.html b/LayoutTests/fast/text/system-font-japanese-synthetic-italic-expected-mismatch.html
deleted file mode 100644 (file)
index 6a970f2..0000000
+++ /dev/null
@@ -1,10 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-</head>
-<body>
-This test makes sure that the Japanese system font can be italicized. The test passes if the character below is oblique (either because the font supports it or because WebKit synthesizes the oblique).
-<div style="font: 100px 'system-ui';">の</div>
-</body>
-</html>
diff --git a/LayoutTests/fast/text/system-font-japanese-synthetic-italic.html b/LayoutTests/fast/text/system-font-japanese-synthetic-italic.html
deleted file mode 100644 (file)
index 0b48830..0000000
+++ /dev/null
@@ -1,10 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-</head>
-<body>
-This test makes sure that the Japanese system font can be italicized. The test passes if the character below is oblique (either because the font supports it or because WebKit synthesizes the oblique).
-<div style="font: 100px 'system-ui'; font-style: italic;">の</div>
-</body>
-</html>
index 72493a8..10421e0 100644 (file)
@@ -1605,4 +1605,3 @@ webkit.org/b/173328 [ ElCapitan Sierra ] fast/text/system-font-fallback.html [ I
 
 webkit.org/b/173487 imported/w3c/web-platform-tests/IndexedDB/large-nested-cloning.html [ Pass Failure ]
 
-webkit.org/b/313156 [ ElCapitan ] fast/text/system-font-japanese-synthetic-italic.html [ ImageOnlyFailure ]
index ef4bf1c..a6a1056 100644 (file)
@@ -1,3 +1,15 @@
+2017-06-20  Ryan Haddad  <ryanhaddad@apple.com>
+
+        Unreviewed, rolling out r218524.
+
+        This change broke internal builds.
+
+        Reverted changeset:
+
+        "[Cocoa] The system Japanese font cannot be italicized"
+        https://bugs.webkit.org/show_bug.cgi?id=173300
+        http://trac.webkit.org/changeset/218524
+
 2017-06-20  Daniel Bates  <dabates@apple.com>
 
         Have FrameLoadRequest takes a Frame& instead of a Frame*
index 08f03df..8b03058 100644 (file)
@@ -1292,12 +1292,7 @@ static RetainPtr<CTFontRef> lookupFallbackFont(CTFontRef font, FontSelectionValu
 #endif
 
     CFIndex coveredLength = 0;
-    RetainPtr<CTFontRef> result;
-#if USE_PLATFORM_SYSTEM_FALLBACK_LIST || (PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED < 101200)
-    result = adoptCF(CTFontCreateForCharactersWithLanguage(font, characters, length, localeString.get(), &coveredLength));
-#else
-    result = adoptCF(CTFontCreatePhysicalFontForCharactersWithLanguage(font, characters, length, localeString.get(), &coveredLength));
-#endif
+    auto result = adoptCF(CTFontCreateForCharactersWithLanguage(font, characters, length, localeString.get(), &coveredLength));
 
 #if PLATFORM(IOS)
     // Callers of this function won't include multiple code points. "Length" is to know how many code units
index 15f9c37..4321470 100644 (file)
 
 #include "FontCache.h"
 #include "FontSelector.h"
-#include "SoftLinking.h"
 #include <CoreText/CoreText.h>
 
-#if USE_PLATFORM_SYSTEM_FALLBACK_LIST
-SOFT_LINK_FRAMEWORK(CoreText);
-SOFT_LINK_MAY_FAIL(CoreText, CTFontCopyPhysicalFont, CTFontRef, (CTFontRef font), (font));
-#endif
-
 namespace WebCore {
 
 FontFamilySpecificationCoreText::FontFamilySpecificationCoreText(CTFontDescriptorRef fontDescriptor)
@@ -53,18 +47,10 @@ FontRanges FontFamilySpecificationCoreText::fontRanges(const FontDescription& fo
 
     auto font = adoptCF(CTFontCreateWithFontDescriptor(m_fontDescriptor.get(), size, nullptr));
 
-    auto fontForSynthesisComputation = font;
-#if USE_PLATFORM_SYSTEM_FALLBACK_LIST
-    if (canLoadCTFontCopyPhysicalFont()) {
-        if (auto physicalFont = adoptCF(CTFontCopyPhysicalFont(font.get())))
-            fontForSynthesisComputation = physicalFont;
-    }
-#endif
-
     font = preparePlatformFont(font.get(), fontDescription, nullptr, nullptr, { }, fontDescription.computedSize());
 
     bool syntheticBold, syntheticOblique;
-    std::tie(syntheticBold, syntheticOblique) = computeNecessarySynthesis(fontForSynthesisComputation.get(), fontDescription).boldObliquePair();
+    std::tie(syntheticBold, syntheticOblique) = computeNecessarySynthesis(font.get(), fontDescription).boldObliquePair();
 
     FontPlatformData fontPlatformData(font.get(), size, syntheticBold, syntheticOblique, fontDescription.orientation(), fontDescription.widthVariant(), fontDescription.textRenderingMode());