Addressing post-review comments.
authormmaxfield@apple.com <mmaxfield@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 1 Apr 2015 17:43:21 +0000 (17:43 +0000)
committermmaxfield@apple.com <mmaxfield@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 1 Apr 2015 17:43:21 +0000 (17:43 +0000)
https://bugs.webkit.org/show_bug.cgi?id=143292

Unreviewed.

* platform/graphics/FontCascade.cpp:
(WebCore::FontCascade::leadingExpansionOpportunity):
(WebCore::FontCascade::trailingExpansionOpportunity):

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

Source/WebCore/ChangeLog
Source/WebCore/platform/graphics/FontCascade.cpp

index 7cdd7920f30c3949ffc7d4d0dedda6f34cdb3d25..ec8aebfa2e89335e0443c84b6a494991ab4ea91f 100644 (file)
@@ -1,3 +1,14 @@
+2015-04-01  Myles C. Maxfield  <mmaxfield@apple.com>
+
+        Addressing post-review comments.
+        https://bugs.webkit.org/show_bug.cgi?id=143292
+
+        Unreviewed.
+
+        * platform/graphics/FontCascade.cpp:
+        (WebCore::FontCascade::leadingExpansionOpportunity):
+        (WebCore::FontCascade::trailingExpansionOpportunity):
+
 2015-04-01  Per Arne Vollan  <peavo@outlook.com>
 
         [WinCairo] Link errors, unresolved texture mapper methods.
index 1d66a9f48a77bc5b9215cc3ee6d74573c9619459..6806e6fd84a4e8f75171a944b703e20cfe5e969d 100644 (file)
@@ -1121,11 +1121,11 @@ bool FontCascade::leadingExpansionOpportunity(const StringView& stringView, Text
     UChar32 initialCharacter;
     if (direction == LTR) {
         initialCharacter = stringView[0];
-        if (!stringView.is8Bit() && U16_IS_LEAD(initialCharacter) && stringView.length() > 1 && U16_IS_TRAIL(stringView[1]))
+        if (U16_IS_LEAD(initialCharacter) && stringView.length() > 1 && U16_IS_TRAIL(stringView[1]))
             initialCharacter = U16_GET_SUPPLEMENTARY(initialCharacter, stringView[1]);
     } else {
         initialCharacter = stringView[stringView.length() - 1];
-        if (!stringView.is8Bit() && U16_IS_TRAIL(initialCharacter) && stringView.length() > 1 && U16_IS_LEAD(stringView[stringView.length() - 2]))
+        if (U16_IS_TRAIL(initialCharacter) && stringView.length() > 1 && U16_IS_LEAD(stringView[stringView.length() - 2]))
             initialCharacter = U16_GET_SUPPLEMENTARY(stringView[stringView.length() - 2], initialCharacter);
     }
 
@@ -1140,11 +1140,11 @@ bool FontCascade::trailingExpansionOpportunity(const StringView& stringView, Tex
     UChar32 finalCharacter;
     if (direction == LTR) {
         finalCharacter = stringView[stringView.length() - 1];
-        if (!stringView.is8Bit() && U16_IS_TRAIL(finalCharacter) && stringView.length() > 1 && U16_IS_LEAD(stringView[stringView.length() - 2]))
+        if (U16_IS_TRAIL(finalCharacter) && stringView.length() > 1 && U16_IS_LEAD(stringView[stringView.length() - 2]))
             finalCharacter = U16_GET_SUPPLEMENTARY(stringView[stringView.length() - 2], finalCharacter);
     } else {
         finalCharacter = stringView[0];
-        if (!stringView.is8Bit() && U16_IS_LEAD(finalCharacter) && stringView.length() > 1 && U16_IS_TRAIL(stringView[1]))
+        if (U16_IS_LEAD(finalCharacter) && stringView.length() > 1 && U16_IS_TRAIL(stringView[1]))
             finalCharacter = U16_GET_SUPPLEMENTARY(finalCharacter, stringView[1]);
     }