<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[169474] trunk</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/169474">169474</a></dd>
<dt>Author</dt> <dd>mmaxfield@apple.com</dd>
<dt>Date</dt> <dd>2014-05-29 16:41:15 -0700 (Thu, 29 May 2014)</dd>
</dl>

<h3>Log Message</h3>
<pre>Support -apple-system-font on OS X
https://bugs.webkit.org/show_bug.cgi?id=133382

Source/WebCore:
Reviewed by Simon Fraser.

Guard on both family names: &quot;-apple-system-font&quot; and &quot;-webkit-system-font&quot;

Test: platform/mac/fast/text/systemFont.html

* platform/mac/WebFontCache.mm:
(+[WebFontCache internalFontWithFamily:traits:weight:size:]):

LayoutTests:
This test makes sure that -apple-system-font is rendered the same way as -webkit-system-font.

Reviewed by Simon Fraser.

* platform/mac-mountainlion/platform/mac/fast/text/systemFont-expected.txt: Updated.
* platform/mac/fast/text/systemFont.html: Tests -apple-system-font in addition to -webkit-system-font.
* platform/mac/platform/mac/fast/text/systemFont-expected.txt: Updated.</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkLayoutTestsChangeLog">trunk/LayoutTests/ChangeLog</a></li>
<li><a href="#trunkLayoutTestsplatformmacfasttextsystemFonthtml">trunk/LayoutTests/platform/mac/fast/text/systemFont.html</a></li>
<li><a href="#trunkLayoutTestsplatformmacplatformmacfasttextsystemFontexpectedtxt">trunk/LayoutTests/platform/mac/platform/mac/fast/text/systemFont-expected.txt</a></li>
<li><a href="#trunkLayoutTestsplatformmacmountainlionplatformmacfasttextsystemFontexpectedtxt">trunk/LayoutTests/platform/mac-mountainlion/platform/mac/fast/text/systemFont-expected.txt</a></li>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCoreplatformmacWebFontCachemm">trunk/Source/WebCore/platform/mac/WebFontCache.mm</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkLayoutTestsChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/ChangeLog (169473 => 169474)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/ChangeLog        2014-05-29 23:24:16 UTC (rev 169473)
+++ trunk/LayoutTests/ChangeLog        2014-05-29 23:41:15 UTC (rev 169474)
</span><span class="lines">@@ -1,3 +1,16 @@
</span><ins>+2014-05-29  Myles C. Maxfield  &lt;mmaxfield@apple.com&gt;
+
+        Support -apple-system-font on OS X
+        https://bugs.webkit.org/show_bug.cgi?id=133382
+
+        This test makes sure that -apple-system-font is rendered the same way as -webkit-system-font.
+
+        Reviewed by Simon Fraser.
+
+        * platform/mac-mountainlion/platform/mac/fast/text/systemFont-expected.txt: Updated.
+        * platform/mac/fast/text/systemFont.html: Tests -apple-system-font in addition to -webkit-system-font.
+        * platform/mac/platform/mac/fast/text/systemFont-expected.txt: Updated.
+
</ins><span class="cx"> 2014-05-29  Alexey Proskuryakov  &lt;ap@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Loading &lt;object&gt; from WebArchive crashes
</span></span></pre></div>
<a id="trunkLayoutTestsplatformmacfasttextsystemFonthtml"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/platform/mac/fast/text/systemFont.html (169473 => 169474)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/platform/mac/fast/text/systemFont.html        2014-05-29 23:24:16 UTC (rev 169473)
+++ trunk/LayoutTests/platform/mac/fast/text/systemFont.html        2014-05-29 23:41:15 UTC (rev 169474)
</span><span class="lines">@@ -1,12 +1,26 @@
</span><span class="cx"> &lt;body&gt;
</span><del>-    &lt;div style=&quot;font-family: -webkit-system-font; font-size: 24px&quot;&gt;This is a test for -webkit-system-font font&lt;/div&gt;
-    &lt;div style=&quot;font: 30.0px '-webkit-system-font'&quot;&gt;This is a test for -webkit-system-font font&lt;/div&gt;
-    &lt;div style=&quot;font-family: -webkit-system-font; font-size: 30px&quot;&gt;This is a test for -webkit-system-font font&lt;/div&gt;
-    &lt;div style=&quot;font-family: -webkit-system-font; font-size: 36px&quot;&gt;&lt;b&gt;This is a test for -webkit-system-font font&lt;/b&gt;&lt;/div&gt;
-    &lt;div style=&quot;font-family: -webkit-system-font; font-size: 42px&quot;&gt;&lt;i&gt;This is a test for -webkit-system-font font&lt;/i&gt;&lt;/div&gt;
-    &lt;div style=&quot;font-family: -webkit-system-font; font-size: 48px&quot;&gt;This is a test for -webkit-system-font font&lt;/div&gt;
-    &lt;div style=&quot;font-family: -webkit-system-font; font-size: 54px&quot;&gt;This is a test for -webkit-system-font font&lt;/div&gt;
-    &lt;div style=&quot;font-family: -webkit-system-font; font-size: 60px&quot;&gt;This is a test for -webkit-system-font font&lt;/div&gt;
-    &lt;div style=&quot;font-family: -webkit-system-font; font-size: 66px&quot;&gt;This is a test for -webkit-system-font font&lt;/div&gt;
-    &lt;div style=&quot;font-family: -webkit-system-font; font-size: 72px&quot;&gt;This is a test for -webkit-system-font font&lt;/div&gt;
</del><ins>+    &lt;div&gt;
+        &lt;div style=&quot;font-family: -webkit-system-font; font-size: 24px&quot;&gt;This is a test for -webkit-system-font font&lt;/div&gt;
+        &lt;div style=&quot;font: 30.0px '-webkit-system-font'&quot;&gt;This is a test for -webkit-system-font font&lt;/div&gt;
+        &lt;div style=&quot;font-family: -webkit-system-font; font-size: 30px&quot;&gt;This is a test for -webkit-system-font font&lt;/div&gt;
+        &lt;div style=&quot;font-family: -webkit-system-font; font-size: 36px&quot;&gt;&lt;b&gt;This is a test for -webkit-system-font font&lt;/b&gt;&lt;/div&gt;
+        &lt;div style=&quot;font-family: -webkit-system-font; font-size: 42px&quot;&gt;&lt;i&gt;This is a test for -webkit-system-font font&lt;/i&gt;&lt;/div&gt;
+        &lt;div style=&quot;font-family: -webkit-system-font; font-size: 48px&quot;&gt;This is a test for -webkit-system-font font&lt;/div&gt;
+        &lt;div style=&quot;font-family: -webkit-system-font; font-size: 54px&quot;&gt;This is a test for -webkit-system-font font&lt;/div&gt;
+        &lt;div style=&quot;font-family: -webkit-system-font; font-size: 60px&quot;&gt;This is a test for -webkit-system-font font&lt;/div&gt;
+        &lt;div style=&quot;font-family: -webkit-system-font; font-size: 66px&quot;&gt;This is a test for -webkit-system-font font&lt;/div&gt;
+        &lt;div style=&quot;font-family: -webkit-system-font; font-size: 72px&quot;&gt;This is a test for -webkit-system-font font&lt;/div&gt;
+    &lt;/div&gt;
+    &lt;div&gt;
+        &lt;div style=&quot;font-family: -apple-system-font; font-size: 24px&quot;&gt;This is a test for -apple-system-font font&lt;/div&gt;
+        &lt;div style=&quot;font: 30.0px '-apple-system-font'&quot;&gt;This is a test for -apple-system-font font&lt;/div&gt;
+        &lt;div style=&quot;font-family: -apple-system-font; font-size: 30px&quot;&gt;This is a test for -apple-system-font font&lt;/div&gt;
+        &lt;div style=&quot;font-family: -apple-system-font; font-size: 36px&quot;&gt;&lt;b&gt;This is a test for -apple-system-font font&lt;/b&gt;&lt;/div&gt;
+        &lt;div style=&quot;font-family: -apple-system-font; font-size: 42px&quot;&gt;&lt;i&gt;This is a test for -apple-system-font font&lt;/i&gt;&lt;/div&gt;
+        &lt;div style=&quot;font-family: -apple-system-font; font-size: 48px&quot;&gt;This is a test for -apple-system-font font&lt;/div&gt;
+        &lt;div style=&quot;font-family: -apple-system-font; font-size: 54px&quot;&gt;This is a test for -apple-system-font font&lt;/div&gt;
+        &lt;div style=&quot;font-family: -apple-system-font; font-size: 60px&quot;&gt;This is a test for -apple-system-font font&lt;/div&gt;
+        &lt;div style=&quot;font-family: -apple-system-font; font-size: 66px&quot;&gt;This is a test for -apple-system-font font&lt;/div&gt;
+        &lt;div style=&quot;font-family: -apple-system-font; font-size: 72px&quot;&gt;This is a test for -apple-system-font font&lt;/div&gt;
+    &lt;/div&gt;
</ins><span class="cx"> &lt;/body&gt;
</span></span></pre></div>
<a id="trunkLayoutTestsplatformmacplatformmacfasttextsystemFontexpectedtxt"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/platform/mac/platform/mac/fast/text/systemFont-expected.txt (169473 => 169474)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/platform/mac/platform/mac/fast/text/systemFont-expected.txt        2014-05-29 23:24:16 UTC (rev 169473)
+++ trunk/LayoutTests/platform/mac/platform/mac/fast/text/systemFont-expected.txt        2014-05-29 23:41:15 UTC (rev 169474)
</span><span class="lines">@@ -1,46 +1,88 @@
</span><del>-layer at (0,0) size 785x1169
</del><ins>+layer at (0,0) size 785x2244
</ins><span class="cx">   RenderView at (0,0) size 785x600
</span><del>-layer at (0,0) size 785x1169
-  RenderBlock {HTML} at (0,0) size 785x1169
-    RenderBody {BODY} at (8,8) size 769x1153
-      RenderBlock {DIV} at (0,0) size 769x28
-        RenderText {#text} at (0,0) size 493x28
-          text run at (0,0) width 493: &quot;This is a test for -webkit-system-font font&quot;
-      RenderBlock {DIV} at (0,28) size 769x35
-        RenderText {#text} at (0,0) size 616x35
-          text run at (0,0) width 616: &quot;This is a test for -webkit-system-font font&quot;
-      RenderBlock {DIV} at (0,63) size 769x35
-        RenderText {#text} at (0,0) size 616x35
-          text run at (0,0) width 616: &quot;This is a test for -webkit-system-font font&quot;
-      RenderBlock {DIV} at (0,98) size 769x86
-        RenderInline {B} at (0,0) size 726x86
-          RenderText {#text} at (0,0) size 726x86
-            text run at (0,0) width 726: &quot;This is a test for -webkit-system-font&quot;
-            text run at (0,43) width 77: &quot;font&quot;
-      RenderBlock {DIV} at (0,184) size 769x100
-        RenderInline {I} at (0,0) size 766x100
-          RenderText {#text} at (0,0) size 766x100
-            text run at (0,0) width 766: &quot;This is a test for -webkit-system-font&quot;
-            text run at (0,50) width 84: &quot;font&quot;
-      RenderBlock {DIV} at (0,284) size 769x112
-        RenderText {#text} at (0,0) size 594x112
-          text run at (0,0) width 594: &quot;This is a test for -webkit-&quot;
-          text run at (0,56) width 392: &quot;system-font font&quot;
-      RenderBlock {DIV} at (0,396) size 769x126
-        RenderText {#text} at (0,0) size 669x126
-          text run at (0,0) width 669: &quot;This is a test for -webkit-&quot;
-          text run at (0,63) width 441: &quot;system-font font&quot;
-      RenderBlock {DIV} at (0,522) size 769x142
-        RenderText {#text} at (0,0) size 743x142
-          text run at (0,0) width 743: &quot;This is a test for -webkit-&quot;
-          text run at (0,71) width 490: &quot;system-font font&quot;
-      RenderBlock {DIV} at (0,664) size 769x234
-        RenderText {#text} at (0,0) size 636x234
-          text run at (0,0) width 568: &quot;This is a test for -&quot;
-          text run at (0,78) width 636: &quot;webkit-system-font&quot;
-          text run at (0,156) width 131: &quot;font&quot;
-      RenderBlock {DIV} at (0,898) size 769x255
-        RenderText {#text} at (0,0) size 694x255
-          text run at (0,0) width 619: &quot;This is a test for -&quot;
-          text run at (0,85) width 694: &quot;webkit-system-font&quot;
-          text run at (0,170) width 143: &quot;font&quot;
</del><ins>+layer at (0,0) size 785x2244
+  RenderBlock {HTML} at (0,0) size 785x2244
+    RenderBody {BODY} at (8,8) size 769x2228
+      RenderBlock {DIV} at (0,0) size 769x1153
+        RenderBlock {DIV} at (0,0) size 769x28
+          RenderText {#text} at (0,0) size 493x28
+            text run at (0,0) width 493: &quot;This is a test for -webkit-system-font font&quot;
+        RenderBlock {DIV} at (0,28) size 769x35
+          RenderText {#text} at (0,0) size 616x35
+            text run at (0,0) width 616: &quot;This is a test for -webkit-system-font font&quot;
+        RenderBlock {DIV} at (0,63) size 769x35
+          RenderText {#text} at (0,0) size 616x35
+            text run at (0,0) width 616: &quot;This is a test for -webkit-system-font font&quot;
+        RenderBlock {DIV} at (0,98) size 769x86
+          RenderInline {B} at (0,0) size 726x86
+            RenderText {#text} at (0,0) size 726x86
+              text run at (0,0) width 726: &quot;This is a test for -webkit-system-font&quot;
+              text run at (0,43) width 77: &quot;font&quot;
+        RenderBlock {DIV} at (0,184) size 769x100
+          RenderInline {I} at (0,0) size 766x100
+            RenderText {#text} at (0,0) size 766x100
+              text run at (0,0) width 766: &quot;This is a test for -webkit-system-font&quot;
+              text run at (0,50) width 84: &quot;font&quot;
+        RenderBlock {DIV} at (0,284) size 769x112
+          RenderText {#text} at (0,0) size 594x112
+            text run at (0,0) width 594: &quot;This is a test for -webkit-&quot;
+            text run at (0,56) width 392: &quot;system-font font&quot;
+        RenderBlock {DIV} at (0,396) size 769x126
+          RenderText {#text} at (0,0) size 669x126
+            text run at (0,0) width 669: &quot;This is a test for -webkit-&quot;
+            text run at (0,63) width 441: &quot;system-font font&quot;
+        RenderBlock {DIV} at (0,522) size 769x142
+          RenderText {#text} at (0,0) size 743x142
+            text run at (0,0) width 743: &quot;This is a test for -webkit-&quot;
+            text run at (0,71) width 490: &quot;system-font font&quot;
+        RenderBlock {DIV} at (0,664) size 769x234
+          RenderText {#text} at (0,0) size 636x234
+            text run at (0,0) width 568: &quot;This is a test for -&quot;
+            text run at (0,78) width 636: &quot;webkit-system-font&quot;
+            text run at (0,156) width 131: &quot;font&quot;
+        RenderBlock {DIV} at (0,898) size 769x255
+          RenderText {#text} at (0,0) size 694x255
+            text run at (0,0) width 619: &quot;This is a test for -&quot;
+            text run at (0,85) width 694: &quot;webkit-system-font&quot;
+            text run at (0,170) width 143: &quot;font&quot;
+      RenderBlock {DIV} at (0,1153) size 769x1075
+        RenderBlock {DIV} at (0,0) size 769x28
+          RenderText {#text} at (0,0) size 480x28
+            text run at (0,0) width 480: &quot;This is a test for -apple-system-font font&quot;
+        RenderBlock {DIV} at (0,28) size 769x35
+          RenderText {#text} at (0,0) size 600x35
+            text run at (0,0) width 600: &quot;This is a test for -apple-system-font font&quot;
+        RenderBlock {DIV} at (0,63) size 769x35
+          RenderText {#text} at (0,0) size 600x35
+            text run at (0,0) width 600: &quot;This is a test for -apple-system-font font&quot;
+        RenderBlock {DIV} at (0,98) size 769x86
+          RenderInline {B} at (0,0) size 703x86
+            RenderText {#text} at (0,0) size 703x86
+              text run at (0,0) width 703: &quot;This is a test for -apple-system-font&quot;
+              text run at (0,43) width 77: &quot;font&quot;
+        RenderBlock {DIV} at (0,184) size 769x100
+          RenderInline {I} at (0,0) size 743x100
+            RenderText {#text} at (0,0) size 743x100
+              text run at (0,0) width 743: &quot;This is a test for -apple-system-font&quot;
+              text run at (0,50) width 84: &quot;font&quot;
+        RenderBlock {DIV} at (0,284) size 769x112
+          RenderText {#text} at (0,0) size 755x112
+            text run at (0,0) width 755: &quot;This is a test for -apple-system-&quot;
+            text run at (0,56) width 205: &quot;font font&quot;
+        RenderBlock {DIV} at (0,396) size 769x126
+          RenderText {#text} at (0,0) size 639x126
+            text run at (0,0) width 639: &quot;This is a test for -apple-&quot;
+            text run at (0,63) width 441: &quot;system-font font&quot;
+        RenderBlock {DIV} at (0,522) size 769x142
+          RenderText {#text} at (0,0) size 710x142
+            text run at (0,0) width 710: &quot;This is a test for -apple-&quot;
+            text run at (0,71) width 490: &quot;system-font font&quot;
+        RenderBlock {DIV} at (0,664) size 769x156
+          RenderText {#text} at (0,0) size 752x156
+            text run at (0,0) width 568: &quot;This is a test for -&quot;
+            text run at (0,78) width 752: &quot;apple-system-font font&quot;
+        RenderBlock {DIV} at (0,820) size 769x255
+          RenderText {#text} at (0,0) size 655x255
+            text run at (0,0) width 619: &quot;This is a test for -&quot;
+            text run at (0,85) width 655: &quot;apple-system-font&quot;
+            text run at (0,170) width 143: &quot;font&quot;
</ins></span></pre></div>
<a id="trunkLayoutTestsplatformmacmountainlionplatformmacfasttextsystemFontexpectedtxt"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/platform/mac-mountainlion/platform/mac/fast/text/systemFont-expected.txt (169473 => 169474)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/platform/mac-mountainlion/platform/mac/fast/text/systemFont-expected.txt        2014-05-29 23:24:16 UTC (rev 169473)
+++ trunk/LayoutTests/platform/mac-mountainlion/platform/mac/fast/text/systemFont-expected.txt        2014-05-29 23:41:15 UTC (rev 169474)
</span><span class="lines">@@ -1,46 +1,88 @@
</span><del>-layer at (0,0) size 785x1169
</del><ins>+layer at (0,0) size 785x2244
</ins><span class="cx">   RenderView at (0,0) size 785x600
</span><del>-layer at (0,0) size 785x1169
-  RenderBlock {HTML} at (0,0) size 785x1169
-    RenderBody {BODY} at (8,8) size 769x1153
-      RenderBlock {DIV} at (0,0) size 769x28
-        RenderText {#text} at (0,0) size 500x28
-          text run at (0,0) width 500: &quot;This is a test for -webkit-system-font font&quot;
-      RenderBlock {DIV} at (0,28) size 769x35
-        RenderText {#text} at (0,0) size 625x35
-          text run at (0,0) width 625: &quot;This is a test for -webkit-system-font font&quot;
-      RenderBlock {DIV} at (0,63) size 769x35
-        RenderText {#text} at (0,0) size 625x35
-          text run at (0,0) width 625: &quot;This is a test for -webkit-system-font font&quot;
-      RenderBlock {DIV} at (0,98) size 769x86
-        RenderInline {B} at (0,0) size 721x86
-          RenderText {#text} at (0,0) size 721x86
-            text run at (0,0) width 721: &quot;This is a test for -webkit-system-font&quot;
-            text run at (0,43) width 77: &quot;font&quot;
-      RenderBlock {DIV} at (0,184) size 769x100
-        RenderInline {I} at (0,0) size 695x100
-          RenderText {#text} at (0,0) size 695x100
-            text run at (0,0) width 695: &quot;This is a test for -webkit-system-&quot;
-            text run at (0,50) width 180: &quot;font font&quot;
-      RenderBlock {DIV} at (0,284) size 769x112
-        RenderText {#text} at (0,0) size 603x112
-          text run at (0,0) width 603: &quot;This is a test for -webkit-&quot;
-          text run at (0,56) width 397: &quot;system-font font&quot;
-      RenderBlock {DIV} at (0,396) size 769x126
-        RenderText {#text} at (0,0) size 678x126
-          text run at (0,0) width 678: &quot;This is a test for -webkit-&quot;
-          text run at (0,63) width 446: &quot;system-font font&quot;
-      RenderBlock {DIV} at (0,522) size 769x142
-        RenderText {#text} at (0,0) size 754x142
-          text run at (0,0) width 754: &quot;This is a test for -webkit-&quot;
-          text run at (0,71) width 496: &quot;system-font font&quot;
-      RenderBlock {DIV} at (0,664) size 769x234
-        RenderText {#text} at (0,0) size 644x234
-          text run at (0,0) width 579: &quot;This is a test for -&quot;
-          text run at (0,78) width 644: &quot;webkit-system-font&quot;
-          text run at (0,156) width 131: &quot;font&quot;
-      RenderBlock {DIV} at (0,898) size 769x255
-        RenderText {#text} at (0,0) size 702x255
-          text run at (0,0) width 632: &quot;This is a test for -&quot;
-          text run at (0,85) width 702: &quot;webkit-system-font&quot;
-          text run at (0,170) width 143: &quot;font&quot;
</del><ins>+layer at (0,0) size 785x2244
+  RenderBlock {HTML} at (0,0) size 785x2244
+    RenderBody {BODY} at (8,8) size 769x2228
+      RenderBlock {DIV} at (0,0) size 769x1153
+        RenderBlock {DIV} at (0,0) size 769x28
+          RenderText {#text} at (0,0) size 500x28
+            text run at (0,0) width 500: &quot;This is a test for -webkit-system-font font&quot;
+        RenderBlock {DIV} at (0,28) size 769x35
+          RenderText {#text} at (0,0) size 625x35
+            text run at (0,0) width 625: &quot;This is a test for -webkit-system-font font&quot;
+        RenderBlock {DIV} at (0,63) size 769x35
+          RenderText {#text} at (0,0) size 625x35
+            text run at (0,0) width 625: &quot;This is a test for -webkit-system-font font&quot;
+        RenderBlock {DIV} at (0,98) size 769x86
+          RenderInline {B} at (0,0) size 721x86
+            RenderText {#text} at (0,0) size 721x86
+              text run at (0,0) width 721: &quot;This is a test for -webkit-system-font&quot;
+              text run at (0,43) width 77: &quot;font&quot;
+        RenderBlock {DIV} at (0,184) size 769x100
+          RenderInline {I} at (0,0) size 695x100
+            RenderText {#text} at (0,0) size 695x100
+              text run at (0,0) width 695: &quot;This is a test for -webkit-system-&quot;
+              text run at (0,50) width 180: &quot;font font&quot;
+        RenderBlock {DIV} at (0,284) size 769x112
+          RenderText {#text} at (0,0) size 603x112
+            text run at (0,0) width 603: &quot;This is a test for -webkit-&quot;
+            text run at (0,56) width 397: &quot;system-font font&quot;
+        RenderBlock {DIV} at (0,396) size 769x126
+          RenderText {#text} at (0,0) size 678x126
+            text run at (0,0) width 678: &quot;This is a test for -webkit-&quot;
+            text run at (0,63) width 446: &quot;system-font font&quot;
+        RenderBlock {DIV} at (0,522) size 769x142
+          RenderText {#text} at (0,0) size 754x142
+            text run at (0,0) width 754: &quot;This is a test for -webkit-&quot;
+            text run at (0,71) width 496: &quot;system-font font&quot;
+        RenderBlock {DIV} at (0,664) size 769x234
+          RenderText {#text} at (0,0) size 644x234
+            text run at (0,0) width 579: &quot;This is a test for -&quot;
+            text run at (0,78) width 644: &quot;webkit-system-font&quot;
+            text run at (0,156) width 131: &quot;font&quot;
+        RenderBlock {DIV} at (0,898) size 769x255
+          RenderText {#text} at (0,0) size 702x255
+            text run at (0,0) width 632: &quot;This is a test for -&quot;
+            text run at (0,85) width 702: &quot;webkit-system-font&quot;
+            text run at (0,170) width 143: &quot;font&quot;
+      RenderBlock {DIV} at (0,1153) size 769x1075
+        RenderBlock {DIV} at (0,0) size 769x28
+          RenderText {#text} at (0,0) size 487x28
+            text run at (0,0) width 487: &quot;This is a test for -apple-system-font font&quot;
+        RenderBlock {DIV} at (0,28) size 769x35
+          RenderText {#text} at (0,0) size 608x35
+            text run at (0,0) width 608: &quot;This is a test for -apple-system-font font&quot;
+        RenderBlock {DIV} at (0,63) size 769x35
+          RenderText {#text} at (0,0) size 608x35
+            text run at (0,0) width 608: &quot;This is a test for -apple-system-font font&quot;
+        RenderBlock {DIV} at (0,98) size 769x86
+          RenderInline {B} at (0,0) size 698x86
+            RenderText {#text} at (0,0) size 698x86
+              text run at (0,0) width 698: &quot;This is a test for -apple-system-font&quot;
+              text run at (0,43) width 77: &quot;font&quot;
+        RenderBlock {DIV} at (0,184) size 769x100
+          RenderInline {I} at (0,0) size 755x100
+            RenderText {#text} at (0,0) size 755x100
+              text run at (0,0) width 755: &quot;This is a test for -apple-system-font&quot;
+              text run at (0,50) width 84: &quot;font&quot;
+        RenderBlock {DIV} at (0,284) size 769x112
+          RenderText {#text} at (0,0) size 768x112
+            text run at (0,0) width 768: &quot;This is a test for -apple-system-&quot;
+            text run at (0,56) width 205: &quot;font font&quot;
+        RenderBlock {DIV} at (0,396) size 769x126
+          RenderText {#text} at (0,0) size 649x126
+            text run at (0,0) width 649: &quot;This is a test for -apple-&quot;
+            text run at (0,63) width 446: &quot;system-font font&quot;
+        RenderBlock {DIV} at (0,522) size 769x142
+          RenderText {#text} at (0,0) size 721x142
+            text run at (0,0) width 721: &quot;This is a test for -apple-&quot;
+            text run at (0,71) width 496: &quot;system-font font&quot;
+        RenderBlock {DIV} at (0,664) size 769x156
+          RenderText {#text} at (0,0) size 759x156
+            text run at (0,0) width 579: &quot;This is a test for -&quot;
+            text run at (0,78) width 759: &quot;apple-system-font font&quot;
+        RenderBlock {DIV} at (0,820) size 769x255
+          RenderText {#text} at (0,0) size 663x255
+            text run at (0,0) width 632: &quot;This is a test for -&quot;
+            text run at (0,85) width 663: &quot;apple-system-font&quot;
+            text run at (0,170) width 143: &quot;font&quot;
</ins></span></pre></div>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (169473 => 169474)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog        2014-05-29 23:24:16 UTC (rev 169473)
+++ trunk/Source/WebCore/ChangeLog        2014-05-29 23:41:15 UTC (rev 169474)
</span><span class="lines">@@ -1,3 +1,17 @@
</span><ins>+2014-05-29  Myles C. Maxfield  &lt;mmaxfield@apple.com&gt;
+
+        Support -apple-system-font on OS X
+        https://bugs.webkit.org/show_bug.cgi?id=133382
+
+        Reviewed by Simon Fraser.
+
+        Guard on both family names: &quot;-apple-system-font&quot; and &quot;-webkit-system-font&quot;
+
+        Test: platform/mac/fast/text/systemFont.html
+
+        * platform/mac/WebFontCache.mm:
+        (+[WebFontCache internalFontWithFamily:traits:weight:size:]):
+
</ins><span class="cx"> 2014-05-29  Alexey Proskuryakov  &lt;ap@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Loading &lt;object&gt; from WebArchive crashes
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformmacWebFontCachemm"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/mac/WebFontCache.mm (169473 => 169474)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/mac/WebFontCache.mm        2014-05-29 23:24:16 UTC (rev 169473)
+++ trunk/Source/WebCore/platform/mac/WebFontCache.mm        2014-05-29 23:41:15 UTC (rev 169474)
</span><span class="lines">@@ -160,7 +160,8 @@
</span><span class="cx"> + (NSFont *)internalFontWithFamily:(NSString *)desiredFamily traits:(NSFontTraitMask)desiredTraits weight:(int)desiredWeight size:(float)size
</span><span class="cx"> {
</span><span class="cx"> 
</span><del>-    if ([desiredFamily compare:@&quot;-webkit-system-font&quot; options:NSCaseInsensitiveSearch] == NSOrderedSame) {
</del><ins>+    if ([desiredFamily compare:@&quot;-webkit-system-font&quot; options:NSCaseInsensitiveSearch] == NSOrderedSame
+        || [desiredFamily compare:@&quot;-apple-system-font&quot; options:NSCaseInsensitiveSearch] == NSOrderedSame) {
</ins><span class="cx">         // We ignore italic for system font.
</span><span class="cx">         return (desiredWeight &gt;= 7) ? [NSFont boldSystemFontOfSize:size] : [NSFont systemFontOfSize:size];
</span><span class="cx">     }
</span></span></pre>
</div>
</div>

</body>
</html>