2008-03-26 Mark Rowe <mrowe@apple.com>
authormrowe@apple.com <mrowe@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 26 Mar 2008 23:34:36 +0000 (23:34 +0000)
committermrowe@apple.com <mrowe@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 26 Mar 2008 23:34:36 +0000 (23:34 +0000)
        Reviewed by David Hyatt.

        Make the Ahem font antialias correctly on Acid3 on Tiger.

        * WebCore.Tiger.exp:
        * platform/graphics/mac/SimpleFontDataMac.mm:
        (WebCore::SimpleFontData::platformInit):
        * platform/mac/WebCoreSystemInterface.h:
        * platform/mac/WebCoreSystemInterface.mm:

2008-03-26  Mark Rowe  <mrowe@apple.com>

        Reviewed by David Hyatt.

        Make the Ahem font antialias correctly on Acid3 on Tiger.

        * WebKitSystemInterface.h:
        * libWebKitSystemInterfaceTiger.a:

2008-03-26  Mark Rowe  <mrowe@apple.com>

        Reviewed by David Hyatt.

        Make the Ahem font antialias correctly on Acid3 on Tiger.

        * WebCoreSupport/WebSystemInterface.m:
        (InitWebCoreSystemInterface):

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

WebCore/ChangeLog
WebCore/WebCore.Tiger.exp
WebCore/platform/graphics/mac/SimpleFontDataMac.mm
WebCore/platform/mac/WebCoreSystemInterface.h
WebCore/platform/mac/WebCoreSystemInterface.mm
WebKit/mac/ChangeLog
WebKit/mac/WebCoreSupport/WebSystemInterface.m
WebKitLibraries/ChangeLog
WebKitLibraries/WebKitSystemInterface.h
WebKitLibraries/libWebKitSystemInterfaceTiger.a

index 6a556d8..791fb08 100644 (file)
@@ -1,3 +1,15 @@
+2008-03-26  Mark Rowe  <mrowe@apple.com>
+
+        Reviewed by David Hyatt.
+
+        Make the Ahem font antialias correctly on Acid3 on Tiger.
+
+        * WebCore.Tiger.exp:
+        * platform/graphics/mac/SimpleFontDataMac.mm:
+        (WebCore::SimpleFontData::platformInit):
+        * platform/mac/WebCoreSystemInterface.h:
+        * platform/mac/WebCoreSystemInterface.mm:
+
 2008-03-26  Simon Hausmann  <hausmann@webkit.org>
 
         Attempt to fix the Qt build.
index 3197e06..cd91799 100644 (file)
@@ -2,3 +2,4 @@ _wkGetCGFontFromNSFont
 _wkGetFontMetrics
 _wkGetNSFontATSUFontId
 _wkSupportsMultipartXMixedReplace
+_wkCopyFullFontName
index 393fbcb..9e201f0 100644 (file)
@@ -257,18 +257,17 @@ void SimpleFontData::platformInit()
         m_xHeight = MAX(NSMaxX(xBox), NSMaxY(xBox));
     } else
         m_xHeight = [m_font.font() xHeight];
-    
-    // FIXME: Cannot
-#ifdef BUILDING_ON_TIGER
-    m_allowFontSmoothing = true;
-#else
+
     // Workaround for strange CG antialiasing of the Ahem font. Limit to the Web font version.
     if (isCustomFont()) {
+#ifdef BUILDING_ON_TIGER
+        RetainPtr<CFStringRef> fullName(AdoptCF, wkCopyFullFontName(m_font.cgFont()));
+#else
         RetainPtr<CFStringRef> fullName(AdoptCF, CGFontCopyFullName(m_font.cgFont()));
+#endif
         String nameStr(fullName.get());
         m_allowFontSmoothing = (nameStr != "Ahem");
     }
-#endif
 }
 
 void SimpleFontData::platformDestroy()
index 873d3bf..a645d65 100644 (file)
@@ -138,6 +138,7 @@ extern void (*wkSignalCFReadStreamHasBytes)(CFReadStreamRef stream);
 
 #ifdef BUILDING_ON_TIGER
 extern void (*wkGetFontMetrics)(CGFontRef, int* ascent, int* descent, int* lineGap, unsigned* unitsPerEm);
+extern CFStringRef (*wkCopyFullFontName)(CGFontRef font);
 extern BOOL (*wkSupportsMultipartXMixedReplace)(NSMutableURLRequest *);
 #endif
 
index e827009..3ee1fba 100644 (file)
@@ -91,5 +91,6 @@ id (*wkCreateNSURLConnectionDelegateProxy)(void);
 CGFontRef (*wkGetCGFontFromNSFont)(NSFont*);
 void (*wkGetFontMetrics)(CGFontRef, int* ascent, int* descent, int* lineGap, unsigned* unitsPerEm);
 ATSUFontID (*wkGetNSFontATSUFontId)(NSFont*);
+CFStringRef (*wkCopyFullFontName)(CGFontRef font);
 BOOL (*wkSupportsMultipartXMixedReplace)(NSMutableURLRequest *);
 #endif
index e09dc3c..1b6732d 100644 (file)
@@ -1,5 +1,14 @@
 2008-03-26  Mark Rowe  <mrowe@apple.com>
 
+        Reviewed by David Hyatt.
+
+        Make the Ahem font antialias correctly on Acid3 on Tiger.
+
+        * WebCoreSupport/WebSystemInterface.m:
+        (InitWebCoreSystemInterface):
+
+2008-03-26  Mark Rowe  <mrowe@apple.com>
+
         Fix the Mac build.
 
         * MigrateHeaders.make: Copy the newly generated header into the right place.
index 43d21bb..a6a98fc 100644 (file)
@@ -92,6 +92,7 @@ void InitWebCoreSystemInterface(void)
     INIT(GetCGFontFromNSFont);
     INIT(GetFontMetrics);
     INIT(GetNSFontATSUFontId);
+    INIT(CopyFullFontName);
     INIT(SupportsMultipartXMixedReplace);
 #endif
 
index b0781e9..2641a36 100644 (file)
@@ -1,3 +1,12 @@
+2008-03-26  Mark Rowe  <mrowe@apple.com>
+
+        Reviewed by David Hyatt.
+
+        Make the Ahem font antialias correctly on Acid3 on Tiger.
+
+        * WebKitSystemInterface.h:
+        * libWebKitSystemInterfaceTiger.a:
+
 2008-03-19  Mark Rowe  <mrowe@apple.com>
 
         Rubber-stamped by Sam Weinig.
index 7355243..9afe6e5 100644 (file)
@@ -123,6 +123,8 @@ void WKGetFontMetrics(CGFontRef font, int *ascent, int *descent, int *lineGap, u
 CGFontRef WKGetCGFontFromNSFont(NSFont *font);
 // CTFontGetPlatformFont was not available until Leopard
 ATSUFontID WKGetNSFontATSUFontId(NSFont *font);
+// CGFontCopyFullName was not available until Leopard
+CFStringRef WKCopyFullFontName(CGFontRef font);
 #endif
 
 void WKSetPatternBaseCTM(CGContextRef, CGAffineTransform);
index 0db47d0..be8197c 100644 (file)
Binary files a/WebKitLibraries/libWebKitSystemInterfaceTiger.a and b/WebKitLibraries/libWebKitSystemInterfaceTiger.a differ