зеркало из https://github.com/mozilla/moz-skia.git
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
This commit is contained in:
Родитель
4ed75287ae
Коммит
a3530ef268
|
@ -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)
|
||||
|
|
Загрузка…
Ссылка в новой задаче