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

Unified Diff: Source/platform/fonts/Font.cpp

Issue 692643006: Restore webkit-font-smoothing. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Actually suppress flaky tests. Created 6 years, 1 month 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 | « Source/platform/fonts/Font.h ('k') | Source/platform/fonts/FontPlatformData.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/platform/fonts/Font.cpp
diff --git a/Source/platform/fonts/Font.cpp b/Source/platform/fonts/Font.cpp
index bc22d60f376ae3fffecf72eaf1d9071c5fe8a3d2..2bfc2c6419fa21095e7f4664748ad80efa54745c 100644
--- a/Source/platform/fonts/Font.cpp
+++ b/Source/platform/fonts/Font.cpp
@@ -749,19 +749,19 @@ int Font::emphasisMarkHeight(const AtomicString& mark) const
return markFontData->fontMetrics().height();
}
-static SkPaint textFillPaint(GraphicsContext* gc, const SimpleFontData* font)
+SkPaint Font::textFillPaint(GraphicsContext* gc, const SimpleFontData* font) const
{
SkPaint paint = gc->fillPaint();
- font->platformData().setupPaint(&paint, gc);
+ font->platformData().setupPaint(&paint, gc, this);
gc->adjustTextRenderMode(&paint);
paint.setTextEncoding(SkPaint::kGlyphID_TextEncoding);
return paint;
}
-static SkPaint textStrokePaint(GraphicsContext* gc, const SimpleFontData* font, bool isFilling)
+SkPaint Font::textStrokePaint(GraphicsContext* gc, const SimpleFontData* font, bool isFilling) const
{
SkPaint paint = gc->strokePaint();
- font->platformData().setupPaint(&paint, gc);
+ font->platformData().setupPaint(&paint, gc, this);
gc->adjustTextRenderMode(&paint);
paint.setTextEncoding(SkPaint::kGlyphID_TextEncoding);
if (isFilling) {
@@ -779,9 +779,9 @@ static SkPaint textStrokePaint(GraphicsContext* gc, const SimpleFontData* font,
return paint;
}
-static void paintGlyphs(GraphicsContext* gc, const SimpleFontData* font,
+void Font::paintGlyphs(GraphicsContext* gc, const SimpleFontData* font,
const Glyph glyphs[], unsigned numGlyphs,
- const SkPoint pos[], const FloatRect& textRect)
+ const SkPoint pos[], const FloatRect& textRect) const
{
TextDrawingModeFlags textMode = gc->textDrawingMode();
@@ -797,9 +797,9 @@ static void paintGlyphs(GraphicsContext* gc, const SimpleFontData* font,
}
}
-static void paintGlyphsHorizontal(GraphicsContext* gc, const SimpleFontData* font,
+void Font::paintGlyphsHorizontal(GraphicsContext* gc, const SimpleFontData* font,
const Glyph glyphs[], unsigned numGlyphs,
- const SkScalar xpos[], SkScalar constY, const FloatRect& textRect)
+ const SkScalar xpos[], SkScalar constY, const FloatRect& textRect) const
{
TextDrawingModeFlags textMode = gc->textDrawingMode();
« no previous file with comments | « Source/platform/fonts/Font.h ('k') | Source/platform/fonts/FontPlatformData.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698