diff options
author | Ben Murdoch <benm@google.com> | 2011-05-06 11:21:12 +0100 |
---|---|---|
committer | Ben Murdoch <benm@google.com> | 2011-05-10 15:38:32 +0100 |
commit | b2a9e2728d6dcf8aecf09fe037e942a8dba233c1 (patch) | |
tree | a03fa06bb590f44753cb6e10fc34ce70e360f7ab /WebCore/platform/graphics/android/FontAndroid.cpp | |
parent | 312a1f86fb2e3afb0948da0b2915fae853fbc54e (diff) | |
download | external_webkit-b2a9e2728d6dcf8aecf09fe037e942a8dba233c1.zip external_webkit-b2a9e2728d6dcf8aecf09fe037e942a8dba233c1.tar.gz external_webkit-b2a9e2728d6dcf8aecf09fe037e942a8dba233c1.tar.bz2 |
Merge WebKit at r74534: Fix FontAndroid.cpp (TextMode constants)
Port style changes to our code.
See http://trac.webkit.org/changeset/73284
Change-Id: I03a5a7aa7a9a319ac4dbfc257c7adf83b362107c
Diffstat (limited to 'WebCore/platform/graphics/android/FontAndroid.cpp')
-rw-r--r-- | WebCore/platform/graphics/android/FontAndroid.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/WebCore/platform/graphics/android/FontAndroid.cpp b/WebCore/platform/graphics/android/FontAndroid.cpp index 64d6aca..0a9ce5a 100644 --- a/WebCore/platform/graphics/android/FontAndroid.cpp +++ b/WebCore/platform/graphics/android/FontAndroid.cpp @@ -76,7 +76,7 @@ static SkPaint* setupStroke(SkPaint* paint, GraphicsContext* gc, static bool setupForText(SkPaint* paint, GraphicsContext* gc, const SimpleFontData* font) { - int mode = gc->textDrawingMode() & (cTextFill | cTextStroke); + int mode = gc->textDrawingMode() & (TextModeFill | TextModeStroke); if (!mode) return false; @@ -86,7 +86,7 @@ static bool setupForText(SkPaint* paint, GraphicsContext* gc, ColorSpace shadowColorSpace; bool hasShadow = gc->getShadow(shadowOffset, shadowBlur, shadowColor, shadowColorSpace); bool hasBothStrokeAndFill = - (mode & (cTextStroke | cTextFill)) == (cTextStroke | cTextFill); + (mode & (TextModeStroke | TextModeFill)) == (TextModeStroke | TextModeFill); if (hasShadow || hasBothStrokeAndFill) { SkLayerDrawLooper* looper = new SkLayerDrawLooper; paint->setLooper(looper)->unref(); @@ -102,11 +102,11 @@ static bool setupForText(SkPaint* paint, GraphicsContext* gc, bool hasStrokePaint = false; SkScalar strokeWidth; - if ((mode & cTextStroke) && gc->willStroke()) { + if ((mode & TextModeStroke) && gc->willStroke()) { strokeWidth = setupStroke(looper->addLayer(info), gc, font)->getStrokeWidth(); hasStrokePaint = true; } - if ((mode & cTextFill) && gc->willFill()) { + if ((mode & TextModeFill) && gc->willFill()) { setupFill(looper->addLayer(info), gc, font); hasFillPaint = true; } @@ -142,9 +142,9 @@ static bool setupForText(SkPaint* paint, GraphicsContext* gc, updateForFont(p, font); } } - } else if (mode & cTextFill) { + } else if (mode & TextModeFill) { (void)setupFill(paint, gc, font); - } else if (mode & cTextStroke) { + } else if (mode & TextModeStroke) { (void)setupStroke(paint, gc, font); } else { return false; @@ -894,8 +894,8 @@ void Font::drawComplexText(GraphicsContext* gc, TextRun const& run, return; int mode = gc->textDrawingMode(); - bool fill = mode & cTextFill; - bool stroke = mode & cTextStroke; + bool fill = mode & TextModeFill; + bool stroke = mode & TextModeStroke; if (!fill && !stroke) return; |