Changeset 91935 in webkit


Ignore:
Timestamp:
Jul 28, 2011 9:33:33 AM (13 years ago)
Author:
mitz@apple.com
Message:

Source/WebCore: <rdar://problem/9589433> Displaying Japanese dictionary contents in vertical orientation takes a couple of seconds

Reviewed by Darin Adler.

  • WebCore.exp.in: Exported wkGetVerticalGlyphsForCharacters.
  • platform/graphics/mac/GlyphPageTreeNodeMac.cpp:

(WebCore::GlyphPage::fill): Use wkGetVerticalGlyphsForCharacters. If it returns false, proceed
with the existing, slower method of getting vertical glyphs.

  • platform/mac/WebCoreSystemInterface.h:
  • platform/mac/WebCoreSystemInterface.mm:

Source/WebKit/mac: <rdar://problem/9589433> Displaying Japanese dictionary contents in vertical orientation takes a couple of seconds

Reviewed by Darin Adler.

  • WebCoreSupport/WebSystemInterface.mm:

(InitWebCoreSystemInterface): Initialize wkGetVerticalGlyphsForCharacters.

Source/WebKit2: <rdar://problem/9589433> Displaying Japanese dictionary contents in vertical orientation takes a couple of seconds

Reviewed by Darin Adler.

  • WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:

(InitWebCoreSystemInterface): Initialize wkGetVerticalGlyphsForCharacters.

WebKitLibraries: WebKitSystemInterface support for
<rdar://problem/9589433> Displaying Japanese dictionary contents in vertical orientation takes a couple of seconds

Reviewed by Darin Adler.

  • WebKitSystemInterface.h: Added WKGetVerticalGlyphsForCharacters().
  • libWebKitSystemInterfaceLeopard.a:
  • libWebKitSystemInterfaceLion.a:
  • libWebKitSystemInterfaceSnowLeopard.a:
Location:
trunk
Files:
14 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r91931 r91935  
     12011-07-28  Dan Bernstein  <mitz@apple.com>
     2
     3        <rdar://problem/9589433> Displaying Japanese dictionary contents in vertical orientation takes a couple of seconds
     4
     5        Reviewed by Darin Adler.
     6
     7        * WebCore.exp.in: Exported wkGetVerticalGlyphsForCharacters.
     8        * platform/graphics/mac/GlyphPageTreeNodeMac.cpp:
     9        (WebCore::GlyphPage::fill): Use wkGetVerticalGlyphsForCharacters. If it returns false, proceed
     10        with the existing, slower method of getting vertical glyphs.
     11        * platform/mac/WebCoreSystemInterface.h:
     12        * platform/mac/WebCoreSystemInterface.mm:
     13
    1142011-07-28  Brady Eidson  <beidson@apple.com>
    215
  • trunk/Source/WebCore/WebCore.exp.in

    r91931 r91935  
    13851385_wkGetPreferredExtensionForMIMEType
    13861386_wkGetUserToBaseCTM
     1387_wkGetVerticalGlyphsForCharacters
    13871388_wkGetWheelEventDeltas
    13881389_wkHTTPCookiesForURL
  • trunk/Source/WebCore/platform/graphics/mac/GlyphPageTreeNodeMac.cpp

    r85501 r91935  
    5454    bool haveGlyphs = false;
    5555
     56    Vector<CGGlyph, 512> glyphs(bufferLength);
    5657    if (!shouldUseCoreText(buffer, bufferLength, fontData)) {
    57         Vector<CGGlyph, 512> glyphs(bufferLength);
    5858        wkGetGlyphsForCharacters(fontData->platformData().cgFont(), buffer, glyphs.data(), bufferLength);
     59        for (unsigned i = 0; i < length; ++i) {
     60            if (!glyphs[i])
     61                setGlyphDataForIndex(offset + i, 0, 0);
     62            else {
     63                setGlyphDataForIndex(offset + i, glyphs[i], fontData);
     64                haveGlyphs = true;
     65            }
     66        }
     67    } else if (wkGetVerticalGlyphsForCharacters(fontData->platformData().ctFont(), buffer, glyphs.data(), bufferLength)) {
    5968        for (unsigned i = 0; i < length; ++i) {
    6069            if (!glyphs[i])
  • trunk/Source/WebCore/platform/mac/WebCoreSystemInterface.h

    r91616 r91935  
    4747typedef struct _CFURLResponse *CFURLResponseRef;
    4848typedef const struct _CFURLRequest *CFURLRequestRef;
     49typedef const struct __CTFont * CTFontRef;
    4950typedef const struct __CTLine * CTLineRef;
    5051typedef const struct __CTTypesetter * CTTypesetterRef;
     
    222223
    223224extern void (*wkGetGlyphsForCharacters)(CGFontRef, const UniChar[], CGGlyph[], size_t);
     225extern bool (*wkGetVerticalGlyphsForCharacters)(CTFontRef, const UniChar[], CGGlyph[], size_t);
    224226
    225227extern BOOL (*wkUseSharedMediaUI)();
  • trunk/Source/WebCore/platform/mac/WebCoreSystemInterface.mm

    r91616 r91935  
    118118
    119119void (*wkGetGlyphsForCharacters)(CGFontRef, const UniChar[], CGGlyph[], size_t);
     120bool (*wkGetVerticalGlyphsForCharacters)(CTFontRef, const UniChar[], CGGlyph[], size_t);
    120121
    121122#if !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD)
  • trunk/Source/WebKit/mac/ChangeLog

    r91931 r91935  
     12011-07-28  Dan Bernstein  <mitz@apple.com>
     2
     3        <rdar://problem/9589433> Displaying Japanese dictionary contents in vertical orientation takes a couple of seconds
     4
     5        Reviewed by Darin Adler.
     6
     7        * WebCoreSupport/WebSystemInterface.mm:
     8        (InitWebCoreSystemInterface): Initialize wkGetVerticalGlyphsForCharacters.
     9
    1102011-07-28  Brady Eidson  <beidson@apple.com>
    211
  • trunk/Source/WebKit/mac/WebCoreSupport/WebSystemInterface.mm

    r91154 r91935  
    110110
    111111    INIT(GetGlyphsForCharacters);
     112    INIT(GetVerticalGlyphsForCharacters);
    112113
    113114#if defined(BUILDING_ON_LEOPARD) || defined(BUILDING_ON_SNOW_LEOPARD)
  • trunk/Source/WebKit2/ChangeLog

    r91931 r91935  
     12011-07-28  Dan Bernstein  <mitz@apple.com>
     2
     3        <rdar://problem/9589433> Displaying Japanese dictionary contents in vertical orientation takes a couple of seconds
     4
     5        Reviewed by Darin Adler.
     6
     7        * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
     8        (InitWebCoreSystemInterface): Initialize wkGetVerticalGlyphsForCharacters.
     9
    1102011-07-28  Brady Eidson  <beidson@apple.com>
    211
  • trunk/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebSystemInterface.mm

    r91616 r91935  
    5757        INIT(GetGlyphTransformedAdvances);
    5858        INIT(GetGlyphsForCharacters);
     59        INIT(GetVerticalGlyphsForCharacters);
    5960        INIT(GetHTTPPipeliningPriority);
    6061        INIT(GetMIMETypeForExtension);
  • trunk/WebKitLibraries/ChangeLog

    r91616 r91935  
     12011-07-28  Dan Bernstein  <mitz@apple.com>
     2
     3        WebKitSystemInterface support for
     4        <rdar://problem/9589433> Displaying Japanese dictionary contents in vertical orientation takes a couple of seconds
     5
     6        Reviewed by Darin Adler.
     7
     8        * WebKitSystemInterface.h: Added WKGetVerticalGlyphsForCharacters().
     9        * libWebKitSystemInterfaceLeopard.a:
     10        * libWebKitSystemInterfaceLion.a:
     11        * libWebKitSystemInterfaceSnowLeopard.a:
     12
    1132011-07-22  Jessie Berlin  <jberlin@apple.com>
    214
  • trunk/WebKitLibraries/WebKitSystemInterface.h

    r91616 r91935  
    154154
    155155void WKGetGlyphsForCharacters(CGFontRef, const UniChar[], CGGlyph[], size_t);
     156bool WKGetVerticalGlyphsForCharacters(CTFontRef, const UniChar[], CGGlyph[], size_t);
    156157
    157158CTLineRef WKCreateCTLineWithUniCharProvider(const UniChar* (*provide)(CFIndex stringIndex, CFIndex* charCount, CFDictionaryRef* attributes, void*), void (*dispose)(const UniChar* chars, void*), void*);
Note: See TracChangeset for help on using the changeset viewer.