Changeset 212776 in webkit


Ignore:
Timestamp:
Feb 21, 2017 4:30:32 PM (7 years ago)
Author:
Simon Fraser
Message:

Add support to PlatformCALayer/GraphicsLayerCA for subpixel-antialiased text, with a Setting and a MiniBrowser switch
https://bugs.webkit.org/show_bug.cgi?id=168620
<rdar://problem/30617772>

Reviewed by Tim Horton.
Source/WebCore:

Add a Setting for subpixel-antialiased layer text. Plumb this through GraphicsLayerCA and
PlatformCALayer, where it ultimately affects the layer contents format.

TileControllers are slightly special because we communicate with them via an Obj-C
WebTiledBackingLayer.

Test: compositing/contents-format/subpixel-antialiased-text-enabled.html

  • page/Settings.in:
  • platform/graphics/GraphicsLayer.cpp:

(WebCore::GraphicsLayer::GraphicsLayer):
(WebCore::GraphicsLayer::dumpProperties):

  • platform/graphics/GraphicsLayer.h:

(WebCore::GraphicsLayer::supportsSubpixelAntialiasedText):
(WebCore::GraphicsLayer::setSupportsSubpixelAntialiasedText):

  • platform/graphics/ca/GraphicsLayerCA.cpp:

(WebCore::GraphicsLayerCA::setSupportsSubpixelAntialiasedText):
(WebCore::GraphicsLayerCA::commitLayerChangesBeforeSublayers):
(WebCore::GraphicsLayerCA::updateSupportsSubpixelAntialiasedText):

  • platform/graphics/ca/GraphicsLayerCA.h:
  • platform/graphics/ca/PlatformCALayer.cpp:

(WebCore::PlatformCALayer::drawRepaintIndicator):

  • platform/graphics/ca/PlatformCALayer.h:
  • platform/graphics/ca/TileController.cpp:

(WebCore::TileController::setWantsDeepColorBackingStore):
(WebCore::TileController::setSupportsSubpixelAntialiasedText):
(WebCore::TileController::setTilesOpaque):

  • platform/graphics/ca/TileController.h:
  • platform/graphics/ca/TileGrid.cpp:

(WebCore::TileGrid::updateTileLayerProperties):

  • platform/graphics/ca/cocoa/PlatformCALayerCocoa.h:
  • platform/graphics/ca/cocoa/PlatformCALayerCocoa.mm:

(PlatformCALayerCocoa::supportsSubpixelAntialiasedText):
(PlatformCALayerCocoa::setSupportsSubpixelAntialiasedText):
(layerContentsFormat):
(PlatformCALayerCocoa::updateContentsFormat):
(PlatformCALayer::drawLayerContents):

  • platform/graphics/ca/cocoa/WebTiledBackingLayer.h:
  • platform/graphics/ca/cocoa/WebTiledBackingLayer.mm:

(-[WebTiledBackingLayer drawsAsynchronously]):
(-[WebTiledBackingLayer setSupportsSubpixelAntialiasedText:]):
(-[WebTiledBackingLayer supportsSubpixelAntialiasedText]):

  • platform/spi/cocoa/QuartzCoreSPI.h:
  • rendering/RenderLayerBacking.cpp:

(WebCore::RenderLayerBacking::createGraphicsLayer):

Source/WebKit/mac:

  • WebView/WebPreferenceKeysPrivate.h:
  • WebView/WebPreferences.mm:

(+[WebPreferences initialize]):
(-[WebPreferences subpixelAntialiasedLayerTextEnabled]):
(-[WebPreferences setSubpixelAntialiasedLayerTextEnabled:]):

  • WebView/WebPreferencesPrivate.h:

Source/WebKit2:

Add a Setting for subpixel-antialiased layer text. Plumb this through GraphicsLayerCA and
PlatformCALayer, where it ultimately affects the layer contents format.

This is not supported with UI-side compositing.

  • Shared/WebPreferencesDefinitions.h:
  • UIProcess/API/C/WKPreferences.cpp:

(WKPreferencesSetSubpixelAntialiasedLayerTextEnabled):
(WKPreferencesGetSubpixelAntialiasedLayerTextEnabled):

  • UIProcess/API/C/WKPreferencesRefPrivate.h:
  • UIProcess/API/Cocoa/WKPreferences.mm:

(-[WKPreferences _subpixelAntialiasedLayerTextEnabled]):
(-[WKPreferences _setSubpixelAntialiasedLayerTextEnabled:]):

  • UIProcess/API/Cocoa/WKPreferencesPrivate.h:
  • WebProcess/WebPage/WebPage.cpp:

(WebKit::WebPage::updatePreferences):

  • WebProcess/WebPage/mac/PlatformCALayerRemote.cpp:

(WebKit::PlatformCALayerRemote::supportsSubpixelAntialiasedText):
(WebKit::PlatformCALayerRemote::setSupportsSubpixelAntialiasedText):

  • WebProcess/WebPage/mac/PlatformCALayerRemote.h:
  • WebProcess/WebPage/mac/PlatformCALayerRemoteTiledBacking.cpp:

(WebKit::PlatformCALayerRemoteTiledBacking::supportsSubpixelAntialiasedText):
(WebKit::PlatformCALayerRemoteTiledBacking::setSupportsSubpixelAntialiasedText):

  • WebProcess/WebPage/mac/PlatformCALayerRemoteTiledBacking.h:

Tools:

Add a setting that allows one to toggle subpixel-antialiased layer text on and off.

  • DumpRenderTree/mac/DumpRenderTree.mm:

(resetWebPreferencesToConsistentValues):

  • MiniBrowser/mac/SettingsController.h:
  • MiniBrowser/mac/SettingsController.m:

(-[SettingsController _populateMenu]):
(-[SettingsController validateMenuItem:]):
(-[SettingsController toggleSubpixelAntialiasedLayerTextEnabled:]):
(-[SettingsController subpixelAntialiasedLayerTextEnabled]):

  • MiniBrowser/mac/WK1BrowserWindowController.m:

(-[WK1BrowserWindowController didChangeSettings]):

  • MiniBrowser/mac/WK2BrowserWindowController.m:

(-[WK2BrowserWindowController didChangeSettings]):

  • WebKitTestRunner/TestController.cpp:

(WTR::TestController::resetPreferencesToConsistentValues):

Location:
trunk
Files:
5 added
41 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r212773 r212776  
     12017-02-20  Simon Fraser  <simon.fraser@apple.com>
     2
     3        Add support to PlatformCALayer/GraphicsLayerCA for subpixel-antialiased text, with a Setting and a MiniBrowser switch
     4        https://bugs.webkit.org/show_bug.cgi?id=168620
     5        <rdar://problem/30617772>
     6
     7        Reviewed by Tim Horton.
     8
     9        Add a Setting for subpixel-antialiased layer text. Plumb this through GraphicsLayerCA and
     10        PlatformCALayer, where it ultimately affects the layer contents format.
     11       
     12        TileControllers are slightly special because we communicate with them via an Obj-C
     13        WebTiledBackingLayer.
     14
     15        Test: compositing/contents-format/subpixel-antialiased-text-enabled.html
     16
     17        * page/Settings.in:
     18        * platform/graphics/GraphicsLayer.cpp:
     19        (WebCore::GraphicsLayer::GraphicsLayer):
     20        (WebCore::GraphicsLayer::dumpProperties):
     21        * platform/graphics/GraphicsLayer.h:
     22        (WebCore::GraphicsLayer::supportsSubpixelAntialiasedText):
     23        (WebCore::GraphicsLayer::setSupportsSubpixelAntialiasedText):
     24        * platform/graphics/ca/GraphicsLayerCA.cpp:
     25        (WebCore::GraphicsLayerCA::setSupportsSubpixelAntialiasedText):
     26        (WebCore::GraphicsLayerCA::commitLayerChangesBeforeSublayers):
     27        (WebCore::GraphicsLayerCA::updateSupportsSubpixelAntialiasedText):
     28        * platform/graphics/ca/GraphicsLayerCA.h:
     29        * platform/graphics/ca/PlatformCALayer.cpp:
     30        (WebCore::PlatformCALayer::drawRepaintIndicator):
     31        * platform/graphics/ca/PlatformCALayer.h:
     32        * platform/graphics/ca/TileController.cpp:
     33        (WebCore::TileController::setWantsDeepColorBackingStore):
     34        (WebCore::TileController::setSupportsSubpixelAntialiasedText):
     35        (WebCore::TileController::setTilesOpaque):
     36        * platform/graphics/ca/TileController.h:
     37        * platform/graphics/ca/TileGrid.cpp:
     38        (WebCore::TileGrid::updateTileLayerProperties):
     39        * platform/graphics/ca/cocoa/PlatformCALayerCocoa.h:
     40        * platform/graphics/ca/cocoa/PlatformCALayerCocoa.mm:
     41        (PlatformCALayerCocoa::supportsSubpixelAntialiasedText):
     42        (PlatformCALayerCocoa::setSupportsSubpixelAntialiasedText):
     43        (layerContentsFormat):
     44        (PlatformCALayerCocoa::updateContentsFormat):
     45        (PlatformCALayer::drawLayerContents):
     46        * platform/graphics/ca/cocoa/WebTiledBackingLayer.h:
     47        * platform/graphics/ca/cocoa/WebTiledBackingLayer.mm:
     48        (-[WebTiledBackingLayer drawsAsynchronously]):
     49        (-[WebTiledBackingLayer setSupportsSubpixelAntialiasedText:]):
     50        (-[WebTiledBackingLayer supportsSubpixelAntialiasedText]):
     51        * platform/spi/cocoa/QuartzCoreSPI.h:
     52        * rendering/RenderLayerBacking.cpp:
     53        (WebCore::RenderLayerBacking::createGraphicsLayer):
     54
    1552017-02-21  Chris Dumez  <cdumez@apple.com>
    256
  • trunk/Source/WebCore/page/Settings.in

    r212633 r212776  
    202202minimumZoomFontSize type=float, initial=defaultMinimumZoomFontSize(), conditional=TEXT_AUTOSIZING
    203203
     204subpixelAntialiasedLayerTextEnabled initial=false, setNeedsStyleRecalcInAllFrames=1
    204205simpleLineLayoutEnabled initial=true, setNeedsStyleRecalcInAllFrames=1
    205206simpleLineLayoutDebugBordersEnabled initial=false, setNeedsStyleRecalcInAllFrames=1
  • trunk/Source/WebCore/platform/graphics/GraphicsLayer.cpp

    r212153 r212776  
    116116    , m_type(type)
    117117    , m_contentsOpaque(false)
     118    , m_supportsSubpixelAntialiasedText(false)
    118119    , m_preserves3D(false)
    119120    , m_backfaceVisibility(true)
     
    763764    }
    764765
     766    if (m_supportsSubpixelAntialiasedText) {
     767        writeIndent(ts, indent + 1);
     768        ts << "(supports subpixel antialiased text " << m_supportsSubpixelAntialiasedText << ")\n";
     769    }
     770
    765771    if (m_preserves3D) {
    766772        writeIndent(ts, indent + 1);
  • trunk/Source/WebCore/platform/graphics/GraphicsLayer.h

    r212153 r212776  
    375375    virtual void setContentsOpaque(bool b) { m_contentsOpaque = b; }
    376376
     377    bool supportsSubpixelAntialiasedText() const { return m_supportsSubpixelAntialiasedText; }
     378    virtual void setSupportsSubpixelAntialiasedText(bool b) { m_supportsSubpixelAntialiasedText = b; }
     379
    377380    bool backfaceVisibility() const { return m_backfaceVisibility; }
    378381    virtual void setBackfaceVisibility(bool b) { m_backfaceVisibility = b; }
     
    632635
    633636    bool m_contentsOpaque : 1;
     637    bool m_supportsSubpixelAntialiasedText : 1;
    634638    bool m_preserves3D: 1;
    635639    bool m_backfaceVisibility : 1;
  • trunk/Source/WebCore/platform/graphics/ca/GraphicsLayerCA.cpp

    r212590 r212776  
    739739}
    740740
     741void GraphicsLayerCA::setSupportsSubpixelAntialiasedText(bool supportsSubpixelAntialiasedText)
     742{
     743    if (m_supportsSubpixelAntialiasedText == supportsSubpixelAntialiasedText)
     744        return;
     745
     746    GraphicsLayer::setSupportsSubpixelAntialiasedText(supportsSubpixelAntialiasedText);
     747    noteLayerPropertyChanged(SupportsSubpixelAntialiasedTextChanged);
     748}
     749
    741750void GraphicsLayerCA::setBackfaceVisibility(bool visible)
    742751{
     
    16721681        updateAcceleratesDrawing();
    16731682
     1683    if (m_uncommittedChanges & SupportsSubpixelAntialiasedTextChanged)
     1684        updateSupportsSubpixelAntialiasedText();
     1685
    16741686    if (m_uncommittedChanges & DebugIndicatorsChanged)
    16751687        updateDebugBorder();
     
    22012213{
    22022214    m_layer->setAcceleratesDrawing(m_acceleratesDrawing);
     2215}
     2216
     2217void GraphicsLayerCA::updateSupportsSubpixelAntialiasedText()
     2218{
     2219    m_layer->setSupportsSubpixelAntialiasedText(m_supportsSubpixelAntialiasedText);
    22032220}
    22042221
  • trunk/Source/WebCore/platform/graphics/ca/GraphicsLayerCA.h

    r212730 r212776  
    9595
    9696    WEBCORE_EXPORT void setContentsOpaque(bool) override;
     97    WEBCORE_EXPORT void setSupportsSubpixelAntialiasedText(bool) override;
     98
    9799    WEBCORE_EXPORT void setBackfaceVisibility(bool) override;
    98100
     
    406408    void updateContentsNeedsDisplay();
    407409    void updateAcceleratesDrawing();
     410    void updateSupportsSubpixelAntialiasedText();
    408411    void updateDebugBorder();
    409412    void updateTiles();
     
    453456
    454457    enum LayerChange : uint64_t {
    455         NoChange =                      0,
    456         NameChanged =                   1LLU << 1,
    457         ChildrenChanged =               1LLU << 2, // also used for content layer, and preserves-3d, and size if tiling changes?
    458         GeometryChanged =               1LLU << 3,
    459         TransformChanged =              1LLU << 4,
    460         ChildrenTransformChanged =      1LLU << 5,
    461         Preserves3DChanged =            1LLU << 6,
    462         MasksToBoundsChanged =          1LLU << 7,
    463         DrawsContentChanged =           1LLU << 8,
    464         BackgroundColorChanged =        1LLU << 9,
    465         ContentsOpaqueChanged =         1LLU << 10,
    466         BackfaceVisibilityChanged =     1LLU << 11,
    467         OpacityChanged =                1LLU << 12,
    468         AnimationChanged =              1LLU << 13,
    469         DirtyRectsChanged =             1LLU << 14,
    470         ContentsImageChanged =          1LLU << 15,
    471         ContentsPlatformLayerChanged =  1LLU << 16,
    472         ContentsColorLayerChanged =     1LLU << 17,
    473         ContentsRectsChanged =          1LLU << 18,
    474         MasksToBoundsRectChanged =      1LLU << 19,
    475         MaskLayerChanged =              1LLU << 20,
    476         ReplicatedLayerChanged =        1LLU << 21,
    477         ContentsNeedsDisplay =          1LLU << 22,
    478         AcceleratesDrawingChanged =     1LLU << 23,
    479         ContentsScaleChanged =          1LLU << 24,
    480         ContentsVisibilityChanged =     1LLU << 25,
    481         CoverageRectChanged =           1LLU << 26,
    482         FiltersChanged =                1LLU << 27,
    483         BackdropFiltersChanged =        1LLU << 28,
    484         BackdropFiltersRectChanged =    1LLU << 29,
    485         TilingAreaChanged =             1LLU << 30,
    486         TilesAdded =                    1LLU << 31,
    487         DebugIndicatorsChanged =        1LLU << 32,
    488         CustomAppearanceChanged =       1LLU << 33,
    489         BlendModeChanged =              1LLU << 34,
    490         ShapeChanged =                  1LLU << 35,
    491         WindRuleChanged =               1LLU << 36,
    492         UserInteractionEnabledChanged = 1LLU << 37,
     458        NoChange                                = 0,
     459        NameChanged                             = 1LLU << 1,
     460        ChildrenChanged                         = 1LLU << 2, // also used for content layer, and preserves-3d, and size if tiling changes?
     461        GeometryChanged                         = 1LLU << 3,
     462        TransformChanged                        = 1LLU << 4,
     463        ChildrenTransformChanged                = 1LLU << 5,
     464        Preserves3DChanged                      = 1LLU << 6,
     465        MasksToBoundsChanged                    = 1LLU << 7,
     466        DrawsContentChanged                     = 1LLU << 8,
     467        BackgroundColorChanged                  = 1LLU << 9,
     468        ContentsOpaqueChanged                   = 1LLU << 10,
     469        BackfaceVisibilityChanged               = 1LLU << 11,
     470        OpacityChanged                          = 1LLU << 12,
     471        AnimationChanged                        = 1LLU << 13,
     472        DirtyRectsChanged                       = 1LLU << 14,
     473        ContentsImageChanged                    = 1LLU << 15,
     474        ContentsPlatformLayerChanged            = 1LLU << 16,
     475        ContentsColorLayerChanged               = 1LLU << 17,
     476        ContentsRectsChanged                    = 1LLU << 18,
     477        MasksToBoundsRectChanged                = 1LLU << 19,
     478        MaskLayerChanged                        = 1LLU << 20,
     479        ReplicatedLayerChanged                  = 1LLU << 21,
     480        ContentsNeedsDisplay                    = 1LLU << 22,
     481        AcceleratesDrawingChanged               = 1LLU << 23,
     482        SupportsSubpixelAntialiasedTextChanged  = 1LLU << 24,
     483        ContentsScaleChanged                    = 1LLU << 25,
     484        ContentsVisibilityChanged               = 1LLU << 26,
     485        CoverageRectChanged                     = 1LLU << 27,
     486        FiltersChanged                          = 1LLU << 28,
     487        BackdropFiltersChanged                  = 1LLU << 29,
     488        BackdropFiltersRectChanged              = 1LLU << 30,
     489        TilingAreaChanged                       = 1LLU << 31,
     490        TilesAdded                              = 1LLU << 32,
     491        DebugIndicatorsChanged                  = 1LLU << 33,
     492        CustomAppearanceChanged                 = 1LLU << 34,
     493        BlendModeChanged                        = 1LLU << 35,
     494        ShapeChanged                            = 1LLU << 36,
     495        WindRuleChanged                         = 1LLU << 37,
     496        UserInteractionEnabledChanged           = 1LLU << 38,
    493497    };
    494498    typedef uint64_t LayerChangeFlags;
  • trunk/Source/WebCore/platform/graphics/ca/PlatformCALayer.cpp

    r212590 r212776  
    117117    }
    118118
     119    if (!platformCALayer->isOpaque() && platformCALayer->supportsSubpixelAntialiasedText()) {
     120        // Draw a gray shadow behind the repaint count.
     121        CGContextSetRGBFillColor(context, 1, 1, 1, 0.4);
     122        platformCALayer->drawTextAtPoint(context, indicatorBox.x() + 7, indicatorBox.y() + 24, CGSizeMake(1, -1), 22, text, strlen(text));
     123    }
     124
    119125    if (platformCALayer->acceleratesDrawing())
    120126        CGContextSetRGBFillColor(context, 1, 0, 0, 1);
  • trunk/Source/WebCore/platform/graphics/ca/PlatformCALayer.h

    r212590 r212776  
    180180    virtual void setWantsDeepColorBackingStore(bool) = 0;
    181181
     182    virtual bool supportsSubpixelAntialiasedText() const = 0;
     183    virtual void setSupportsSubpixelAntialiasedText(bool) = 0;
     184
    182185    virtual CFTypeRef contents() const = 0;
    183186    virtual void setContents(CFTypeRef) = 0;
  • trunk/Source/WebCore/platform/graphics/ca/TileController.cpp

    r212590 r212776  
    180180
    181181    m_wantsDeepColorBackingStore = wantsDeepColorBackingStore;
    182 
    183182    tileGrid().updateTileLayerProperties();
    184183}
    185184
     185void TileController::setSupportsSubpixelAntialiasedText(bool supportsSubpixelAntialiasedText)
     186{
     187    if (m_supportsSubpixelAntialiasedText == supportsSubpixelAntialiasedText)
     188        return;
     189
     190    m_supportsSubpixelAntialiasedText = supportsSubpixelAntialiasedText;
     191    tileGrid().updateTileLayerProperties();
     192}
     193
    186194void TileController::setTilesOpaque(bool opaque)
    187195{
    188196    if (opaque == m_tilesAreOpaque)
    189197        return;
     198
    190199    m_tilesAreOpaque = opaque;
    191 
    192200    tileGrid().updateTileLayerProperties();
    193201}
  • trunk/Source/WebCore/platform/graphics/ca/TileController.h

    r212590 r212776  
    7474    bool wantsDeepColorBackingStore() const { return m_wantsDeepColorBackingStore; }
    7575    WEBCORE_EXPORT void setWantsDeepColorBackingStore(bool);
     76
     77    bool supportsSubpixelAntialiasedText() const { return m_supportsSubpixelAntialiasedText; }
     78    WEBCORE_EXPORT void setSupportsSubpixelAntialiasedText(bool);
    7679
    7780    WEBCORE_EXPORT void setTilesOpaque(bool);
     
    222225    bool m_acceleratesDrawing { false };
    223226    bool m_wantsDeepColorBackingStore { false };
     227    bool m_supportsSubpixelAntialiasedText { false };
    224228    bool m_tilesAreOpaque { false };
    225229    bool m_hasTilesWithTemporaryScaleFactor { false }; // Used to make low-res tiles when zooming.
  • trunk/Source/WebCore/platform/graphics/ca/TileGrid.cpp

    r212590 r212776  
    200200    bool acceleratesDrawing = m_controller.acceleratesDrawing();
    201201    bool deepColor = m_controller.wantsDeepColorBackingStore();
     202    bool subpixelAntialiasedText = m_controller.supportsSubpixelAntialiasedText();
    202203    bool opaque = m_controller.tilesAreOpaque();
    203204    Color tileDebugBorderColor = m_controller.tileDebugBorderColor();
     
    208209        tileInfo.layer->setAcceleratesDrawing(acceleratesDrawing);
    209210        tileInfo.layer->setWantsDeepColorBackingStore(deepColor);
     211        tileInfo.layer->setSupportsSubpixelAntialiasedText(subpixelAntialiasedText);
    210212        tileInfo.layer->setOpaque(opaque);
    211213        tileInfo.layer->setBorderColor(tileDebugBorderColor);
  • trunk/Source/WebCore/platform/graphics/ca/cocoa/PlatformCALayerCocoa.h

    r212590 r212776  
    114114    void setWantsDeepColorBackingStore(bool) override;
    115115
     116    bool supportsSubpixelAntialiasedText() const override;
     117    void setSupportsSubpixelAntialiasedText(bool) override;
     118
    116119    CFTypeRef contents() const override;
    117120    void setContents(CFTypeRef) override;
     
    192195    std::unique_ptr<FloatRoundedRect> m_shapeRoundedRect;
    193196    bool m_wantsDeepColorBackingStore { false };
     197    bool m_supportsSubpixelAntialiasedText { false };
    194198};
    195199
  • trunk/Source/WebCore/platform/graphics/ca/cocoa/PlatformCALayerCocoa.mm

    r212590 r212776  
    706706}
    707707
     708bool PlatformCALayerCocoa::supportsSubpixelAntialiasedText() const
     709{
     710    return m_supportsSubpixelAntialiasedText;
     711}
     712
     713void PlatformCALayerCocoa::setSupportsSubpixelAntialiasedText(bool supportsSubpixelAntialiasedText)
     714{
     715    if (supportsSubpixelAntialiasedText == m_supportsSubpixelAntialiasedText)
     716        return;
     717   
     718    m_supportsSubpixelAntialiasedText = supportsSubpixelAntialiasedText;
     719
     720    if (usesTiledBackingLayer()) {
     721        [static_cast<WebTiledBackingLayer *>(m_layer.get()) setSupportsSubpixelAntialiasedText:m_supportsSubpixelAntialiasedText];
     722        return;
     723    }
     724
     725    updateContentsFormat();
     726}
     727
    708728CFTypeRef PlatformCALayerCocoa::contents() const
    709729{
     
    976996
    977997#if (PLATFORM(IOS) && __IPHONE_OS_VERSION_MIN_REQUIRED >= 90300) || (PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 101200)
    978 static NSString *layerContentsFormat(bool wantsDeepColor)
     998static NSString *layerContentsFormat(bool wantsDeepColor, bool supportsSubpixelAntialiasedFonts)
    979999{
    9801000#if PLATFORM(IOS) && __IPHONE_OS_VERSION_MIN_REQUIRED >= 90300
     
    9841004    UNUSED_PARAM(wantsDeepColor);
    9851005#endif
     1006
     1007#if PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 101200
     1008    if (supportsSubpixelAntialiasedFonts)
     1009        return kCAContentsFormatRGBA8ColorRGBA8LinearGlyphMask;
     1010#else
     1011    UNUSED_PARAM(supportsSubpixelAntialiasedFonts);
     1012#endif
     1013
    9861014    return nil;
    9871015}
     
    9931021        BEGIN_BLOCK_OBJC_EXCEPTIONS
    9941022#if (PLATFORM(IOS) && __IPHONE_OS_VERSION_MIN_REQUIRED >= 90300) || (PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 101200)
    995         if (NSString *formatString = layerContentsFormat(wantsDeepColorBackingStore()))
     1023        if (NSString *formatString = layerContentsFormat(wantsDeepColorBackingStore(), supportsSubpixelAntialiasedText()))
    9961024            [m_layer setContentsFormat:formatString];
    9971025#endif
     
    11081136        graphicsContext.setIsAcceleratedContext(platformCALayer->acceleratesDrawing());
    11091137       
    1110         if (!layerContents->platformCALayerContentsOpaque()) {
     1138        if (!layerContents->platformCALayerContentsOpaque() && !platformCALayer->supportsSubpixelAntialiasedText()) {
    11111139            // Turn off font smoothing to improve the appearance of text rendered onto a transparent background.
    11121140            graphicsContext.setShouldSmoothFonts(false);
  • trunk/Source/WebCore/platform/graphics/ca/cocoa/WebTiledBackingLayer.h

    r212590 r212776  
    4747- (BOOL)wantsDeepColorBackingStore;
    4848
     49- (void)setSupportsSubpixelAntialiasedText:(BOOL)supportsSubpixelAntialiasedText;
     50- (BOOL)supportsSubpixelAntialiasedText;
     51
    4952@end
    5053
  • trunk/Source/WebCore/platform/graphics/ca/cocoa/WebTiledBackingLayer.mm

    r212590 r212776  
    109109}
    110110
     111- (BOOL)drawsAsynchronously
     112{
     113    return _tileController ? _tileController->acceleratesDrawing() : NO;
     114}
     115
    111116- (void)setWantsDeepColorBackingStore:(BOOL)wantsDeepColor
    112117{
     
    119124}
    120125
    121 - (BOOL)drawsAsynchronously
     126- (void)setSupportsSubpixelAntialiasedText:(BOOL)supportsSubpixelAntialiasedText
    122127{
    123     return _tileController ? _tileController->acceleratesDrawing() : NO;
     128    _tileController->setSupportsSubpixelAntialiasedText(supportsSubpixelAntialiasedText);
     129}
     130
     131- (BOOL)supportsSubpixelAntialiasedText
     132{
     133    return _tileController->supportsSubpixelAntialiasedText();
    124134}
    125135
  • trunk/Source/WebCore/platform/graphics/ca/win/PlatformCALayerWin.cpp

    r212590 r212776  
    529529}
    530530
     531bool PlatformCALayerWin::supportsSubpixelAntialiasedText() const
     532{
     533    return false
     534}
     535
     536void PlatformCALayerWin::setSupportsSubpixelAntialiasedText(bool)
     537{
     538}
     539
    531540CFTypeRef PlatformCALayerWin::contents() const
    532541{
  • trunk/Source/WebCore/platform/graphics/ca/win/PlatformCALayerWin.h

    r212590 r212776  
    106106    void setWantsDeepColorBackingStore(bool) override;
    107107
     108    bool supportsSubpixelAntialiasedText() const override;
     109    void setSupportsSubpixelAntialiasedText(bool) override;
     110
    108111    CFTypeRef contents() const override;
    109112    void setContents(CFTypeRef) override;
  • trunk/Source/WebCore/platform/spi/cocoa/QuartzCoreSPI.h

    r212590 r212776  
    222222#endif
    223223
     224#if PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 101200
     225extern NSString * const kCAContentsFormatRGBA8ColorRGBA8LinearGlyphMask;
     226#endif
     227
    224228#if (PLATFORM(APPLETV) && __TV_OS_VERSION_MAX_ALLOWED < 100000) \
    225229    || (PLATFORM(WATCHOS) && __WATCH_OS_VERSION_MAX_ALLOWED < 30000) \
  • trunk/Source/WebCore/rendering/RenderLayerBacking.cpp

    r211750 r212776  
    143143    graphicsLayer->setAcceleratesDrawing(compositor().acceleratedDrawingEnabled());
    144144    graphicsLayer->setUsesDisplayListDrawing(compositor().displayListDrawingEnabled());
     145    graphicsLayer->setSupportsSubpixelAntialiasedText(renderer().settings().subpixelAntialiasedLayerTextEnabled());
    145146#endif
    146147   
  • trunk/Source/WebKit/mac/ChangeLog

    r212774 r212776  
     12017-02-20  Simon Fraser  <simon.fraser@apple.com>
     2
     3        Add support to PlatformCALayer/GraphicsLayerCA for subpixel-antialiased text, with a Setting and a MiniBrowser switch
     4        https://bugs.webkit.org/show_bug.cgi?id=168620
     5        <rdar://problem/30617772>
     6
     7        Reviewed by Tim Horton.
     8
     9        * WebView/WebPreferenceKeysPrivate.h:
     10        * WebView/WebPreferences.mm:
     11        (+[WebPreferences initialize]):
     12        (-[WebPreferences subpixelAntialiasedLayerTextEnabled]):
     13        (-[WebPreferences setSubpixelAntialiasedLayerTextEnabled:]):
     14        * WebView/WebPreferencesPrivate.h:
     15
    1162017-02-21  Aakash Jain  <aakash_jain@apple.com>
    217
  • trunk/Source/WebKit/mac/WebView/WebPreferenceKeysPrivate.h

    r212331 r212776  
    106106#define WebKitAcceleratedCompositingEnabledPreferenceKey @"WebKitAcceleratedCompositingEnabled"
    107107#define WebKitShowDebugBordersPreferenceKey @"WebKitShowDebugBorders"
     108#define WebKitSubpixelAntialiasedLayerTextEnabledPreferenceKey @"WebKitSubpixelAntialiasedLayerTextEnabled"
    108109#define WebKitSimpleLineLayoutEnabledPreferenceKey @"WebKitSimpleLineLayoutEnabled"
    109110#define WebKitSimpleLineLayoutDebugBordersEnabledPreferenceKey @"WebKitSimpleLineLayoutDebugBordersEnabled"
  • trunk/Source/WebKit/mac/WebView/WebPreferences.mm

    r212629 r212776  
    492492        [NSNumber numberWithBool:YES],  WebKitXSSAuditorEnabledPreferenceKey,
    493493        [NSNumber numberWithBool:YES],  WebKitAcceleratedCompositingEnabledPreferenceKey,
     494        [NSNumber numberWithBool:NO],   WebKitSubpixelAntialiasedLayerTextEnabledPreferenceKey,
    494495        [NSNumber numberWithBool:NO],   WebKitDisplayListDrawingEnabledPreferenceKey,
    495496#if PLATFORM(IOS) && !PLATFORM(IOS_SIMULATOR)
     
    19621963}
    19631964
     1965- (BOOL)subpixelAntialiasedLayerTextEnabled
     1966{
     1967    return [self _boolValueForKey:WebKitSubpixelAntialiasedLayerTextEnabledPreferenceKey];
     1968}
     1969
     1970- (void)setSubpixelAntialiasedLayerTextEnabled:(BOOL)enabled
     1971{
     1972    [self _setBoolValue:enabled forKey:WebKitSubpixelAntialiasedLayerTextEnabledPreferenceKey];
     1973}
     1974
    19641975- (BOOL)simpleLineLayoutEnabled
    19651976{
  • trunk/Source/WebKit/mac/WebView/WebPreferencesPrivate.h

    r212331 r212776  
    225225- (void)setAcceleratedCompositingEnabled:(BOOL)enabled;
    226226
     227- (BOOL)subpixelAntialiasedLayerTextEnabled;
     228- (void)setSubpixelAntialiasedLayerTextEnabled:(BOOL)enabled;
     229
    227230- (BOOL)showDebugBorders;
    228231- (void)setShowDebugBorders:(BOOL)show;
  • trunk/Source/WebKit2/ChangeLog

    r212766 r212776  
     12017-02-20  Simon Fraser  <simon.fraser@apple.com>
     2
     3        Add support to PlatformCALayer/GraphicsLayerCA for subpixel-antialiased text, with a Setting and a MiniBrowser switch
     4        https://bugs.webkit.org/show_bug.cgi?id=168620
     5        <rdar://problem/30617772>
     6
     7        Reviewed by Tim Horton.
     8
     9        Add a Setting for subpixel-antialiased layer text. Plumb this through GraphicsLayerCA and
     10        PlatformCALayer, where it ultimately affects the layer contents format.
     11       
     12        This is not supported with UI-side compositing.
     13
     14        * Shared/WebPreferencesDefinitions.h:
     15        * UIProcess/API/C/WKPreferences.cpp:
     16        (WKPreferencesSetSubpixelAntialiasedLayerTextEnabled):
     17        (WKPreferencesGetSubpixelAntialiasedLayerTextEnabled):
     18        * UIProcess/API/C/WKPreferencesRefPrivate.h:
     19        * UIProcess/API/Cocoa/WKPreferences.mm:
     20        (-[WKPreferences _subpixelAntialiasedLayerTextEnabled]):
     21        (-[WKPreferences _setSubpixelAntialiasedLayerTextEnabled:]):
     22        * UIProcess/API/Cocoa/WKPreferencesPrivate.h:
     23        * WebProcess/WebPage/WebPage.cpp:
     24        (WebKit::WebPage::updatePreferences):
     25        * WebProcess/WebPage/mac/PlatformCALayerRemote.cpp:
     26        (WebKit::PlatformCALayerRemote::supportsSubpixelAntialiasedText):
     27        (WebKit::PlatformCALayerRemote::setSupportsSubpixelAntialiasedText):
     28        * WebProcess/WebPage/mac/PlatformCALayerRemote.h:
     29        * WebProcess/WebPage/mac/PlatformCALayerRemoteTiledBacking.cpp:
     30        (WebKit::PlatformCALayerRemoteTiledBacking::supportsSubpixelAntialiasedText):
     31        (WebKit::PlatformCALayerRemoteTiledBacking::setSupportsSubpixelAntialiasedText):
     32        * WebProcess/WebPage/mac/PlatformCALayerRemoteTiledBacking.h:
     33
    1342017-02-21  John Wilander  <wilander@apple.com>
    235
  • trunk/Source/WebKit2/Shared/WebPreferencesDefinitions.h

    r212704 r212776  
    274274#define FOR_EACH_WEBKIT_DEBUG_BOOL_PREFERENCE(macro) \
    275275    macro(AcceleratedDrawingEnabled, acceleratedDrawingEnabled, Bool, bool, DEFAULT_ACCELERATED_DRAWING_ENABLED, "", "") \
     276    macro(SubpixelAntialiasedLayerTextEnabled, subpixelAntialiasedLayerTextEnabled, Bool, bool, false, "", "") \
    276277    macro(DisplayListDrawingEnabled, displayListDrawingEnabled, Bool, bool, false, "", "") \
    277278    macro(CompositingBordersVisible, compositingBordersVisible, Bool, bool, false, "", "") \
  • trunk/Source/WebKit2/UIProcess/API/C/WKPreferences.cpp

    r212173 r212776  
    384384}
    385385
     386void WKPreferencesSetSubpixelAntialiasedLayerTextEnabled(WKPreferencesRef preferencesRef, bool flag)
     387{
     388    toImpl(preferencesRef)->setSubpixelAntialiasedLayerTextEnabled(flag);
     389}
     390
     391bool WKPreferencesGetSubpixelAntialiasedLayerTextEnabled(WKPreferencesRef preferencesRef)
     392{
     393    return toImpl(preferencesRef)->subpixelAntialiasedLayerTextEnabled();
     394}
     395
    386396void WKPreferencesSetAcceleratedDrawingEnabled(WKPreferencesRef preferencesRef, bool flag)
    387397{
  • trunk/Source/WebKit2/UIProcess/API/C/WKPreferencesRefPrivate.h

    r212173 r212776  
    6464WK_EXPORT WKFontSmoothingLevel WKPreferencesGetFontSmoothingLevel(WKPreferencesRef);
    6565
     66// Defaults to false.
     67WK_EXPORT void WKPreferencesSetSubpixelAntialiasedLayerTextEnabled(WKPreferencesRef, bool);
     68WK_EXPORT bool WKPreferencesGetSubpixelAntialiasedLayerTextEnabled(WKPreferencesRef);
     69
    6670// Defaults to EditableLinkNeverLive.
    6771WK_EXPORT void WKPreferencesSetEditableLinkBehavior(WKPreferencesRef preferencesRef, WKEditableLinkBehavior);
  • trunk/Source/WebKit2/UIProcess/API/Cocoa/WKPreferences.mm

    r211135 r212776  
    366366}
    367367
     368- (BOOL)_subpixelAntialiasedLayerTextEnabled
     369{
     370    return _preferences->subpixelAntialiasedLayerTextEnabled();
     371}
     372
     373- (void)_setSubpixelAntialiasedLayerTextEnabled:(BOOL)enabled
     374{
     375    _preferences->setSubpixelAntialiasedLayerTextEnabled(enabled);
     376}
     377
    368378- (BOOL)_developerExtrasEnabled
    369379{
  • trunk/Source/WebKit2/UIProcess/API/Cocoa/WKPreferencesPrivate.h

    r211135 r212776  
    6868@property (nonatomic, setter=_setAnimatedImageAsyncDecodingEnabled:) BOOL _animatedImageAsyncDecodingEnabled WK_API_AVAILABLE(macosx(WK_MAC_TBA), ios(WK_IOS_TBA));
    6969@property (nonatomic, setter=_setTextAutosizingEnabled:) BOOL _textAutosizingEnabled WK_API_AVAILABLE(macosx(10.12), ios(10.0));
     70@property (nonatomic, setter=_setSubpixelAntialiasedLayerTextEnabled:) BOOL _subpixelAntialiasedLayerTextEnabled WK_API_AVAILABLE(macosx(10.12), ios(10.0));
    7071
    7172@property (nonatomic, setter=_setDeveloperExtrasEnabled:) BOOL _developerExtrasEnabled WK_API_AVAILABLE(macosx(10.11), ios(9.0));
  • trunk/Source/WebKit2/WebProcess/WebPage/WebPage.cpp

    r212745 r212776  
    30063006    settings.setVisibleDebugOverlayRegions(store.getUInt32ValueForKey(WebPreferencesKey::visibleDebugOverlayRegionsKey()));
    30073007    settings.setUseGiantTiles(store.getBoolValueForKey(WebPreferencesKey::useGiantTilesKey()));
    3008    
     3008    settings.setSubpixelAntialiasedLayerTextEnabled(store.getBoolValueForKey(WebPreferencesKey::subpixelAntialiasedLayerTextEnabledKey()));
     3009
    30093010    settings.setAggressiveTileRetentionEnabled(store.getBoolValueForKey(WebPreferencesKey::aggressiveTileRetentionEnabledKey()));
    30103011    settings.setTemporaryTileCohortRetentionEnabled(store.getBoolValueForKey(WebPreferencesKey::temporaryTileCohortRetentionEnabledKey()));
  • trunk/Source/WebKit2/WebProcess/WebPage/mac/PlatformCALayerRemote.cpp

    r212590 r212776  
    608608}
    609609
     610bool PlatformCALayerRemote::supportsSubpixelAntialiasedText() const
     611{
     612    return false;
     613}
     614
     615void PlatformCALayerRemote::setSupportsSubpixelAntialiasedText(bool)
     616{
     617}
     618
    610619CFTypeRef PlatformCALayerRemote::contents() const
    611620{
  • trunk/Source/WebKit2/WebProcess/WebPage/mac/PlatformCALayerRemote.h

    r212590 r212776  
    119119    void setWantsDeepColorBackingStore(bool) override;
    120120
     121    bool supportsSubpixelAntialiasedText() const override;
     122    void setSupportsSubpixelAntialiasedText(bool) override;
     123
    121124    CFTypeRef contents() const override;
    122125    void setContents(CFTypeRef) override;
  • trunk/Source/WebKit2/WebProcess/WebPage/mac/PlatformCALayerRemoteTiledBacking.cpp

    r212590 r212776  
    9898}
    9999
     100bool PlatformCALayerRemoteTiledBacking::supportsSubpixelAntialiasedText() const
     101{
     102    return m_tileController->supportsSubpixelAntialiasedText();
     103}
     104
     105void PlatformCALayerRemoteTiledBacking::setSupportsSubpixelAntialiasedText(bool supportsSubpixelAntialiasedText)
     106{
     107    m_tileController->setSupportsSubpixelAntialiasedText(supportsSubpixelAntialiasedText);
     108}
     109
    100110float PlatformCALayerRemoteTiledBacking::contentsScale() const
    101111{
  • trunk/Source/WebKit2/WebProcess/WebPage/mac/PlatformCALayerRemoteTiledBacking.h

    r212590 r212776  
    5757    bool wantsDeepColorBackingStore() const override;
    5858    void setWantsDeepColorBackingStore(bool) override;
    59    
     59
     60    bool supportsSubpixelAntialiasedText() const override;
     61    void setSupportsSubpixelAntialiasedText(bool) override;
     62
    6063    float contentsScale() const override;
    6164    void setContentsScale(float) override;
  • trunk/Tools/ChangeLog

    r212757 r212776  
     12017-02-20  Simon Fraser  <simon.fraser@apple.com>
     2
     3        Add support to PlatformCALayer/GraphicsLayerCA for subpixel-antialiased text, with a Setting and a MiniBrowser switch
     4        https://bugs.webkit.org/show_bug.cgi?id=168620
     5        <rdar://problem/30617772>
     6
     7        Reviewed by Tim Horton.
     8       
     9        Add a setting that allows one to toggle subpixel-antialiased layer text on and off.
     10
     11        * DumpRenderTree/mac/DumpRenderTree.mm:
     12        (resetWebPreferencesToConsistentValues):
     13        * MiniBrowser/mac/SettingsController.h:
     14        * MiniBrowser/mac/SettingsController.m:
     15        (-[SettingsController _populateMenu]):
     16        (-[SettingsController validateMenuItem:]):
     17        (-[SettingsController toggleSubpixelAntialiasedLayerTextEnabled:]):
     18        (-[SettingsController subpixelAntialiasedLayerTextEnabled]):
     19        * MiniBrowser/mac/WK1BrowserWindowController.m:
     20        (-[WK1BrowserWindowController didChangeSettings]):
     21        * MiniBrowser/mac/WK2BrowserWindowController.m:
     22        (-[WK2BrowserWindowController didChangeSettings]):
     23        * WebKitTestRunner/TestController.cpp:
     24        (WTR::TestController::resetPreferencesToConsistentValues):
     25
    1262017-02-21  John Wilander  <wilander@apple.com>
    227
  • trunk/Tools/DumpRenderTree/mac/DumpRenderTree.mm

    r212513 r212776  
    972972    } else
    973973        [preferences setUserStyleSheetEnabled:NO];
     974
    974975    [preferences setMediaPlaybackAllowsInline:YES];
    975976    [preferences setVideoPlaybackRequiresUserGesture:NO];
     
    977978    [preferences setMediaDataLoadsAutomatically:YES];
    978979    [preferences setInvisibleAutoplayNotPermitted:NO];
     980    [preferences setSubpixelAntialiasedLayerTextEnabled:NO];
    979981
    980982#if PLATFORM(IOS)
  • trunk/Tools/MiniBrowser/mac/SettingsController.h

    r211135 r212776  
    5252@property (nonatomic, readonly) BOOL acceleratedDrawingEnabled;
    5353@property (nonatomic, readonly) BOOL displayListDrawingEnabled;
     54@property (nonatomic, readonly) BOOL subpixelAntialiasedLayerTextEnabled;
    5455@property (nonatomic, readonly) BOOL resourceLoadStatisticsEnabled;
    5556@property (nonatomic, readonly) BOOL visualViewportEnabled;
  • trunk/Tools/MiniBrowser/mac/SettingsController.m

    r211769 r212776  
    5151static NSString * const AcceleratedDrawingEnabledPreferenceKey = @"AcceleratedDrawingEnabled";
    5252static NSString * const DisplayListDrawingEnabledPreferenceKey = @"DisplayListDrawingEnabled";
     53static NSString * const SubpixelAntialiasedLayerTextEnabledPreferenceKey = @"SubpixelAntialiasedLayerTextEnabled";
    5354static NSString * const ResourceLoadStatisticsEnabledPreferenceKey = @"ResourceLoadStatisticsEnabled";
    5455
     
    135136    [self _addItemWithTitle:@"Enable Accelerated Drawing" action:@selector(toggleAcceleratedDrawingEnabled:) indented:NO];
    136137    [self _addItemWithTitle:@"Enable Display List Drawing" action:@selector(toggleDisplayListDrawingEnabled:) indented:NO];
     138    [self _addItemWithTitle:@"Enable Subpixel-antialiased Layer Text" action:@selector(toggleSubpixelAntialiasedLayerTextEnabled:) indented:NO];
    137139    [self _addItemWithTitle:@"Enable Visual Viewport" action:@selector(toggleVisualViewportEnabled:) indented:NO];
    138140    [self _addItemWithTitle:@"Enable Resource Load Statistics" action:@selector(toggleResourceLoadStatisticsEnabled:) indented:NO];
     
    219221    else if (action == @selector(toggleDisplayListDrawingEnabled:))
    220222        [menuItem setState:[self displayListDrawingEnabled] ? NSOnState : NSOffState];
     223    else if (action == @selector(toggleSubpixelAntialiasedLayerTextEnabled:))
     224        [menuItem setState:[self subpixelAntialiasedLayerTextEnabled] ? NSOnState : NSOffState];
    221225    else if (action == @selector(toggleResourceLoadStatisticsEnabled:))
    222226        [menuItem setState:[self resourceLoadStatisticsEnabled] ? NSOnState : NSOffState];
     
    399403}
    400404
     405- (void)toggleSubpixelAntialiasedLayerTextEnabled:(id)sender
     406{
     407    [self _toggleBooleanDefault:SubpixelAntialiasedLayerTextEnabledPreferenceKey];
     408}
     409
     410- (BOOL)subpixelAntialiasedLayerTextEnabled
     411{
     412    return [[NSUserDefaults standardUserDefaults] boolForKey:SubpixelAntialiasedLayerTextEnabledPreferenceKey];
     413}
     414
    401415- (void)toggleReserveSpaceForBanners:(id)sender
    402416{
  • trunk/Tools/MiniBrowser/mac/WK1BrowserWindowController.m

    r212195 r212776  
    270270    [[WebPreferences standardPreferences] setSuppressesIncrementalRendering:settings.incrementalRenderingSuppressed];
    271271    [[WebPreferences standardPreferences] setAcceleratedDrawingEnabled:settings.acceleratedDrawingEnabled];
     272    [[WebPreferences standardPreferences] setSubpixelAntialiasedLayerTextEnabled:settings.subpixelAntialiasedLayerTextEnabled];
    272273    [[WebPreferences standardPreferences] setResourceLoadStatisticsEnabled:settings.resourceLoadStatisticsEnabled];
    273274    [[WebPreferences standardPreferences] setVisualViewportEnabled:settings.visualViewportEnabled];
  • trunk/Tools/MiniBrowser/mac/WK2BrowserWindowController.m

    r211135 r212776  
    376376    preferences._resourceUsageOverlayVisible = settings.resourceUsageOverlayVisible;
    377377    preferences._displayListDrawingEnabled = settings.displayListDrawingEnabled;
     378    preferences._subpixelAntialiasedLayerTextEnabled = settings.subpixelAntialiasedLayerTextEnabled;
    378379    preferences._visualViewportEnabled = settings.visualViewportEnabled;
    379380    preferences._largeImageAsyncDecodingEnabled = settings.largeImageAsyncDecodingEnabled;
  • trunk/Tools/WebKitTestRunner/TestController.cpp

    r212757 r212776  
    643643    WKPreferencesSetOfflineWebApplicationCacheEnabled(preferences, true);
    644644    WKPreferencesSetFontSmoothingLevel(preferences, kWKFontSmoothingLevelNoSubpixelAntiAliasing);
     645    WKPreferencesSetSubpixelAntialiasedLayerTextEnabled(preferences, false);
    645646    WKPreferencesSetXSSAuditorEnabled(preferences, false);
    646647    WKPreferencesSetWebAudioEnabled(preferences, true);
Note: See TracChangeset for help on using the changeset viewer.