Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1369)

Unified Diff: Source/platform/fonts/win/SkiaFontWin.cpp

Issue 209113002: Remove unnecessary paintSkiaText wrapper (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/platform/fonts/win/SkiaFontWin.cpp
diff --git a/Source/platform/fonts/win/SkiaFontWin.cpp b/Source/platform/fonts/win/SkiaFontWin.cpp
index faae245fc949c86281e1fcf2d020e2da9af95228..9b0f48aa6abd68e00ebd7bdd2d0293e0b165b649 100644
--- a/Source/platform/fonts/win/SkiaFontWin.cpp
+++ b/Source/platform/fonts/win/SkiaFontWin.cpp
@@ -83,9 +83,8 @@ static void skiaDrawText(GraphicsContext* context,
}
}
-static void paintSkiaText(GraphicsContext* context,
+void paintSkiaText(GraphicsContext* context,
const FontPlatformData& data,
- SkTypeface* face, float size, uint32_t textFlags,
unsigned numGlyphs,
const WORD* glyphs,
const int* advances,
@@ -101,11 +100,6 @@ static void paintSkiaText(GraphicsContext* context,
paint.setTextEncoding(SkPaint::kGlyphID_TextEncoding);
data.setupPaint(&paint, context);
- // FIXME: Only needed to support the HFONT based paintSkiaText
- // version where a new typeface is created from the HFONT.
- // As such it can go away once the HFONT code path is removed.
- paint.setTypeface(face);
-
bool didFill = false;
if ((textMode & TextModeFill) && (SkColorGetA(paint.getColor()) || paint.getLooper())) {
@@ -122,7 +116,6 @@ static void paintSkiaText(GraphicsContext* context,
context->setupPaintForStroking(&paint);
paint.setTextEncoding(SkPaint::kGlyphID_TextEncoding);
data.setupPaint(&paint, context);
- paint.setTypeface(face);
if (didFill) {
// If there is a shadow and we filled above, there will already be
@@ -141,19 +134,4 @@ static void paintSkiaText(GraphicsContext* context,
}
}
-///////////////////////////////////////////////////////////////////////////////////////////
-
-void paintSkiaText(GraphicsContext* context,
- const FontPlatformData& data,
- unsigned numGlyphs,
- const WORD* glyphs,
- const int* advances,
- const GOFFSET* offsets,
- const SkPoint& origin,
- const SkRect& textRect)
-{
- paintSkiaText(context, data, data.typeface(), data.size(), data.paintTextFlags(),
- numGlyphs, glyphs, advances, offsets, origin, textRect);
-}
-
} // namespace WebCore
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698