<!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>[180199] tags/Safari-600.5.6.1</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/180199">180199</a></dd>
<dt>Author</dt> <dd>bshafiei@apple.com</dd>
<dt>Date</dt> <dd>2015-02-16 18:04:30 -0800 (Mon, 16 Feb 2015)</dd>
</dl>
<h3>Log Message</h3>
<pre>Merged <a href="http://trac.webkit.org/projects/webkit/changeset/180191">r180191</a>. rdar://problem/19855007</pre>
<h3>Modified Paths</h3>
<ul>
<li><a href="#tagsSafari600561LayoutTestsChangeLog">tags/Safari-600.5.6.1/LayoutTests/ChangeLog</a></li>
<li><a href="#tagsSafari600561LayoutTestsTestExpectations">tags/Safari-600.5.6.1/LayoutTests/TestExpectations</a></li>
<li><a href="#tagsSafari600561SourceWebCoreChangeLog">tags/Safari-600.5.6.1/Source/WebCore/ChangeLog</a></li>
<li><a href="#tagsSafari600561SourceWebCoreWebCorexcodeprojprojectpbxproj">tags/Safari-600.5.6.1/Source/WebCore/WebCore.xcodeproj/project.pbxproj</a></li>
<li><a href="#tagsSafari600561SourceWebCoreplatformgraphicsFontcpp">tags/Safari-600.5.6.1/Source/WebCore/platform/graphics/Font.cpp</a></li>
<li><a href="#tagsSafari600561SourceWebCoreplatformgraphicsmacComplexTextControllercpp">tags/Safari-600.5.6.1/Source/WebCore/platform/graphics/mac/ComplexTextController.cpp</a></li>
<li><a href="#tagsSafari600561SourceWebCorerenderingRenderTextcpp">tags/Safari-600.5.6.1/Source/WebCore/rendering/RenderText.cpp</a></li>
</ul>
<h3>Added Paths</h3>
<ul>
<li><a href="#tagsSafari600561LayoutTestsfasttextemojiexpectedtxt">tags/Safari-600.5.6.1/LayoutTests/fast/text/emoji-expected.txt</a></li>
<li><a href="#tagsSafari600561LayoutTestsfasttextemojihtml">tags/Safari-600.5.6.1/LayoutTests/fast/text/emoji.html</a></li>
<li><a href="#tagsSafari600561SourceWebCoreplatformtextCharacterPropertiesh">tags/Safari-600.5.6.1/Source/WebCore/platform/text/CharacterProperties.h</a></li>
</ul>
</div>
<div id="patch">
<h3>Diff</h3>
<a id="tagsSafari600561LayoutTestsChangeLog"></a>
<div class="modfile"><h4>Modified: tags/Safari-600.5.6.1/LayoutTests/ChangeLog (180198 => 180199)</h4>
<pre class="diff"><span>
<span class="info">--- tags/Safari-600.5.6.1/LayoutTests/ChangeLog        2015-02-17 01:49:57 UTC (rev 180198)
+++ tags/Safari-600.5.6.1/LayoutTests/ChangeLog        2015-02-17 02:04:30 UTC (rev 180199)
</span><span class="lines">@@ -1,3 +1,19 @@
</span><ins>+2015-02-16 Babak Shafiei <bshafiei@apple.com>
+
+ Merge r180191
+
+ 2015-02-16 Enrica Casucci <enrica@apple.com>
+
+ Emoji sequences do not render properly.
+ https://bugs.webkit.org/show_bug.cgi?id=141661
+ rdar://problem/19820463
+
+ Reviewed by Sam Weinig.
+
+ * TestExpectations:
+ * fast/text/emoji-expected.txt: Added.
+ * fast/text/emoji.html: Added.
+
</ins><span class="cx"> 2015-02-12 Matthew Hanson <matthew_hanson@apple.com>
</span><span class="cx">
</span><span class="cx"> Merge r179883. rdar://problem/19790645
</span></span></pre></div>
<a id="tagsSafari600561LayoutTestsTestExpectations"></a>
<div class="modfile"><h4>Modified: tags/Safari-600.5.6.1/LayoutTests/TestExpectations (180198 => 180199)</h4>
<pre class="diff"><span>
<span class="info">--- tags/Safari-600.5.6.1/LayoutTests/TestExpectations        2015-02-17 01:49:57 UTC (rev 180198)
+++ tags/Safari-600.5.6.1/LayoutTests/TestExpectations        2015-02-17 02:04:30 UTC (rev 180199)
</span><span class="lines">@@ -131,6 +131,8 @@
</span><span class="cx"> # Failing on some bots due to using resource load callbacks
</span><span class="cx"> webkit.org/b/134769 fast/dom/HTMLImageElement/sizes/image-sizes-js-change.html [ Skip ]
</span><span class="cx">
</span><ins>+webkit.org/b/141661 fast/text/emoji.html [ Failure ]
+
</ins><span class="cx"> compositing/fixed-image-loading.html [ Skip ]
</span><span class="cx"> fast/xsl/xslt-missing-namespace-in-xslt.xml [ Skip ]
</span><span class="cx"> http/tests/cache/partitioned-cache.html [ Skip ]
</span></span></pre></div>
<a id="tagsSafari600561LayoutTestsfasttextemojiexpectedtxtfromrev180198branchessafari6005branchLayoutTestsfasttextemojiexpectedtxt"></a>
<div class="copfile"><h4>Copied: tags/Safari-600.5.6.1/LayoutTests/fast/text/emoji-expected.txt (from rev 180198, branches/safari-600.5-branch/LayoutTests/fast/text/emoji-expected.txt) (0 => 180199)</h4>
<pre class="diff"><span>
<span class="info">--- tags/Safari-600.5.6.1/LayoutTests/fast/text/emoji-expected.txt         (rev 0)
+++ tags/Safari-600.5.6.1/LayoutTests/fast/text/emoji-expected.txt        2015-02-17 02:04:30 UTC (rev 180199)
</span><span class="lines">@@ -0,0 +1,23 @@
</span><ins>+layer at (0,0) size 800x600
+ RenderView at (0,0) size 800x600
+layer at (0,0) size 800x600
+ RenderBlock {HTML} at (0,0) size 800x600
+ RenderBody {BODY} at (8,8) size 784x584
+ RenderBlock (anonymous) at (0,0) size 784x18
+ RenderText {#text} at (0,0) size 470x18
+ text run at (0,0) width 470: "This test validate rendering of emoji sequences and emoji with modifiers."
+ RenderBlock {DIV} at (0,18) size 784x235
+ RenderText {#text} at (0,4) size 180x41
+ text run at (0,4) width 180: "\x{D83D}\x{DC66}\x{D83C}\x{DFFB}\x{D83D}\x{DC69}\x{D83C}\x{DFFC}\x{D83D}\x{DC66}\x{D83C}\x{DFFE}\x{2764}\x{FE0F}\x{D83D}\x{DC8B}"
+ RenderBR {BR} at (180,36) size 0x0
+ RenderText {#text} at (0,51) size 243x41
+ text run at (0,51) width 243: "\x{D83D}\x{DC68}\x{200D}\x{D83D}\x{DC69}\x{200D}\x{D83D}\x{DC66} \x{D83D}\x{DC68}\x{200D}\x{D83D}\x{DC69}\x{200D}\x{D83D}\x{DC67} \x{D83D}\x{DC6A} \x{D83D}\x{DC66}\x{D83C}\x{DFFB}\x{D83D}\x{DC69}\x{D83C}\x{DFFC}\x{D83D}\x{DC66}\x{D83C}\x{DFFE}"
+ RenderBR {BR} at (243,83) size 0x0
+ RenderText {#text} at (0,98) size 216x41
+ text run at (0,98) width 216: "\x{D83D}\x{DC69}\x{200D}\x{D83D}\x{DC69}\x{200D}\x{D83D}\x{DC66} \x{D83D}\x{DC69}\x{200D}\x{D83D}\x{DC69}\x{200D}\x{D83D}\x{DC67} \x{D83D}\x{DC69}\x{200D}\x{D83D}\x{DC69}\x{200D}\x{D83D}\x{DC67}\x{200D}\x{D83D}\x{DC66} \x{D83D}\x{DC69}\x{200D}\x{D83D}\x{DC69}\x{200D}\x{D83D}\x{DC66}\x{200D}\x{D83D}\x{DC66} \x{D83D}\x{DC69}\x{200D}\x{D83D}\x{DC69}\x{200D}\x{D83D}\x{DC67}\x{200D}\x{D83D}\x{DC67}"
+ RenderBR {BR} at (216,130) size 0x0
+ RenderText {#text} at (0,145) size 216x41
+ text run at (0,145) width 216: "\x{D83D}\x{DC68}\x{200D}\x{D83D}\x{DC68}\x{200D}\x{D83D}\x{DC66} \x{D83D}\x{DC68}\x{200D}\x{D83D}\x{DC68}\x{200D}\x{D83D}\x{DC67} \x{D83D}\x{DC68}\x{200D}\x{D83D}\x{DC68}\x{200D}\x{D83D}\x{DC67}\x{200D}\x{D83D}\x{DC66} \x{D83D}\x{DC68}\x{200D}\x{D83D}\x{DC68}\x{200D}\x{D83D}\x{DC66}\x{200D}\x{D83D}\x{DC66} \x{D83D}\x{DC68}\x{200D}\x{D83D}\x{DC68}\x{200D}\x{D83D}\x{DC67}\x{200D}\x{D83D}\x{DC67}"
+ RenderBR {BR} at (216,177) size 0x0
+ RenderText {#text} at (0,192) size 216x41
+ text run at (0,192) width 216: "\x{D83D}\x{DC69}\x{200D}\x{2764}\x{FE0F}\x{200D}\x{D83D}\x{DC69} \x{D83D}\x{DC68}\x{200D}\x{2764}\x{FE0F}\x{200D}\x{D83D}\x{DC68} \x{D83D}\x{DC69}\x{200D}\x{2764}\x{FE0F}\x{200D}\x{D83D}\x{DC8B}\x{200D}\x{D83D}\x{DC69} \x{D83D}\x{DC68}\x{200D}\x{2764}\x{FE0F}\x{200D}\x{D83D}\x{DC8B}\x{200D}\x{D83D}\x{DC68} \x{D83D}\x{DC69}\x{200D}\x{2764}\x{FE0F}\x{200D}\x{D83D}\x{DC69}"
</ins></span></pre></div>
<a id="tagsSafari600561LayoutTestsfasttextemojihtmlfromrev180198branchessafari6005branchLayoutTestsfasttextemojihtml"></a>
<div class="copfile"><h4>Copied: tags/Safari-600.5.6.1/LayoutTests/fast/text/emoji.html (from rev 180198, branches/safari-600.5-branch/LayoutTests/fast/text/emoji.html) (0 => 180199)</h4>
<pre class="diff"><span>
<span class="info">--- tags/Safari-600.5.6.1/LayoutTests/fast/text/emoji.html         (rev 0)
+++ tags/Safari-600.5.6.1/LayoutTests/fast/text/emoji.html        2015-02-17 02:04:30 UTC (rev 180199)
</span><span class="lines">@@ -0,0 +1,12 @@
</span><ins>+<html>
+<body>
+ This test validate rendering of emoji sequences and emoji with modifiers.
+<div style='font-size: 36px'>
+&#x1F466;&#x1F3FB;&#x1F469;&#x1F3FC;&#x1F466;&#x1F3FE;&#x2764;&#xFE0F;&#x1F48B;<br>
+&#x1F468;&#x200D;&#x1F469;&#x200D;&#x1F466; &#x1F468;&#x200D;&#x1F469;&#x200D;&#x1F467; &#x1F46A; &#x1F466;&#x1F3FB;&#x1F469;&#x1F3FC;&#x1F466;&#x1F3FE;<br>
+&#x1F469;&#x200D;&#x1F469;&#x200D;&#x1F466; &#x1F469;&#x200D;&#x1F469;&#x200D;&#x1F467; &#x1F469;&#x200D;&#x1F469;&#x200D;&#x1F467;&#x200D;&#x1F466; &#x1F469;&#x200D;&#x1F469;&#x200D;&#x1F466;&#x200D;&#x1F466; &#x1F469;&#x200D;&#x1F469;&#x200D;&#x1F467;&#x200D;&#x1F467;<br>
+&#x1F468;&#x200D;&#x1F468;&#x200D;&#x1F466; &#x1F468;&#x200D;&#x1F468;&#x200D;&#x1F467; &#x1F468;&#x200D;&#x1F468;&#x200D;&#x1F467;&#x200D;&#x1F466; &#x1F468;&#x200D;&#x1F468;&#x200D;&#x1F466;&#x200D;&#x1F466; &#x1F468;&#x200D;&#x1F468;&#x200D;&#x1F467;&#x200D;&#x1F467;<br>
+&#x1F469;&#x200D;&#x2764;&#xFE0F;&#x200D;&#x1F469; &#x1F468;&#x200D;&#x2764;&#xFE0F;&#x200D;&#x1F468; &#x1F469;&#x200D;&#x2764;&#xFE0F;&#x200D;&#x1F48B;&#x200D;&#x1F469; &#x1F468;&#x200D;&#x2764;&#xFE0F;&#x200D;&#x1F48B;&#x200D;&#x1F468; &#x1F469;&#x200D;&#x2764;&#xFE0F;&#x200D;&#x1F469;
+</div>
+</body>
+</html>
</ins></span></pre></div>
<a id="tagsSafari600561SourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: tags/Safari-600.5.6.1/Source/WebCore/ChangeLog (180198 => 180199)</h4>
<pre class="diff"><span>
<span class="info">--- tags/Safari-600.5.6.1/Source/WebCore/ChangeLog        2015-02-17 01:49:57 UTC (rev 180198)
+++ tags/Safari-600.5.6.1/Source/WebCore/ChangeLog        2015-02-17 02:04:30 UTC (rev 180199)
</span><span class="lines">@@ -1,3 +1,36 @@
</span><ins>+2015-02-16 Babak Shafiei <bshafiei@apple.com>
+
+ Merge r180191
+
+ 2015-02-16 Enrica Casucci <enrica@apple.com>
+
+ Emoji sequences do not render properly.
+ https://bugs.webkit.org/show_bug.cgi?id=141661
+ rdar://problem/19820463
+
+ Reviewed by Sam Weinig.
+
+ Emoji sequences and emoji with variations should be rendered
+ using the Complex code path and should be treated as graphemes.
+ This change modifies advanceByCombiningCharacterSequence to add
+ this logic.
+
+ Test: fast/text/emoji.html
+
+ * WebCore.xcodeproj/project.pbxproj:
+ * platform/graphics/FontCascade.cpp:
+ (WebCore::FontCascade::characterRangeCodePath):
+ * platform/graphics/mac/ComplexTextController.cpp:
+ (WebCore::advanceByCombiningCharacterSequence): Implements a simple
+ logic to treat emoji sequences and emoji with variations as graphemes.
+ * platform/text/CharacterProperties.h: Added.
+ (WebCore::isEmojiGroupCandidate):
+ (WebCore::isEmojiModifier):
+ (WebCore::isVariationSelector):
+ * rendering/RenderText.cpp:
+ (WebCore::isEmojiGroupCandidate): Deleted.
+ (WebCore::isEmojiModifier): Deleted.
+
</ins><span class="cx"> 2015-01-12 Pratik Solanki <psolanki@apple.com>
</span><span class="cx">
</span><span class="cx"> <rdar://problem/17889529> CrashTracer: [USER] com.apple.WebKit.WebContent at com.apple.WebCore: WebCore::SharedBuffer::createPurgeableBuffer const + 14
</span></span></pre></div>
<a id="tagsSafari600561SourceWebCoreWebCorexcodeprojprojectpbxproj"></a>
<div class="modfile"><h4>Modified: tags/Safari-600.5.6.1/Source/WebCore/WebCore.xcodeproj/project.pbxproj (180198 => 180199)</h4>
<pre class="diff"><span>
<span class="info">--- tags/Safari-600.5.6.1/Source/WebCore/WebCore.xcodeproj/project.pbxproj        2015-02-17 01:49:57 UTC (rev 180198)
+++ tags/Safari-600.5.6.1/Source/WebCore/WebCore.xcodeproj/project.pbxproj        2015-02-17 02:04:30 UTC (rev 180199)
</span><span class="lines">@@ -5582,6 +5582,7 @@
</span><span class="cx">                 C5278B0C17F212EA003A2998 /* PlatformPasteboardIOS.mm in Sources */ = {isa = PBXBuildFile; fileRef = C5278B0B17F212EA003A2998 /* PlatformPasteboardIOS.mm */; };
</span><span class="cx">                 C544274B11A57E7A0063A749 /* DOMStringList.h in Headers */ = {isa = PBXBuildFile; fileRef = C544274911A57E7A0063A749 /* DOMStringList.h */; settings = {ATTRIBUTES = (Private, ); }; };
</span><span class="cx">                 C55610F111A704EB00B82D27 /* DOMStringList.cpp in Sources */ = {isa = PBXBuildFile; fileRef = C55610F011A704EB00B82D27 /* DOMStringList.cpp */; };
</span><ins>+                C5592F781A92AA28001F8862 /* CharacterProperties.h in Headers */ = {isa = PBXBuildFile; fileRef = C5592F771A92AA28001F8862 /* CharacterProperties.h */; };
</ins><span class="cx">                 C55C7BA11718AFBA001327E4 /* RenderThemeIOS.mm in Sources */ = {isa = PBXBuildFile; fileRef = C55C7BA01718AFBA001327E4 /* RenderThemeIOS.mm */; };
</span><span class="cx">                 C55E38BF10040D5D00A56BDB /* StorageNamespaceImpl.h in Headers */ = {isa = PBXBuildFile; fileRef = C55E38BB10040D5D00A56BDB /* StorageNamespaceImpl.h */; };
</span><span class="cx">                 C55E38C010040D5D00A56BDB /* StorageNamespaceImpl.cpp in Sources */ = {isa = PBXBuildFile; fileRef = C55E38BC10040D5D00A56BDB /* StorageNamespaceImpl.cpp */; };
</span><span class="lines">@@ -13041,6 +13042,7 @@
</span><span class="cx">                 C544274911A57E7A0063A749 /* DOMStringList.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DOMStringList.h; sourceTree = "<group>"; };
</span><span class="cx">                 C544274A11A57E7A0063A749 /* DOMStringList.idl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = DOMStringList.idl; sourceTree = "<group>"; };
</span><span class="cx">                 C55610F011A704EB00B82D27 /* DOMStringList.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = DOMStringList.cpp; sourceTree = "<group>"; };
</span><ins>+                C5592F771A92AA28001F8862 /* CharacterProperties.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CharacterProperties.h; sourceTree = "<group>"; };
</ins><span class="cx">                 C55C7BA01718AFBA001327E4 /* RenderThemeIOS.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = RenderThemeIOS.mm; sourceTree = "<group>"; };
</span><span class="cx">                 C55E38BB10040D5D00A56BDB /* StorageNamespaceImpl.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = StorageNamespaceImpl.h; sourceTree = "<group>"; };
</span><span class="cx">                 C55E38BC10040D5D00A56BDB /* StorageNamespaceImpl.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = StorageNamespaceImpl.cpp; sourceTree = "<group>"; };
</span><span class="lines">@@ -20695,6 +20697,7 @@
</span><span class="cx">                                 B2C3D9F30D006C1D00EF6F26 /* BidiContext.h */,
</span><span class="cx">                                 B2C3D9F40D006C1D00EF6F26 /* BidiResolver.h */,
</span><span class="cx">                                 A8C402921348B2220063F1E5 /* BidiRunList.h */,
</span><ins>+                                C5592F771A92AA28001F8862 /* CharacterProperties.h */,
</ins><span class="cx">                                 0FDA7C2018832BCC00C954B5 /* DateTimeFormat.cpp */,
</span><span class="cx">                                 453EB635159C570400001BB7 /* DateTimeFormat.h */,
</span><span class="cx">                                 CECCFC3A141973D5002A0AC1 /* DecodeEscapeSequences.h */,
</span><span class="lines">@@ -23890,6 +23893,7 @@
</span><span class="cx">                                 59A8F1D811A69520001AC34A /* DeviceOrientationClient.h in Headers */,
</span><span class="cx">                                 3140379D124BEA7F00AF40E4 /* DeviceOrientationClientIOS.h in Headers */,
</span><span class="cx">                                 59309A1311F4AE6A00250603 /* DeviceOrientationClientMock.h in Headers */,
</span><ins>+                                C5592F781A92AA28001F8862 /* CharacterProperties.h in Headers */,
</ins><span class="cx">                                 59A8F1D611A69513001AC34A /* DeviceOrientationController.h in Headers */,
</span><span class="cx">                                 590E1B4911E4EF4B0069F784 /* DeviceOrientationData.h in Headers */,
</span><span class="cx">                                 59A85EA4119D68EC00DEF1EF /* DeviceOrientationEvent.h in Headers */,
</span></span></pre></div>
<a id="tagsSafari600561SourceWebCoreplatformgraphicsFontcpp"></a>
<div class="modfile"><h4>Modified: tags/Safari-600.5.6.1/Source/WebCore/platform/graphics/Font.cpp (180198 => 180199)</h4>
<pre class="diff"><span>
<span class="info">--- tags/Safari-600.5.6.1/Source/WebCore/platform/graphics/Font.cpp        2015-02-17 01:49:57 UTC (rev 180198)
+++ tags/Safari-600.5.6.1/Source/WebCore/platform/graphics/Font.cpp        2015-02-17 02:04:30 UTC (rev 180199)
</span><span class="lines">@@ -24,6 +24,7 @@
</span><span class="cx"> #include "config.h"
</span><span class="cx"> #include "Font.h"
</span><span class="cx">
</span><ins>+#include "CharacterProperties.h"
</ins><span class="cx"> #include "FloatRect.h"
</span><span class="cx"> #include "FontCache.h"
</span><span class="cx"> #include "GlyphBuffer.h"
</span><span class="lines">@@ -751,6 +752,8 @@
</span><span class="cx"> previousCharacterIsEmojiGroupCandidate = true;
</span><span class="cx"> continue;
</span><span class="cx"> }
</span><ins>+ if (isEmojiModifier(supplementaryCharacter))
+ return Complex;
</ins><span class="cx"> if (supplementaryCharacter < 0xE0100) // U+E0100 through U+E01EF Unicode variation selectors.
</span><span class="cx"> continue;
</span><span class="cx"> if (supplementaryCharacter <= 0xE01EF)
</span></span></pre></div>
<a id="tagsSafari600561SourceWebCoreplatformgraphicsmacComplexTextControllercpp"></a>
<div class="modfile"><h4>Modified: tags/Safari-600.5.6.1/Source/WebCore/platform/graphics/mac/ComplexTextController.cpp (180198 => 180199)</h4>
<pre class="diff"><span>
<span class="info">--- tags/Safari-600.5.6.1/Source/WebCore/platform/graphics/mac/ComplexTextController.cpp        2015-02-17 01:49:57 UTC (rev 180198)
+++ tags/Safari-600.5.6.1/Source/WebCore/platform/graphics/mac/ComplexTextController.cpp        2015-02-17 02:04:30 UTC (rev 180199)
</span><span class="lines">@@ -25,6 +25,7 @@
</span><span class="cx"> #include "config.h"
</span><span class="cx"> #include "ComplexTextController.h"
</span><span class="cx">
</span><ins>+#include "CharacterProperties.h"
</ins><span class="cx"> #include "FloatSize.h"
</span><span class="cx"> #include "Font.h"
</span><span class="cx"> #include "RenderBlock.h"
</span><span class="lines">@@ -262,6 +263,8 @@
</span><span class="cx"> return 0;
</span><span class="cx"> }
</span><span class="cx">
</span><ins>+// FIXME: We should consider reimplementing this function using ICU to advance by grapheme.
+// The current implementation only considers explicitly emoji sequences and emoji variations.
</ins><span class="cx"> static bool advanceByCombiningCharacterSequence(const UChar*& iterator, const UChar* end, UChar32& baseCharacter, unsigned& markCount)
</span><span class="cx"> {
</span><span class="cx"> ASSERT(iterator < end);
</span><span class="lines">@@ -272,17 +275,33 @@
</span><span class="cx"> unsigned remainingCharacters = end - iterator;
</span><span class="cx"> U16_NEXT(iterator, i, remainingCharacters, baseCharacter);
</span><span class="cx"> iterator = iterator + i;
</span><del>-
</del><span class="cx"> if (U_IS_SURROGATE(baseCharacter))
</span><span class="cx"> return false;
</span><span class="cx">
</span><span class="cx"> // Consume marks.
</span><ins>+ bool sawEmojiGroupCandidate = isEmojiGroupCandidate(baseCharacter);
+ bool sawJoiner = false;
</ins><span class="cx"> while (iterator < end) {
</span><span class="cx"> UChar32 nextCharacter;
</span><span class="cx"> int markLength = 0;
</span><ins>+ bool shouldContinue = false;
</ins><span class="cx"> U16_NEXT(iterator, markLength, end - iterator, nextCharacter);
</span><del>- if (!(U_GET_GC_MASK(nextCharacter) & U_GC_M_MASK))
</del><ins>+
+ if (isVariationSelector(nextCharacter) || isEmojiModifier(nextCharacter))
+ shouldContinue = true;
+
+ if (sawJoiner && isEmojiGroupCandidate(nextCharacter))
+ shouldContinue = true;
+
+ sawJoiner = false;
+ if (sawEmojiGroupCandidate && nextCharacter == zeroWidthJoiner) {
+ sawJoiner = true;
+ shouldContinue = true;
+ }
+
+ if (!shouldContinue && !(U_GET_GC_MASK(nextCharacter) & U_GC_M_MASK))
</ins><span class="cx"> break;
</span><ins>+
</ins><span class="cx"> markCount += markLength;
</span><span class="cx"> iterator += markLength;
</span><span class="cx"> }
</span></span></pre></div>
<a id="tagsSafari600561SourceWebCoreplatformtextCharacterPropertieshfromrev180198branchessafari6005branchSourceWebCoreplatformtextCharacterPropertiesh"></a>
<div class="copfile"><h4>Copied: tags/Safari-600.5.6.1/Source/WebCore/platform/text/CharacterProperties.h (from rev 180198, branches/safari-600.5-branch/Source/WebCore/platform/text/CharacterProperties.h) (0 => 180199)</h4>
<pre class="diff"><span>
<span class="info">--- tags/Safari-600.5.6.1/Source/WebCore/platform/text/CharacterProperties.h         (rev 0)
+++ tags/Safari-600.5.6.1/Source/WebCore/platform/text/CharacterProperties.h        2015-02-17 02:04:30 UTC (rev 180199)
</span><span class="lines">@@ -0,0 +1,48 @@
</span><ins>+/*
+ * Copyright (C) 2015 Apple, Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. ``AS IS'' AND ANY
+ * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR
+ * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
+ * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+ * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
+ * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
+ * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#ifndef CharacterProperties_h
+#define CharacterProperties_h
+
+namespace WebCore {
+
+static inline bool isEmojiGroupCandidate(UChar32 character)
+{
+ return (character >= 0x1F466 && character <= 0x1F469) || character == 0x2764 || character == 0x1F48B;
+}
+
+static inline bool isEmojiModifier(UChar32 character)
+{
+ return character >= 0x1F3FB && character <= 0x1F3FF;
+}
+
+inline bool isVariationSelector(UChar32 character)
+{
+ return character >= 0xFE00 && character <= 0xFE0F;
+}
+
+}
+
+#endif
</ins></span></pre></div>
<a id="tagsSafari600561SourceWebCorerenderingRenderTextcpp"></a>
<div class="modfile"><h4>Modified: tags/Safari-600.5.6.1/Source/WebCore/rendering/RenderText.cpp (180198 => 180199)</h4>
<pre class="diff"><span>
<span class="info">--- tags/Safari-600.5.6.1/Source/WebCore/rendering/RenderText.cpp        2015-02-17 01:49:57 UTC (rev 180198)
+++ tags/Safari-600.5.6.1/Source/WebCore/rendering/RenderText.cpp        2015-02-17 02:04:30 UTC (rev 180199)
</span><span class="lines">@@ -26,6 +26,7 @@
</span><span class="cx"> #include "RenderText.h"
</span><span class="cx">
</span><span class="cx"> #include "AXObjectCache.h"
</span><ins>+#include "CharacterProperties.h"
</ins><span class="cx"> #include "EllipsisBox.h"
</span><span class="cx"> #include "FloatQuad.h"
</span><span class="cx"> #include "Frame.h"
</span><span class="lines">@@ -1392,16 +1393,6 @@
</span><span class="cx"> return 0x1F1E6 <= character && character <= 0x1F1FF;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-static inline bool isEmojiGroupCandidate(UChar32 character)
-{
- return character >= 0x1F466 && character <= 0x1F469;
-}
-
-static inline bool isEmojiModifier(UChar32 character)
-{
- return character >= 0x1F3FB && character <= 0x1F3FF;
-}
-
</del><span class="cx"> #endif
</span><span class="cx">
</span><span class="cx"> int RenderText::previousOffsetForBackwardDeletion(int current) const
</span></span></pre>
</div>
</div>
</body>
</html>