<!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>[191118] trunk/Source/WebCore</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/191118">191118</a></dd>
<dt>Author</dt> <dd>simon.fraser@apple.com</dd>
<dt>Date</dt> <dd>2015-10-15 10:23:32 -0700 (Thu, 15 Oct 2015)</dd>
</dl>

<h3>Log Message</h3>
<pre>Un-indent contents of the WebCore namespace
in GraphicsContext.h. No code changes.

* platform/graphics/GraphicsContext.h:</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCoreplatformgraphicsGraphicsContexth">trunk/Source/WebCore/platform/graphics/GraphicsContext.h</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (191117 => 191118)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog        2015-10-15 17:20:10 UTC (rev 191117)
+++ trunk/Source/WebCore/ChangeLog        2015-10-15 17:23:32 UTC (rev 191118)
</span><span class="lines">@@ -1,3 +1,10 @@
</span><ins>+2015-10-15  Simon Fraser  &lt;simon.fraser@apple.com&gt;
+
+        Un-indent contents of the WebCore namespace
+        in GraphicsContext.h. No code changes.
+
+        * platform/graphics/GraphicsContext.h:
+
</ins><span class="cx"> 2015-10-14  Simon Fraser  &lt;simon.fraser@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Move ImageBuffer:clip() into GraphicsContextCG
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformgraphicsGraphicsContexth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/graphics/GraphicsContext.h (191117 => 191118)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/graphics/GraphicsContext.h        2015-10-15 17:20:10 UTC (rev 191117)
+++ trunk/Source/WebCore/platform/graphics/GraphicsContext.h        2015-10-15 17:23:32 UTC (rev 191118)
</span><span class="lines">@@ -64,551 +64,550 @@
</span><span class="cx"> namespace WebCore {
</span><span class="cx"> 
</span><span class="cx"> #if USE(WINGDI)
</span><del>-    class SharedBitmap;
-    class Font;
-    class GlyphBuffer;
</del><ins>+class SharedBitmap;
+class Font;
+class GlyphBuffer;
</ins><span class="cx"> #endif
</span><span class="cx"> 
</span><del>-    const int cMisspellingLineThickness = 3;
-    const int cMisspellingLinePatternWidth = 4;
-    const int cMisspellingLinePatternGapWidth = 1;
</del><ins>+const int cMisspellingLineThickness = 3;
+const int cMisspellingLinePatternWidth = 4;
+const int cMisspellingLinePatternGapWidth = 1;
</ins><span class="cx"> 
</span><del>-    class AffineTransform;
-    class FloatRoundedRect;
-    class Gradient;
-    class GraphicsContextPlatformPrivate;
-    class ImageBuffer;
-    class IntRect;
-    class RoundedRect;
-    class URL;
-    class GraphicsContext3D;
-    class TextRun;
-    class TransformationMatrix;
</del><ins>+class AffineTransform;
+class FloatRoundedRect;
+class Gradient;
+class GraphicsContextPlatformPrivate;
+class ImageBuffer;
+class IntRect;
+class RoundedRect;
+class URL;
+class GraphicsContext3D;
+class TextRun;
+class TransformationMatrix;
</ins><span class="cx"> 
</span><del>-    enum TextDrawingMode {
-        TextModeFill = 1 &lt;&lt; 0,
-        TextModeStroke = 1 &lt;&lt; 1,
</del><ins>+enum TextDrawingMode {
+    TextModeFill = 1 &lt;&lt; 0,
+    TextModeStroke = 1 &lt;&lt; 1,
</ins><span class="cx"> #if ENABLE(LETTERPRESS)
</span><del>-        TextModeLetterpress = 1 &lt;&lt; 2,
</del><ins>+    TextModeLetterpress = 1 &lt;&lt; 2,
</ins><span class="cx"> #endif
</span><del>-    };
-    typedef unsigned TextDrawingModeFlags;
</del><ins>+};
+typedef unsigned TextDrawingModeFlags;
</ins><span class="cx"> 
</span><del>-    enum StrokeStyle {
-        NoStroke,
-        SolidStroke,
-        DottedStroke,
-        DashedStroke,
-        DoubleStroke,
-        WavyStroke,
-    };
</del><ins>+enum StrokeStyle {
+    NoStroke,
+    SolidStroke,
+    DottedStroke,
+    DashedStroke,
+    DoubleStroke,
+    WavyStroke,
+};
</ins><span class="cx"> 
</span><del>-    enum InterpolationQuality {
-        InterpolationDefault,
-        InterpolationNone,
-        InterpolationLow,
-        InterpolationMedium,
-        InterpolationHigh
-    };
</del><ins>+enum InterpolationQuality {
+    InterpolationDefault,
+    InterpolationNone,
+    InterpolationLow,
+    InterpolationMedium,
+    InterpolationHigh
+};
</ins><span class="cx"> 
</span><del>-    struct GraphicsContextState {
-        GraphicsContextState()
-            : shouldAntialias(true)
-            , shouldSmoothFonts(true)
-            , antialiasedFontDilationEnabled(true)
-            , shouldSubpixelQuantizeFonts(true)
-            , paintingDisabled(false)
-            , shadowsIgnoreTransforms(false)
</del><ins>+struct GraphicsContextState {
+    GraphicsContextState()
+        : shouldAntialias(true)
+        , shouldSmoothFonts(true)
+        , antialiasedFontDilationEnabled(true)
+        , shouldSubpixelQuantizeFonts(true)
+        , paintingDisabled(false)
+        , shadowsIgnoreTransforms(false)
</ins><span class="cx"> #if USE(CG)
</span><del>-            // Core Graphics incorrectly renders shadows with radius &gt; 8px (&lt;rdar://problem/8103442&gt;),
-            // but we need to preserve this buggy behavior for canvas and -webkit-box-shadow.
-            , shadowsUseLegacyRadius(false)
</del><ins>+        // Core Graphics incorrectly renders shadows with radius &gt; 8px (&lt;rdar://problem/8103442&gt;),
+        // but we need to preserve this buggy behavior for canvas and -webkit-box-shadow.
+        , shadowsUseLegacyRadius(false)
</ins><span class="cx"> #endif
</span><del>-            , drawLuminanceMask(false)
-        {
-        }
</del><ins>+        , drawLuminanceMask(false)
+    {
+    }
</ins><span class="cx"> 
</span><del>-        RefPtr&lt;Gradient&gt; strokeGradient;
-        RefPtr&lt;Pattern&gt; strokePattern;
-        
-        RefPtr&lt;Gradient&gt; fillGradient;
-        RefPtr&lt;Pattern&gt; fillPattern;
</del><ins>+    RefPtr&lt;Gradient&gt; strokeGradient;
+    RefPtr&lt;Pattern&gt; strokePattern;
+    
+    RefPtr&lt;Gradient&gt; fillGradient;
+    RefPtr&lt;Pattern&gt; fillPattern;
</ins><span class="cx"> 
</span><del>-        FloatSize shadowOffset;
</del><ins>+    FloatSize shadowOffset;
</ins><span class="cx"> 
</span><del>-        float strokeThickness { 0 };
-        float shadowBlur { 0 };
</del><ins>+    float strokeThickness { 0 };
+    float shadowBlur { 0 };
</ins><span class="cx"> 
</span><del>-        TextDrawingModeFlags textDrawingMode { TextModeFill };
</del><ins>+    TextDrawingModeFlags textDrawingMode { TextModeFill };
</ins><span class="cx"> 
</span><del>-        Color strokeColor { Color::black };
-        Color fillColor { Color::black };
-        Color shadowColor;
</del><ins>+    Color strokeColor { Color::black };
+    Color fillColor { Color::black };
+    Color shadowColor;
</ins><span class="cx"> 
</span><del>-        StrokeStyle strokeStyle { SolidStroke };
-        WindRule fillRule { RULE_NONZERO };
</del><ins>+    StrokeStyle strokeStyle { SolidStroke };
+    WindRule fillRule { RULE_NONZERO };
</ins><span class="cx"> 
</span><del>-        ColorSpace strokeColorSpace { ColorSpaceDeviceRGB };
-        ColorSpace fillColorSpace { ColorSpaceDeviceRGB };
-        ColorSpace shadowColorSpace { ColorSpaceDeviceRGB };
</del><ins>+    ColorSpace strokeColorSpace { ColorSpaceDeviceRGB };
+    ColorSpace fillColorSpace { ColorSpaceDeviceRGB };
+    ColorSpace shadowColorSpace { ColorSpaceDeviceRGB };
</ins><span class="cx"> 
</span><del>-        float alpha { 1 };
-        CompositeOperator compositeOperator { CompositeSourceOver };
-        BlendMode blendMode { BlendModeNormal };
</del><ins>+    float alpha { 1 };
+    CompositeOperator compositeOperator { CompositeSourceOver };
+    BlendMode blendMode { BlendModeNormal };
</ins><span class="cx"> 
</span><del>-        bool shouldAntialias : 1;
-        bool shouldSmoothFonts : 1;
-        bool antialiasedFontDilationEnabled : 1;
-        bool shouldSubpixelQuantizeFonts : 1;
-        bool paintingDisabled : 1;
-        bool shadowsIgnoreTransforms : 1;
</del><ins>+    bool shouldAntialias : 1;
+    bool shouldSmoothFonts : 1;
+    bool antialiasedFontDilationEnabled : 1;
+    bool shouldSubpixelQuantizeFonts : 1;
+    bool paintingDisabled : 1;
+    bool shadowsIgnoreTransforms : 1;
</ins><span class="cx"> #if USE(CG)
</span><del>-        bool shadowsUseLegacyRadius : 1;
</del><ins>+    bool shadowsUseLegacyRadius : 1;
</ins><span class="cx"> #endif
</span><del>-        bool drawLuminanceMask : 1;
-    };
</del><ins>+    bool drawLuminanceMask : 1;
+};
</ins><span class="cx"> 
</span><del>-    struct ImagePaintingOptions {
-        ImagePaintingOptions(CompositeOperator compositeOperator = CompositeSourceOver, BlendMode blendMode = BlendModeNormal, ImageOrientationDescription orientationDescription = ImageOrientationDescription(), bool useLowQualityScale = false)
-            : m_compositeOperator(compositeOperator)
-            , m_blendMode(blendMode)
-            , m_orientationDescription(orientationDescription)
-            , m_useLowQualityScale(useLowQualityScale)
-        {
-        }
</del><ins>+struct ImagePaintingOptions {
+    ImagePaintingOptions(CompositeOperator compositeOperator = CompositeSourceOver, BlendMode blendMode = BlendModeNormal, ImageOrientationDescription orientationDescription = ImageOrientationDescription(), bool useLowQualityScale = false)
+        : m_compositeOperator(compositeOperator)
+        , m_blendMode(blendMode)
+        , m_orientationDescription(orientationDescription)
+        , m_useLowQualityScale(useLowQualityScale)
+    {
+    }
</ins><span class="cx"> 
</span><del>-        ImagePaintingOptions(ImageOrientationDescription orientationDescription, bool useLowQualityScale = false, CompositeOperator compositeOperator = CompositeSourceOver, BlendMode blendMode = BlendModeNormal)
-            : m_compositeOperator(compositeOperator)
-            , m_blendMode(blendMode)
-            , m_orientationDescription(orientationDescription)
-            , m_useLowQualityScale(useLowQualityScale)
-        {
-        }
</del><ins>+    ImagePaintingOptions(ImageOrientationDescription orientationDescription, bool useLowQualityScale = false, CompositeOperator compositeOperator = CompositeSourceOver, BlendMode blendMode = BlendModeNormal)
+        : m_compositeOperator(compositeOperator)
+        , m_blendMode(blendMode)
+        , m_orientationDescription(orientationDescription)
+        , m_useLowQualityScale(useLowQualityScale)
+    {
+    }
</ins><span class="cx"> 
</span><del>-        ImagePaintingOptions(bool useLowQualityScale, ImageOrientationDescription orientationDescription = ImageOrientationDescription(), CompositeOperator compositeOperator = CompositeSourceOver, BlendMode blendMode = BlendModeNormal)
-            : m_compositeOperator(compositeOperator)
-            , m_blendMode(blendMode)
-            , m_orientationDescription(orientationDescription)
-            , m_useLowQualityScale(useLowQualityScale)
-        {
-        }
</del><ins>+    ImagePaintingOptions(bool useLowQualityScale, ImageOrientationDescription orientationDescription = ImageOrientationDescription(), CompositeOperator compositeOperator = CompositeSourceOver, BlendMode blendMode = BlendModeNormal)
+        : m_compositeOperator(compositeOperator)
+        , m_blendMode(blendMode)
+        , m_orientationDescription(orientationDescription)
+        , m_useLowQualityScale(useLowQualityScale)
+    {
+    }
</ins><span class="cx"> 
</span><del>-        CompositeOperator m_compositeOperator;
-        BlendMode m_blendMode;
-        ImageOrientationDescription m_orientationDescription;
-        bool m_useLowQualityScale;
-    };
</del><ins>+    CompositeOperator m_compositeOperator;
+    BlendMode m_blendMode;
+    ImageOrientationDescription m_orientationDescription;
+    bool m_useLowQualityScale;
+};
</ins><span class="cx"> 
</span><del>-    class GraphicsContext {
-        WTF_MAKE_NONCOPYABLE(GraphicsContext); WTF_MAKE_FAST_ALLOCATED;
-    public:
-        WEBCORE_EXPORT GraphicsContext(PlatformGraphicsContext*);
-        WEBCORE_EXPORT ~GraphicsContext();
</del><ins>+class GraphicsContext {
+    WTF_MAKE_NONCOPYABLE(GraphicsContext); WTF_MAKE_FAST_ALLOCATED;
+public:
+    WEBCORE_EXPORT GraphicsContext(PlatformGraphicsContext*);
+    WEBCORE_EXPORT ~GraphicsContext();
</ins><span class="cx"> 
</span><del>-        WEBCORE_EXPORT PlatformGraphicsContext* platformContext() const;
</del><ins>+    WEBCORE_EXPORT PlatformGraphicsContext* platformContext() const;
</ins><span class="cx"> 
</span><del>-        void setStrokeThickness(float);
-        float strokeThickness() const { return m_state.strokeThickness; }
</del><ins>+    void setStrokeThickness(float);
+    float strokeThickness() const { return m_state.strokeThickness; }
</ins><span class="cx"> 
</span><del>-        void setStrokeStyle(StrokeStyle);
-        StrokeStyle strokeStyle() const { return m_state.strokeStyle; }
</del><ins>+    void setStrokeStyle(StrokeStyle);
+    StrokeStyle strokeStyle() const { return m_state.strokeStyle; }
</ins><span class="cx"> 
</span><del>-        WEBCORE_EXPORT void setStrokeColor(const Color&amp;, ColorSpace);
-        Color strokeColor() const { return m_state.strokeColor; }
-        ColorSpace strokeColorSpace() const { return m_state.strokeColorSpace; }
</del><ins>+    WEBCORE_EXPORT void setStrokeColor(const Color&amp;, ColorSpace);
+    Color strokeColor() const { return m_state.strokeColor; }
+    ColorSpace strokeColorSpace() const { return m_state.strokeColorSpace; }
</ins><span class="cx"> 
</span><del>-        void setStrokePattern(Ref&lt;Pattern&gt;&amp;&amp;);
-        Pattern* strokePattern() const { return m_state.strokePattern.get(); }
</del><ins>+    void setStrokePattern(Ref&lt;Pattern&gt;&amp;&amp;);
+    Pattern* strokePattern() const { return m_state.strokePattern.get(); }
</ins><span class="cx"> 
</span><del>-        void setStrokeGradient(Ref&lt;Gradient&gt;&amp;&amp;);
-        Gradient* strokeGradient() const { return m_state.strokeGradient.get(); }
</del><ins>+    void setStrokeGradient(Ref&lt;Gradient&gt;&amp;&amp;);
+    Gradient* strokeGradient() const { return m_state.strokeGradient.get(); }
</ins><span class="cx"> 
</span><del>-        void setFillRule(WindRule fillRule) { m_state.fillRule = fillRule; }
-        WindRule fillRule() const { return m_state.fillRule; }
-    
-        WEBCORE_EXPORT void setFillColor(const Color&amp;, ColorSpace);
-        Color fillColor() const { return m_state.fillColor; }
-        ColorSpace fillColorSpace() const { return m_state.fillColorSpace; }
</del><ins>+    void setFillRule(WindRule fillRule) { m_state.fillRule = fillRule; }
+    WindRule fillRule() const { return m_state.fillRule; }
</ins><span class="cx"> 
</span><del>-        void setFillPattern(Ref&lt;Pattern&gt;&amp;&amp;);
-        Pattern* fillPattern() const { return m_state.fillPattern.get(); }
</del><ins>+    WEBCORE_EXPORT void setFillColor(const Color&amp;, ColorSpace);
+    Color fillColor() const { return m_state.fillColor; }
+    ColorSpace fillColorSpace() const { return m_state.fillColorSpace; }
</ins><span class="cx"> 
</span><del>-        WEBCORE_EXPORT void setFillGradient(Ref&lt;Gradient&gt;&amp;&amp;);
-        Gradient* fillGradient() const { return m_state.fillGradient.get(); }
</del><ins>+    void setFillPattern(Ref&lt;Pattern&gt;&amp;&amp;);
+    Pattern* fillPattern() const { return m_state.fillPattern.get(); }
</ins><span class="cx"> 
</span><del>-        void setShadowsIgnoreTransforms(bool shadowsIgnoreTransforms) { m_state.shadowsIgnoreTransforms = shadowsIgnoreTransforms; }
-        bool shadowsIgnoreTransforms() const { return m_state.shadowsIgnoreTransforms; }
</del><ins>+    WEBCORE_EXPORT void setFillGradient(Ref&lt;Gradient&gt;&amp;&amp;);
+    Gradient* fillGradient() const { return m_state.fillGradient.get(); }
</ins><span class="cx"> 
</span><del>-        WEBCORE_EXPORT void setShouldAntialias(bool);
-        bool shouldAntialias() const { return m_state.shouldAntialias; }
</del><ins>+    void setShadowsIgnoreTransforms(bool shadowsIgnoreTransforms) { m_state.shadowsIgnoreTransforms = shadowsIgnoreTransforms; }
+    bool shadowsIgnoreTransforms() const { return m_state.shadowsIgnoreTransforms; }
</ins><span class="cx"> 
</span><del>-        WEBCORE_EXPORT void setAntialiasedFontDilationEnabled(bool);
-        bool antialiasedFontDilationEnabled() const { return m_state.antialiasedFontDilationEnabled; }
</del><ins>+    WEBCORE_EXPORT void setShouldAntialias(bool);
+    bool shouldAntialias() const { return m_state.shouldAntialias; }
</ins><span class="cx"> 
</span><del>-        WEBCORE_EXPORT void setShouldSmoothFonts(bool);
-        bool shouldSmoothFonts() const { return m_state.shouldSmoothFonts; }
</del><ins>+    WEBCORE_EXPORT void setAntialiasedFontDilationEnabled(bool);
+    bool antialiasedFontDilationEnabled() const { return m_state.antialiasedFontDilationEnabled; }
</ins><span class="cx"> 
</span><del>-        // Normally CG enables subpixel-quantization because it improves the performance of aligning glyphs.
-        // In some cases we have to disable to to ensure a high-quality output of the glyphs.
-        void setShouldSubpixelQuantizeFonts(bool shouldSubpixelQuantizeFonts) { m_state.shouldSubpixelQuantizeFonts = shouldSubpixelQuantizeFonts; }
-        bool shouldSubpixelQuantizeFonts() const { return m_state.shouldSubpixelQuantizeFonts; }
</del><ins>+    WEBCORE_EXPORT void setShouldSmoothFonts(bool);
+    bool shouldSmoothFonts() const { return m_state.shouldSmoothFonts; }
</ins><span class="cx"> 
</span><del>-        const GraphicsContextState&amp; state() const { return m_state; }
</del><ins>+    // Normally CG enables subpixel-quantization because it improves the performance of aligning glyphs.
+    // In some cases we have to disable to to ensure a high-quality output of the glyphs.
+    void setShouldSubpixelQuantizeFonts(bool shouldSubpixelQuantizeFonts) { m_state.shouldSubpixelQuantizeFonts = shouldSubpixelQuantizeFonts; }
+    bool shouldSubpixelQuantizeFonts() const { return m_state.shouldSubpixelQuantizeFonts; }
</ins><span class="cx"> 
</span><ins>+    const GraphicsContextState&amp; state() const { return m_state; }
+
</ins><span class="cx"> #if USE(CG)
</span><del>-        void applyStrokePattern();
-        void applyFillPattern();
-        void drawPath(const Path&amp;);
</del><ins>+    void applyStrokePattern();
+    void applyFillPattern();
+    void drawPath(const Path&amp;);
</ins><span class="cx"> 
</span><del>-        WEBCORE_EXPORT void drawNativeImage(PassNativeImagePtr, const FloatSize&amp; selfSize, ColorSpace styleColorSpace, const FloatRect&amp; destRect, const FloatRect&amp; srcRect, CompositeOperator = CompositeSourceOver, BlendMode = BlendModeNormal, ImageOrientation = DefaultImageOrientation);
</del><ins>+    WEBCORE_EXPORT void drawNativeImage(PassNativeImagePtr, const FloatSize&amp; selfSize, ColorSpace styleColorSpace, const FloatRect&amp; destRect, const FloatRect&amp; srcRect, CompositeOperator = CompositeSourceOver, BlendMode = BlendModeNormal, ImageOrientation = DefaultImageOrientation);
</ins><span class="cx"> 
</span><del>-        void clipToNativeImage(PassNativeImagePtr, const FloatRect&amp; destRect, const FloatSize&amp; bufferSize);
</del><ins>+    void clipToNativeImage(PassNativeImagePtr, const FloatRect&amp; destRect, const FloatSize&amp; bufferSize);
</ins><span class="cx"> 
</span><del>-        // Allow font smoothing (LCD antialiasing). Not part of the graphics state.
-        void setAllowsFontSmoothing(bool);
-        
-        WEBCORE_EXPORT void setIsCALayerContext(bool);
-        bool isCALayerContext() const;
</del><ins>+    // Allow font smoothing (LCD antialiasing). Not part of the graphics state.
+    void setAllowsFontSmoothing(bool);
+    
+    WEBCORE_EXPORT void setIsCALayerContext(bool);
+    bool isCALayerContext() const;
</ins><span class="cx"> 
</span><del>-        WEBCORE_EXPORT void setIsAcceleratedContext(bool);
</del><ins>+    WEBCORE_EXPORT void setIsAcceleratedContext(bool);
</ins><span class="cx"> #endif
</span><del>-        bool isAcceleratedContext() const;
-        RenderingMode renderingMode() const { return isAcceleratedContext() ? Accelerated : Unaccelerated; }
</del><ins>+    bool isAcceleratedContext() const;
+    RenderingMode renderingMode() const { return isAcceleratedContext() ? Accelerated : Unaccelerated; }
</ins><span class="cx"> 
</span><del>-        WEBCORE_EXPORT void save();
-        WEBCORE_EXPORT void restore();
</del><ins>+    WEBCORE_EXPORT void save();
+    WEBCORE_EXPORT void restore();
</ins><span class="cx"> 
</span><del>-        // These draw methods will do both stroking and filling.
-        // FIXME: ...except drawRect(), which fills properly but always strokes
-        // using a 1-pixel stroke inset from the rect borders (of the correct
-        // stroke color).
-        void drawRect(const FloatRect&amp;, float borderThickness = 1);
-        void drawLine(const FloatPoint&amp;, const FloatPoint&amp;);
</del><ins>+    // These draw methods will do both stroking and filling.
+    // FIXME: ...except drawRect(), which fills properly but always strokes
+    // using a 1-pixel stroke inset from the rect borders (of the correct
+    // stroke color).
+    void drawRect(const FloatRect&amp;, float borderThickness = 1);
+    void drawLine(const FloatPoint&amp;, const FloatPoint&amp;);
</ins><span class="cx"> 
</span><span class="cx"> #if PLATFORM(IOS)
</span><del>-        void drawJoinedLines(CGPoint points[], unsigned count, bool antialias, CGLineCap = kCGLineCapButt);
</del><ins>+    void drawJoinedLines(CGPoint points[], unsigned count, bool antialias, CGLineCap = kCGLineCapButt);
</ins><span class="cx"> #endif
</span><span class="cx"> 
</span><del>-        void drawEllipse(const FloatRect&amp;);
-        void drawRaisedEllipse(const FloatRect&amp;, const Color&amp; ellipseColor, ColorSpace ellipseColorSpace, const Color&amp; shadowColor, ColorSpace shadowColorSpace);
-        void drawConvexPolygon(size_t numPoints, const FloatPoint*, bool shouldAntialias = false);
</del><ins>+    void drawEllipse(const FloatRect&amp;);
+    void drawRaisedEllipse(const FloatRect&amp;, const Color&amp; ellipseColor, ColorSpace ellipseColorSpace, const Color&amp; shadowColor, ColorSpace shadowColorSpace);
+    void drawConvexPolygon(size_t numPoints, const FloatPoint*, bool shouldAntialias = false);
</ins><span class="cx"> 
</span><del>-        WEBCORE_EXPORT void fillPath(const Path&amp;);
-        void strokePath(const Path&amp;);
</del><ins>+    WEBCORE_EXPORT void fillPath(const Path&amp;);
+    void strokePath(const Path&amp;);
</ins><span class="cx"> 
</span><del>-        void fillEllipse(const FloatRect&amp;);
-        void strokeEllipse(const FloatRect&amp;);
</del><ins>+    void fillEllipse(const FloatRect&amp;);
+    void strokeEllipse(const FloatRect&amp;);
</ins><span class="cx"> 
</span><del>-        WEBCORE_EXPORT void fillRect(const FloatRect&amp;);
-        WEBCORE_EXPORT void fillRect(const FloatRect&amp;, const Color&amp;, ColorSpace);
-        void fillRect(const FloatRect&amp;, Gradient&amp;);
-        void fillRect(const FloatRect&amp;, const Color&amp;, ColorSpace, CompositeOperator, BlendMode = BlendModeNormal);
-        void fillRoundedRect(const FloatRoundedRect&amp;, const Color&amp;, ColorSpace, BlendMode = BlendModeNormal);
-        void fillRectWithRoundedHole(const FloatRect&amp;, const FloatRoundedRect&amp; roundedHoleRect, const Color&amp;, ColorSpace);
</del><ins>+    WEBCORE_EXPORT void fillRect(const FloatRect&amp;);
+    WEBCORE_EXPORT void fillRect(const FloatRect&amp;, const Color&amp;, ColorSpace);
+    void fillRect(const FloatRect&amp;, Gradient&amp;);
+    void fillRect(const FloatRect&amp;, const Color&amp;, ColorSpace, CompositeOperator, BlendMode = BlendModeNormal);
+    void fillRoundedRect(const FloatRoundedRect&amp;, const Color&amp;, ColorSpace, BlendMode = BlendModeNormal);
+    void fillRectWithRoundedHole(const FloatRect&amp;, const FloatRoundedRect&amp; roundedHoleRect, const Color&amp;, ColorSpace);
</ins><span class="cx"> 
</span><del>-        WEBCORE_EXPORT void clearRect(const FloatRect&amp;);
</del><ins>+    WEBCORE_EXPORT void clearRect(const FloatRect&amp;);
</ins><span class="cx"> 
</span><del>-        WEBCORE_EXPORT void strokeRect(const FloatRect&amp;, float lineWidth);
</del><ins>+    WEBCORE_EXPORT void strokeRect(const FloatRect&amp;, float lineWidth);
</ins><span class="cx"> 
</span><del>-        WEBCORE_EXPORT void drawImage(Image&amp;, ColorSpace, const FloatPoint&amp; destination, const ImagePaintingOptions&amp; = ImagePaintingOptions());
-        WEBCORE_EXPORT void drawImage(Image&amp;, ColorSpace, const FloatRect&amp; destination, const ImagePaintingOptions&amp; = ImagePaintingOptions());
-        void drawImage(Image&amp;, ColorSpace, const FloatRect&amp; destination, const FloatRect&amp; source, const ImagePaintingOptions&amp; = ImagePaintingOptions());
</del><ins>+    WEBCORE_EXPORT void drawImage(Image&amp;, ColorSpace, const FloatPoint&amp; destination, const ImagePaintingOptions&amp; = ImagePaintingOptions());
+    WEBCORE_EXPORT void drawImage(Image&amp;, ColorSpace, const FloatRect&amp; destination, const ImagePaintingOptions&amp; = ImagePaintingOptions());
+    void drawImage(Image&amp;, ColorSpace, const FloatRect&amp; destination, const FloatRect&amp; source, const ImagePaintingOptions&amp; = ImagePaintingOptions());
</ins><span class="cx"> 
</span><del>-        void drawTiledImage(Image&amp;, ColorSpace, const FloatRect&amp; destination, const FloatPoint&amp; source, const FloatSize&amp; tileSize, const FloatSize&amp; spacing, const ImagePaintingOptions&amp; = ImagePaintingOptions());
-        void drawTiledImage(Image&amp;, ColorSpace, const FloatRect&amp; destination, const FloatRect&amp; source, const FloatSize&amp; tileScaleFactor,
-            Image::TileRule, Image::TileRule, const ImagePaintingOptions&amp; = ImagePaintingOptions());
</del><ins>+    void drawTiledImage(Image&amp;, ColorSpace, const FloatRect&amp; destination, const FloatPoint&amp; source, const FloatSize&amp; tileSize, const FloatSize&amp; spacing, const ImagePaintingOptions&amp; = ImagePaintingOptions());
+    void drawTiledImage(Image&amp;, ColorSpace, const FloatRect&amp; destination, const FloatRect&amp; source, const FloatSize&amp; tileScaleFactor,
+        Image::TileRule, Image::TileRule, const ImagePaintingOptions&amp; = ImagePaintingOptions());
</ins><span class="cx"> 
</span><del>-        WEBCORE_EXPORT void drawImageBuffer(ImageBuffer&amp;, ColorSpace, const FloatPoint&amp; destination, const ImagePaintingOptions&amp; = ImagePaintingOptions());
-        void drawImageBuffer(ImageBuffer&amp;, ColorSpace, const FloatRect&amp; destination, const ImagePaintingOptions&amp; = ImagePaintingOptions());
-        void drawImageBuffer(ImageBuffer&amp;, ColorSpace, const FloatRect&amp; destination, const FloatRect&amp; source, const ImagePaintingOptions&amp; = ImagePaintingOptions());
</del><ins>+    WEBCORE_EXPORT void drawImageBuffer(ImageBuffer&amp;, ColorSpace, const FloatPoint&amp; destination, const ImagePaintingOptions&amp; = ImagePaintingOptions());
+    void drawImageBuffer(ImageBuffer&amp;, ColorSpace, const FloatRect&amp; destination, const ImagePaintingOptions&amp; = ImagePaintingOptions());
+    void drawImageBuffer(ImageBuffer&amp;, ColorSpace, const FloatRect&amp; destination, const FloatRect&amp; source, const ImagePaintingOptions&amp; = ImagePaintingOptions());
</ins><span class="cx"> 
</span><del>-        void drawPattern(Image&amp;, const FloatRect&amp; srcRect, const AffineTransform&amp;, const FloatPoint&amp; phase, const FloatSize&amp; spacing, ColorSpace, CompositeOperator, const FloatRect&amp; destRect, BlendMode = BlendModeNormal);
</del><ins>+    void drawPattern(Image&amp;, const FloatRect&amp; srcRect, const AffineTransform&amp;, const FloatPoint&amp; phase, const FloatSize&amp; spacing, ColorSpace, CompositeOperator, const FloatRect&amp; destRect, BlendMode = BlendModeNormal);
</ins><span class="cx"> 
</span><del>-        WEBCORE_EXPORT void setImageInterpolationQuality(InterpolationQuality);
-        InterpolationQuality imageInterpolationQuality() const;
</del><ins>+    WEBCORE_EXPORT void setImageInterpolationQuality(InterpolationQuality);
+    InterpolationQuality imageInterpolationQuality() const;
</ins><span class="cx"> 
</span><del>-        WEBCORE_EXPORT void clip(const IntRect&amp;);
-        WEBCORE_EXPORT void clip(const FloatRect&amp;);
-        void clipRoundedRect(const FloatRoundedRect&amp;);
</del><ins>+    WEBCORE_EXPORT void clip(const IntRect&amp;);
+    WEBCORE_EXPORT void clip(const FloatRect&amp;);
+    void clipRoundedRect(const FloatRoundedRect&amp;);
</ins><span class="cx"> 
</span><del>-        void clipOut(const FloatRect&amp;);
-        void clipOutRoundedRect(const FloatRoundedRect&amp;);
-        void clipPath(const Path&amp;, WindRule);
-        void clipConvexPolygon(size_t numPoints, const FloatPoint*, bool antialias = true);
-        void clipToImageBuffer(ImageBuffer&amp;, const FloatRect&amp;);
-        
-        IntRect clipBounds() const;
</del><ins>+    void clipOut(const FloatRect&amp;);
+    void clipOutRoundedRect(const FloatRoundedRect&amp;);
+    void clipPath(const Path&amp;, WindRule);
+    void clipConvexPolygon(size_t numPoints, const FloatPoint*, bool antialias = true);
+    void clipToImageBuffer(ImageBuffer&amp;, const FloatRect&amp;);
+    
+    IntRect clipBounds() const;
</ins><span class="cx"> 
</span><del>-        void setTextDrawingMode(TextDrawingModeFlags);
-        TextDrawingModeFlags textDrawingMode() const { return m_state.textDrawingMode; }
</del><ins>+    void setTextDrawingMode(TextDrawingModeFlags);
+    TextDrawingModeFlags textDrawingMode() const { return m_state.textDrawingMode; }
</ins><span class="cx"> 
</span><del>-        float drawText(const FontCascade&amp;, const TextRun&amp;, const FloatPoint&amp;, int from = 0, int to = -1);
-        void drawGlyphs(const FontCascade&amp;, const Font&amp;, const GlyphBuffer&amp;, int from, int numGlyphs, const FloatPoint&amp;);
-        void drawEmphasisMarks(const FontCascade&amp;, const TextRun&amp; , const AtomicString&amp; mark, const FloatPoint&amp;, int from = 0, int to = -1);
-        void drawBidiText(const FontCascade&amp;, const TextRun&amp;, const FloatPoint&amp;, FontCascade::CustomFontNotReadyAction = FontCascade::DoNotPaintIfFontNotReady);
</del><ins>+    float drawText(const FontCascade&amp;, const TextRun&amp;, const FloatPoint&amp;, int from = 0, int to = -1);
+    void drawGlyphs(const FontCascade&amp;, const Font&amp;, const GlyphBuffer&amp;, int from, int numGlyphs, const FloatPoint&amp;);
+    void drawEmphasisMarks(const FontCascade&amp;, const TextRun&amp; , const AtomicString&amp; mark, const FloatPoint&amp;, int from = 0, int to = -1);
+    void drawBidiText(const FontCascade&amp;, const TextRun&amp;, const FloatPoint&amp;, FontCascade::CustomFontNotReadyAction = FontCascade::DoNotPaintIfFontNotReady);
</ins><span class="cx"> 
</span><del>-        enum RoundingMode {
-            RoundAllSides,
-            RoundOriginAndDimensions
-        };
-        FloatRect roundToDevicePixels(const FloatRect&amp;, RoundingMode = RoundAllSides);
</del><ins>+    enum RoundingMode {
+        RoundAllSides,
+        RoundOriginAndDimensions
+    };
+    FloatRect roundToDevicePixels(const FloatRect&amp;, RoundingMode = RoundAllSides);
</ins><span class="cx"> 
</span><del>-        FloatRect computeLineBoundsForText(const FloatPoint&amp;, float width, bool printing);
-        WEBCORE_EXPORT void drawLineForText(const FloatPoint&amp;, float width, bool printing, bool doubleLines = false);
-        void drawLinesForText(const FloatPoint&amp;, const DashArray&amp; widths, bool printing, bool doubleLines = false);
-        enum DocumentMarkerLineStyle {
</del><ins>+    FloatRect computeLineBoundsForText(const FloatPoint&amp;, float width, bool printing);
+    WEBCORE_EXPORT void drawLineForText(const FloatPoint&amp;, float width, bool printing, bool doubleLines = false);
+    void drawLinesForText(const FloatPoint&amp;, const DashArray&amp; widths, bool printing, bool doubleLines = false);
+    enum DocumentMarkerLineStyle {
</ins><span class="cx"> #if PLATFORM(IOS)
</span><del>-            TextCheckingDictationPhraseWithAlternativesLineStyle,
</del><ins>+        TextCheckingDictationPhraseWithAlternativesLineStyle,
</ins><span class="cx"> #endif
</span><del>-            DocumentMarkerSpellingLineStyle,
-            DocumentMarkerGrammarLineStyle,
-            DocumentMarkerAutocorrectionReplacementLineStyle,
-            DocumentMarkerDictationAlternativesLineStyle
-        };
-        static void updateDocumentMarkerResources();
-        void drawLineForDocumentMarker(const FloatPoint&amp;, float width, DocumentMarkerLineStyle);
</del><ins>+        DocumentMarkerSpellingLineStyle,
+        DocumentMarkerGrammarLineStyle,
+        DocumentMarkerAutocorrectionReplacementLineStyle,
+        DocumentMarkerDictationAlternativesLineStyle
+    };
+    static void updateDocumentMarkerResources();
+    void drawLineForDocumentMarker(const FloatPoint&amp;, float width, DocumentMarkerLineStyle);
</ins><span class="cx"> 
</span><del>-        void setPaintingDisabled(bool paintingDisabled) { m_state.paintingDisabled = paintingDisabled; }
-        bool paintingDisabled() const { return m_state.paintingDisabled; }
</del><ins>+    void setPaintingDisabled(bool paintingDisabled) { m_state.paintingDisabled = paintingDisabled; }
+    bool paintingDisabled() const { return m_state.paintingDisabled; }
</ins><span class="cx"> 
</span><del>-        void setUpdatingControlTints(bool);
-        bool updatingControlTints() const { return m_updatingControlTints; }
</del><ins>+    void setUpdatingControlTints(bool);
+    bool updatingControlTints() const { return m_updatingControlTints; }
</ins><span class="cx"> 
</span><del>-        WEBCORE_EXPORT void beginTransparencyLayer(float opacity);
-        WEBCORE_EXPORT void endTransparencyLayer();
-        bool isInTransparencyLayer() const { return (m_transparencyCount &gt; 0) &amp;&amp; supportsTransparencyLayers(); }
</del><ins>+    WEBCORE_EXPORT void beginTransparencyLayer(float opacity);
+    WEBCORE_EXPORT void endTransparencyLayer();
+    bool isInTransparencyLayer() const { return (m_transparencyCount &gt; 0) &amp;&amp; supportsTransparencyLayers(); }
</ins><span class="cx"> 
</span><del>-        WEBCORE_EXPORT void setShadow(const FloatSize&amp;, float blur, const Color&amp;, ColorSpace);
-        // Legacy shadow blur radius is used for canvas, and -webkit-box-shadow.
-        // It has different treatment of radii &gt; 8px.
-        void setLegacyShadow(const FloatSize&amp;, float blur, const Color&amp;, ColorSpace);
</del><ins>+    WEBCORE_EXPORT void setShadow(const FloatSize&amp;, float blur, const Color&amp;, ColorSpace);
+    // Legacy shadow blur radius is used for canvas, and -webkit-box-shadow.
+    // It has different treatment of radii &gt; 8px.
+    void setLegacyShadow(const FloatSize&amp;, float blur, const Color&amp;, ColorSpace);
</ins><span class="cx"> 
</span><del>-        WEBCORE_EXPORT void clearShadow();
-        bool getShadow(FloatSize&amp;, float&amp;, Color&amp;, ColorSpace&amp;) const;
</del><ins>+    WEBCORE_EXPORT void clearShadow();
+    bool getShadow(FloatSize&amp;, float&amp;, Color&amp;, ColorSpace&amp;) const;
</ins><span class="cx"> 
</span><del>-        bool hasVisibleShadow() const { return m_state.shadowColor.isValid() &amp;&amp; m_state.shadowColor.alpha(); }
-        bool hasShadow() const { return hasVisibleShadow() &amp;&amp; (m_state.shadowBlur || m_state.shadowOffset.width() || m_state.shadowOffset.height()); }
-        bool hasBlurredShadow() const { return hasVisibleShadow() &amp;&amp; m_state.shadowBlur; }
</del><ins>+    bool hasVisibleShadow() const { return m_state.shadowColor.isValid() &amp;&amp; m_state.shadowColor.alpha(); }
+    bool hasShadow() const { return hasVisibleShadow() &amp;&amp; (m_state.shadowBlur || m_state.shadowOffset.width() || m_state.shadowOffset.height()); }
+    bool hasBlurredShadow() const { return hasVisibleShadow() &amp;&amp; m_state.shadowBlur; }
</ins><span class="cx"> 
</span><span class="cx"> #if USE(CAIRO)
</span><del>-        bool mustUseShadowBlur() const;
</del><ins>+    bool mustUseShadowBlur() const;
</ins><span class="cx"> #endif
</span><span class="cx"> 
</span><del>-        void drawFocusRing(const Vector&lt;IntRect&gt;&amp;, int width, int offset, const Color&amp;);
-        void drawFocusRing(const Path&amp;, int width, int offset, const Color&amp;);
</del><ins>+    void drawFocusRing(const Vector&lt;IntRect&gt;&amp;, int width, int offset, const Color&amp;);
+    void drawFocusRing(const Path&amp;, int width, int offset, const Color&amp;);
</ins><span class="cx"> #if PLATFORM(MAC)
</span><del>-        void drawFocusRing(const Vector&lt;IntRect&gt;&amp;, int width, int offset, double timeOffset, bool&amp; needsRedraw);
</del><ins>+    void drawFocusRing(const Vector&lt;IntRect&gt;&amp;, int width, int offset, double timeOffset, bool&amp; needsRedraw);
</ins><span class="cx"> #endif
</span><span class="cx"> 
</span><del>-        void setLineCap(LineCap);
-        void setLineDash(const DashArray&amp;, float dashOffset);
-        void setLineJoin(LineJoin);
-        void setMiterLimit(float);
</del><ins>+    void setLineCap(LineCap);
+    void setLineDash(const DashArray&amp;, float dashOffset);
+    void setLineJoin(LineJoin);
+    void setMiterLimit(float);
</ins><span class="cx"> 
</span><del>-        void setAlpha(float);
-        float alpha() const { return m_state.alpha; }
</del><ins>+    void setAlpha(float);
+    float alpha() const { return m_state.alpha; }
</ins><span class="cx"> 
</span><del>-        WEBCORE_EXPORT void setCompositeOperation(CompositeOperator, BlendMode = BlendModeNormal);
-        CompositeOperator compositeOperation() const { return m_state.compositeOperator; }
-        BlendMode blendModeOperation() const { return m_state.blendMode; }
</del><ins>+    WEBCORE_EXPORT void setCompositeOperation(CompositeOperator, BlendMode = BlendModeNormal);
+    CompositeOperator compositeOperation() const { return m_state.compositeOperator; }
+    BlendMode blendModeOperation() const { return m_state.blendMode; }
</ins><span class="cx"> 
</span><del>-        void setDrawLuminanceMask(bool drawLuminanceMask) { m_state.drawLuminanceMask = drawLuminanceMask; }
-        bool drawLuminanceMask() const { return m_state.drawLuminanceMask; }
</del><ins>+    void setDrawLuminanceMask(bool drawLuminanceMask) { m_state.drawLuminanceMask = drawLuminanceMask; }
+    bool drawLuminanceMask() const { return m_state.drawLuminanceMask; }
</ins><span class="cx"> 
</span><del>-        WEBCORE_EXPORT void clip(const Path&amp;, WindRule = RULE_EVENODD);
</del><ins>+    WEBCORE_EXPORT void clip(const Path&amp;, WindRule = RULE_EVENODD);
</ins><span class="cx"> 
</span><del>-        // This clip function is used only by &lt;canvas&gt; code. It allows
-        // implementations to handle clipping on the canvas differently since
-        // the discipline is different.
-        void canvasClip(const Path&amp;, WindRule = RULE_EVENODD);
-        void clipOut(const Path&amp;);
</del><ins>+    // This clip function is used only by &lt;canvas&gt; code. It allows
+    // implementations to handle clipping on the canvas differently since
+    // the discipline is different.
+    void canvasClip(const Path&amp;, WindRule = RULE_EVENODD);
+    void clipOut(const Path&amp;);
</ins><span class="cx"> 
</span><del>-        WEBCORE_EXPORT void scale(const FloatSize&amp;);
-        void rotate(float angleInRadians);
-        void translate(const FloatSize&amp; size) { translate(size.width(), size.height()); }
-        WEBCORE_EXPORT void translate(float x, float y);
</del><ins>+    WEBCORE_EXPORT void scale(const FloatSize&amp;);
+    void rotate(float angleInRadians);
+    void translate(const FloatSize&amp; size) { translate(size.width(), size.height()); }
+    WEBCORE_EXPORT void translate(float x, float y);
</ins><span class="cx"> 
</span><del>-        void setURLForRect(const URL&amp;, const IntRect&amp;);
</del><ins>+    void setURLForRect(const URL&amp;, const IntRect&amp;);
</ins><span class="cx"> 
</span><del>-        void concatCTM(const AffineTransform&amp;);
-        void setCTM(const AffineTransform&amp;);
</del><ins>+    void concatCTM(const AffineTransform&amp;);
+    void setCTM(const AffineTransform&amp;);
</ins><span class="cx"> 
</span><del>-        enum IncludeDeviceScale { DefinitelyIncludeDeviceScale, PossiblyIncludeDeviceScale };
-        AffineTransform getCTM(IncludeDeviceScale includeScale = PossiblyIncludeDeviceScale) const;
</del><ins>+    enum IncludeDeviceScale { DefinitelyIncludeDeviceScale, PossiblyIncludeDeviceScale };
+    AffineTransform getCTM(IncludeDeviceScale includeScale = PossiblyIncludeDeviceScale) const;
</ins><span class="cx"> 
</span><span class="cx"> #if ENABLE(3D_TRANSFORMS) &amp;&amp; USE(TEXTURE_MAPPER)
</span><del>-        // This is needed when using accelerated-compositing in software mode, like in TextureMapper.
-        void concat3DTransform(const TransformationMatrix&amp;);
-        void set3DTransform(const TransformationMatrix&amp;);
-        TransformationMatrix get3DTransform() const;
</del><ins>+    // This is needed when using accelerated-compositing in software mode, like in TextureMapper.
+    void concat3DTransform(const TransformationMatrix&amp;);
+    void set3DTransform(const TransformationMatrix&amp;);
+    TransformationMatrix get3DTransform() const;
</ins><span class="cx"> #endif
</span><del>-        // Create an image buffer compatible with this context, with suitable resolution
-        // for drawing into the buffer and then into this context.
-        std::unique_ptr&lt;ImageBuffer&gt; createCompatibleBuffer(const FloatSize&amp;, bool hasAlpha = true) const;
-        bool isCompatibleWithBuffer(ImageBuffer&amp;) const;
</del><ins>+    // Create an image buffer compatible with this context, with suitable resolution
+    // for drawing into the buffer and then into this context.
+    std::unique_ptr&lt;ImageBuffer&gt; createCompatibleBuffer(const FloatSize&amp;, bool hasAlpha = true) const;
+    bool isCompatibleWithBuffer(ImageBuffer&amp;) const;
</ins><span class="cx"> 
</span><del>-        // This function applies the device scale factor to the context, making the context capable of
-        // acting as a base-level context for a HiDPI environment.
-        WEBCORE_EXPORT void applyDeviceScaleFactor(float);
-        void platformApplyDeviceScaleFactor(float);
</del><ins>+    // This function applies the device scale factor to the context, making the context capable of
+    // acting as a base-level context for a HiDPI environment.
+    WEBCORE_EXPORT void applyDeviceScaleFactor(float);
+    void platformApplyDeviceScaleFactor(float);
</ins><span class="cx"> 
</span><span class="cx"> #if OS(WINDOWS)
</span><del>-        HDC getWindowsContext(const IntRect&amp;, bool supportAlphaBlend, bool mayCreateBitmap); // The passed in rect is used to create a bitmap for compositing inside transparency layers.
-        void releaseWindowsContext(HDC, const IntRect&amp;, bool supportAlphaBlend, bool mayCreateBitmap); // The passed in HDC should be the one handed back by getWindowsContext.
-        HDC hdc() const;
</del><ins>+    HDC getWindowsContext(const IntRect&amp;, bool supportAlphaBlend, bool mayCreateBitmap); // The passed in rect is used to create a bitmap for compositing inside transparency layers.
+    void releaseWindowsContext(HDC, const IntRect&amp;, bool supportAlphaBlend, bool mayCreateBitmap); // The passed in HDC should be the one handed back by getWindowsContext.
+    HDC hdc() const;
</ins><span class="cx"> #if PLATFORM(WIN)
</span><span class="cx"> #if USE(WINGDI)
</span><del>-        void setBitmap(PassRefPtr&lt;SharedBitmap&gt;);
-        const AffineTransform&amp; affineTransform() const;
-        AffineTransform&amp; affineTransform();
-        void resetAffineTransform();
-        void fillRect(const FloatRect&amp;, const Gradient*);
-        void drawText(const Font&amp;, const GlyphBuffer&amp;, int from, int numGlyphs, const FloatPoint&amp;);
-        void drawFrameControl(const IntRect&amp; rect, unsigned type, unsigned state);
-        void drawFocusRect(const IntRect&amp; rect);
-        void paintTextField(const IntRect&amp; rect, unsigned state);
-        void drawBitmap(SharedBitmap*, const IntRect&amp; dstRect, const IntRect&amp; srcRect, ColorSpace styleColorSpace, CompositeOperator compositeOp, BlendMode blendMode);
-        void drawBitmapPattern(SharedBitmap*, const FloatRect&amp; tileRectIn, const AffineTransform&amp; patternTransform, const FloatPoint&amp; phase, ColorSpace styleColorSpace, CompositeOperator op, const FloatRect&amp; destRect, const IntSize&amp; origSourceSize);
-        void drawIcon(HICON icon, const IntRect&amp; dstRect, UINT flags);
-        void drawRoundCorner(bool newClip, RECT clipRect, RECT rectWin, HDC dc, int width, int height);
</del><ins>+    void setBitmap(PassRefPtr&lt;SharedBitmap&gt;);
+    const AffineTransform&amp; affineTransform() const;
+    AffineTransform&amp; affineTransform();
+    void resetAffineTransform();
+    void fillRect(const FloatRect&amp;, const Gradient*);
+    void drawText(const Font&amp;, const GlyphBuffer&amp;, int from, int numGlyphs, const FloatPoint&amp;);
+    void drawFrameControl(const IntRect&amp; rect, unsigned type, unsigned state);
+    void drawFocusRect(const IntRect&amp; rect);
+    void paintTextField(const IntRect&amp; rect, unsigned state);
+    void drawBitmap(SharedBitmap*, const IntRect&amp; dstRect, const IntRect&amp; srcRect, ColorSpace styleColorSpace, CompositeOperator compositeOp, BlendMode blendMode);
+    void drawBitmapPattern(SharedBitmap*, const FloatRect&amp; tileRectIn, const AffineTransform&amp; patternTransform, const FloatPoint&amp; phase, ColorSpace styleColorSpace, CompositeOperator op, const FloatRect&amp; destRect, const IntSize&amp; origSourceSize);
+    void drawIcon(HICON icon, const IntRect&amp; dstRect, UINT flags);
+    void drawRoundCorner(bool newClip, RECT clipRect, RECT rectWin, HDC dc, int width, int height);
</ins><span class="cx"> #else
</span><del>-        GraphicsContext(HDC, bool hasAlpha = false); // FIXME: To be removed.
</del><ins>+    GraphicsContext(HDC, bool hasAlpha = false); // FIXME: To be removed.
</ins><span class="cx"> 
</span><del>-        // When set to true, child windows should be rendered into this context
-        // rather than allowing them just to render to the screen. Defaults to
-        // false.
-        // FIXME: This is a layering violation. GraphicsContext shouldn't know
-        // what a &quot;window&quot; is. It would be much more appropriate for this flag
-        // to be passed as a parameter alongside the GraphicsContext, but doing
-        // that would require lots of changes in cross-platform code that we
-        // aren't sure we want to make.
-        void setShouldIncludeChildWindows(bool);
-        bool shouldIncludeChildWindows() const;
</del><ins>+    // When set to true, child windows should be rendered into this context
+    // rather than allowing them just to render to the screen. Defaults to
+    // false.
+    // FIXME: This is a layering violation. GraphicsContext shouldn't know
+    // what a &quot;window&quot; is. It would be much more appropriate for this flag
+    // to be passed as a parameter alongside the GraphicsContext, but doing
+    // that would require lots of changes in cross-platform code that we
+    // aren't sure we want to make.
+    void setShouldIncludeChildWindows(bool);
+    bool shouldIncludeChildWindows() const;
</ins><span class="cx"> 
</span><del>-        class WindowsBitmap {
-            WTF_MAKE_NONCOPYABLE(WindowsBitmap);
-        public:
-            WindowsBitmap(HDC, const IntSize&amp;);
-            ~WindowsBitmap();
</del><ins>+    class WindowsBitmap {
+        WTF_MAKE_NONCOPYABLE(WindowsBitmap);
+    public:
+        WindowsBitmap(HDC, const IntSize&amp;);
+        ~WindowsBitmap();
</ins><span class="cx"> 
</span><del>-            HDC hdc() const { return m_hdc; }
-            UInt8* buffer() const { return m_pixelData.buffer(); }
-            unsigned bufferLength() const { return m_pixelData.bufferLength(); }
-            const IntSize&amp; size() const { return m_pixelData.size(); }
-            unsigned bytesPerRow() const { return m_pixelData.bytesPerRow(); }
-            unsigned short bitsPerPixel() const { return m_pixelData.bitsPerPixel(); }
-            const DIBPixelData&amp; windowsDIB() const { return m_pixelData; }
</del><ins>+        HDC hdc() const { return m_hdc; }
+        UInt8* buffer() const { return m_pixelData.buffer(); }
+        unsigned bufferLength() const { return m_pixelData.bufferLength(); }
+        const IntSize&amp; size() const { return m_pixelData.size(); }
+        unsigned bytesPerRow() const { return m_pixelData.bytesPerRow(); }
+        unsigned short bitsPerPixel() const { return m_pixelData.bitsPerPixel(); }
+        const DIBPixelData&amp; windowsDIB() const { return m_pixelData; }
</ins><span class="cx"> 
</span><del>-        private:
-            HDC m_hdc;
-            HBITMAP m_bitmap;
-            DIBPixelData m_pixelData;
-        };
</del><ins>+    private:
+        HDC m_hdc;
+        HBITMAP m_bitmap;
+        DIBPixelData m_pixelData;
+    };
</ins><span class="cx"> 
</span><del>-        std::unique_ptr&lt;WindowsBitmap&gt; createWindowsBitmap(const IntSize&amp;);
-        // The bitmap should be non-premultiplied.
-        void drawWindowsBitmap(WindowsBitmap*, const IntPoint&amp;);
</del><ins>+    std::unique_ptr&lt;WindowsBitmap&gt; createWindowsBitmap(const IntSize&amp;);
+    // The bitmap should be non-premultiplied.
+    void drawWindowsBitmap(WindowsBitmap*, const IntPoint&amp;);
</ins><span class="cx"> #endif
</span><span class="cx"> #else // PLATFORM(WIN)
</span><del>-        bool shouldIncludeChildWindows() const { return false; }
</del><ins>+    bool shouldIncludeChildWindows() const { return false; }
</ins><span class="cx"> #endif // PLATFORM(WIN)
</span><span class="cx"> #endif // OS(WINDOWS)
</span><span class="cx"> 
</span><span class="cx"> #if USE(CAIRO)
</span><del>-        GraphicsContext(cairo_t*);
</del><ins>+    GraphicsContext(cairo_t*);
</ins><span class="cx"> #endif
</span><span class="cx"> 
</span><del>-        static void adjustLineToPixelBoundaries(FloatPoint&amp; p1, FloatPoint&amp; p2, float strokeWidth, StrokeStyle);
</del><ins>+    static void adjustLineToPixelBoundaries(FloatPoint&amp; p1, FloatPoint&amp; p2, float strokeWidth, StrokeStyle);
</ins><span class="cx"> 
</span><del>-    private:
-        void platformInit(PlatformGraphicsContext*);
-        void platformDestroy();
</del><ins>+private:
+    void platformInit(PlatformGraphicsContext*);
+    void platformDestroy();
</ins><span class="cx"> 
</span><span class="cx"> #if PLATFORM(WIN) &amp;&amp; !USE(WINGDI)
</span><del>-        void platformInit(HDC, bool hasAlpha = false);
</del><ins>+    void platformInit(HDC, bool hasAlpha = false);
</ins><span class="cx"> #endif
</span><span class="cx"> 
</span><del>-        void savePlatformState();
-        void restorePlatformState();
</del><ins>+    void savePlatformState();
+    void restorePlatformState();
</ins><span class="cx"> 
</span><del>-        void setPlatformTextDrawingMode(TextDrawingModeFlags);
</del><ins>+    void setPlatformTextDrawingMode(TextDrawingModeFlags);
</ins><span class="cx"> 
</span><del>-        void setPlatformStrokeColor(const Color&amp;, ColorSpace);
-        void setPlatformStrokeStyle(StrokeStyle);
-        void setPlatformStrokeThickness(float);
</del><ins>+    void setPlatformStrokeColor(const Color&amp;, ColorSpace);
+    void setPlatformStrokeStyle(StrokeStyle);
+    void setPlatformStrokeThickness(float);
</ins><span class="cx"> 
</span><del>-        void setPlatformFillColor(const Color&amp;, ColorSpace);
</del><ins>+    void setPlatformFillColor(const Color&amp;, ColorSpace);
</ins><span class="cx"> 
</span><del>-        void setPlatformShouldAntialias(bool);
-        void setPlatformShouldSmoothFonts(bool);
</del><ins>+    void setPlatformShouldAntialias(bool);
+    void setPlatformShouldSmoothFonts(bool);
</ins><span class="cx"> 
</span><del>-        void setPlatformShadow(const FloatSize&amp;, float blur, const Color&amp;, ColorSpace);
-        void clearPlatformShadow();
</del><ins>+    void setPlatformShadow(const FloatSize&amp;, float blur, const Color&amp;, ColorSpace);
+    void clearPlatformShadow();
</ins><span class="cx"> 
</span><del>-        void setPlatformAlpha(float);
-        void setPlatformCompositeOperation(CompositeOperator, BlendMode = BlendModeNormal);
</del><ins>+    void setPlatformAlpha(float);
+    void setPlatformCompositeOperation(CompositeOperator, BlendMode = BlendModeNormal);
</ins><span class="cx"> 
</span><del>-        void beginPlatformTransparencyLayer(float opacity);
-        void endPlatformTransparencyLayer();
-        static bool supportsTransparencyLayers();
</del><ins>+    void beginPlatformTransparencyLayer(float opacity);
+    void endPlatformTransparencyLayer();
+    static bool supportsTransparencyLayers();
</ins><span class="cx"> 
</span><del>-        void fillEllipseAsPath(const FloatRect&amp;);
-        void strokeEllipseAsPath(const FloatRect&amp;);
</del><ins>+    void fillEllipseAsPath(const FloatRect&amp;);
+    void strokeEllipseAsPath(const FloatRect&amp;);
</ins><span class="cx"> 
</span><del>-        void platformFillEllipse(const FloatRect&amp;);
-        void platformStrokeEllipse(const FloatRect&amp;);
</del><ins>+    void platformFillEllipse(const FloatRect&amp;);
+    void platformStrokeEllipse(const FloatRect&amp;);
</ins><span class="cx"> 
</span><del>-        void platformFillRoundedRect(const FloatRoundedRect&amp;, const Color&amp;, ColorSpace);
</del><ins>+    void platformFillRoundedRect(const FloatRoundedRect&amp;, const Color&amp;, ColorSpace);
</ins><span class="cx"> 
</span><del>-        FloatRect computeLineBoundsAndAntialiasingModeForText(const FloatPoint&amp;, float width, bool printing, bool&amp; shouldAntialias, Color&amp;);
</del><ins>+    FloatRect computeLineBoundsAndAntialiasingModeForText(const FloatPoint&amp;, float width, bool printing, bool&amp; shouldAntialias, Color&amp;);
</ins><span class="cx"> 
</span><del>-        GraphicsContextPlatformPrivate* m_data;
</del><ins>+    GraphicsContextPlatformPrivate* m_data;
</ins><span class="cx"> 
</span><del>-        GraphicsContextState m_state;
-        Vector&lt;GraphicsContextState, 1&gt; m_stack;
-        bool m_updatingControlTints;
-        unsigned m_transparencyCount;
-    };
</del><ins>+    GraphicsContextState m_state;
+    Vector&lt;GraphicsContextState, 1&gt; m_stack;
+    bool m_updatingControlTints;
+    unsigned m_transparencyCount;
+};
</ins><span class="cx"> 
</span><del>-    class GraphicsContextStateSaver {
-        WTF_MAKE_FAST_ALLOCATED;
-    public:
-        GraphicsContextStateSaver(GraphicsContext&amp; context, bool saveAndRestore = true)
-        : m_context(context)
-        , m_saveAndRestore(saveAndRestore)
-        {
-            if (m_saveAndRestore)
-                m_context.save();
-        }
-        
-        ~GraphicsContextStateSaver()
-        {
-            if (m_saveAndRestore)
-                m_context.restore();
-        }
-        
-        void save()
-        {
-            ASSERT(!m_saveAndRestore);
</del><ins>+class GraphicsContextStateSaver {
+    WTF_MAKE_FAST_ALLOCATED;
+public:
+    GraphicsContextStateSaver(GraphicsContext&amp; context, bool saveAndRestore = true)
+    : m_context(context)
+    , m_saveAndRestore(saveAndRestore)
+    {
+        if (m_saveAndRestore)
</ins><span class="cx">             m_context.save();
</span><del>-            m_saveAndRestore = true;
-        }
-
-        void restore()
-        {
-            ASSERT(m_saveAndRestore);
</del><ins>+    }
+    
+    ~GraphicsContextStateSaver()
+    {
+        if (m_saveAndRestore)
</ins><span class="cx">             m_context.restore();
</span><del>-            m_saveAndRestore = false;
-        }
-        
-        GraphicsContext* context() const { return &amp;m_context; }
</del><ins>+    }
+    
+    void save()
+    {
+        ASSERT(!m_saveAndRestore);
+        m_context.save();
+        m_saveAndRestore = true;
+    }
</ins><span class="cx"> 
</span><del>-    private:
-        GraphicsContext&amp; m_context;
-        bool m_saveAndRestore;
-    };
</del><ins>+    void restore()
+    {
+        ASSERT(m_saveAndRestore);
+        m_context.restore();
+        m_saveAndRestore = false;
+    }
+    
+    GraphicsContext* context() const { return &amp;m_context; }
</ins><span class="cx"> 
</span><ins>+private:
+    GraphicsContext&amp; m_context;
+    bool m_saveAndRestore;
+};
+
</ins><span class="cx"> } // namespace WebCore
</span><span class="cx"> 
</span><span class="cx"> #endif // GraphicsContext_h
</span><del>-
</del></span></pre>
</div>
</div>

</body>
</html>