Changeset 215366 in webkit


Ignore:
Timestamp:
Apr 14, 2017 10:57:26 AM (7 years ago)
Author:
mmaxfield@apple.com
Message:

Add performance test for asking the platform for a font for U+2060 WORD JOINER
https://bugs.webkit.org/show_bug.cgi?id=170842

Reviewed by Tim Horton.

PerformanceTests:

  • Layout/word-joiner.html: Added.

Source/WebCore:

No new tests because there is no behavior change.

  • platform/graphics/WidthCache.h:

(WebCore::WidthCache::add):
(WebCore::WidthCache::addSlowCase):

Source/WTF:

  • wtf/unicode/CharacterNames.h:
Location:
trunk
Files:
1 added
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/PerformanceTests/ChangeLog

    r214828 r215366  
     12017-04-14  Myles C. Maxfield  <mmaxfield@apple.com>
     2
     3        Add performance test for asking the platform for a font for U+2060 WORD JOINER
     4        https://bugs.webkit.org/show_bug.cgi?id=170842
     5
     6        Reviewed by Tim Horton.
     7
     8        * Layout/word-joiner.html: Added.
     9
    1102017-04-03  Saam Barati  <sbarati@apple.com>
    211
  • trunk/Source/WTF/ChangeLog

    r215359 r215366  
     12017-04-14  Myles C. Maxfield  <mmaxfield@apple.com>
     2
     3        Add performance test for asking the platform for a font for U+2060 WORD JOINER
     4        https://bugs.webkit.org/show_bug.cgi?id=170842
     5
     6        Reviewed by Tim Horton.
     7
     8        * wtf/unicode/CharacterNames.h:
     9
    1102017-04-13  Yusuke Suzuki  <utatane.tea@gmail.com>
    211
  • trunk/Source/WTF/wtf/unicode/CharacterNames.h

    r205826 r215366  
    9393const UChar whiteSesameDot = 0xFE46;
    9494const UChar whiteUpPointingTriangle = 0x25B3;
     95const UChar wordJoiner = 0x2060;
    9596const UChar yenSign = 0x00A5;
    9697const UChar zeroWidthJoiner = 0x200D;
     
    155156using WTF::Unicode::whiteSesameDot;
    156157using WTF::Unicode::whiteUpPointingTriangle;
     158using WTF::Unicode::wordJoiner;
    157159using WTF::Unicode::yenSign;
    158160using WTF::Unicode::zeroWidthJoiner;
  • trunk/Source/WebCore/ChangeLog

    r215364 r215366  
     12017-04-14  Myles C. Maxfield  <mmaxfield@apple.com>
     2
     3        Add performance test for asking the platform for a font for U+2060 WORD JOINER
     4        https://bugs.webkit.org/show_bug.cgi?id=170842
     5
     6        Reviewed by Tim Horton.
     7
     8        No new tests because there is no behavior change.
     9
     10        * platform/graphics/WidthCache.h:
     11        (WebCore::WidthCache::add):
     12        (WebCore::WidthCache::addSlowCase):
     13
    1142017-04-14  Ryan Haddad  <ryanhaddad@apple.com>
    215
  • trunk/Source/WebCore/platform/graphics/WidthCache.h

    r213214 r215366  
    141141        // The width cache is not really profitable unless we're doing expensive glyph transformations.
    142142        if (!hasKerningOrLigatures)
    143             return 0;
     143            return nullptr;
    144144        // Word spacing and letter spacing can change the width of a word.
    145145        if (hasWordSpacingOrLetterSpacing)
    146             return 0;
     146            return nullptr;
    147147        // Since this is just a width cache, we don't have enough information to satisfy glyph queries.
    148148        if (glyphOverflow)
    149             return 0;
     149            return nullptr;
    150150        // If we allow tabs and a tab occurs inside a word, the width of the word varies based on its position on the line.
    151151        if (run.allowTabs())
    152             return 0;
     152            return nullptr;
    153153        if (static_cast<unsigned>(run.length()) > SmallStringKey::capacity())
    154             return 0;
     154            return nullptr;
    155155
    156156        if (m_countdown > 0) {
    157157            --m_countdown;
    158             return 0;
     158            return nullptr;
    159159        }
    160160
     
    208208        m_singleCharMap.clear();
    209209        m_map.clear();
    210         return 0;
     210        return nullptr;
    211211    }
    212212
Note: See TracChangeset for help on using the changeset viewer.