From a3530ef268acbbbd84cd4c5465cdc29df5269390 Mon Sep 17 00:00:00 2001 From: bungeman Date: Fri, 20 Jun 2014 10:35:00 -0700 Subject: DirectWrite to not round already subpixel metrics. In keeping with the FreeType and Mac scaler contexts, do not artificially round already subpixel metrics. The subpixel flag should be the 'forceSubpixel' flag when it comes to metrics. Existing backends will give subpixel metrics when 'subpixel' is requested, but will not round proper metrics when 'subpixel' is not requested. R=reed@google.com Author: bungeman@google.com Review URL: https://codereview.chromium.org/344253002 --- src/ports/SkScalerContext_win_dw.cpp | 4 ---- 1 file changed, 4 deletions(-) (limited to 'src/ports') diff --git a/src/ports/SkScalerContext_win_dw.cpp b/src/ports/SkScalerContext_win_dw.cpp index fa21df537c..f3293bf003 100644 --- a/src/ports/SkScalerContext_win_dw.cpp +++ b/src/ports/SkScalerContext_win_dw.cpp @@ -288,10 +288,6 @@ void SkScalerContext_DW::generateAdvance(SkGlyph* glyph) { SkIntToScalar(gm.advanceWidth), SkIntToScalar(dwfm.designUnitsPerEm)); - if (!this->isSubpixel()) { - advanceX = SkScalarRoundToScalar(advanceX); - } - SkVector vecs[1] = { { advanceX, 0 } }; if (DWRITE_MEASURING_MODE_GDI_CLASSIC == fMeasuringMode || DWRITE_MEASURING_MODE_GDI_NATURAL == fMeasuringMode) -- cgit v1.2.3