mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 898267 - support font smoothing in Azure CG backend. r=jrmuizel
This commit is contained in:
parent
f843bbb3ea
commit
79e2fd3173
@ -1007,6 +1007,9 @@ DrawTargetCG::FillGlyphs(ScaledFont *aFont, const GlyphBuffer &aBuffer, const Pa
|
||||
CGContextRef cg = fixer.Check(mCg, aDrawOptions.mCompositionOp);
|
||||
CGContextSetAlpha(cg, aDrawOptions.mAlpha);
|
||||
CGContextSetShouldAntialias(cg, aDrawOptions.mAntialiasMode != AA_NONE);
|
||||
if (aDrawOptions.mAntialiasMode != AA_DEFAULT) {
|
||||
CGContextSetShouldSmoothFonts(cg, aDrawOptions.mAntialiasMode == AA_SUBPIXEL);
|
||||
}
|
||||
|
||||
CGContextConcatCTM(cg, GfxMatrixToCGAffineTransform(mTransform));
|
||||
|
||||
|
@ -84,8 +84,10 @@ gfxMacFont::gfxMacFont(MacOSFontEntry *aFontEntry, const gfxFontStyle *aFontStyl
|
||||
if (mAdjustedSize <=
|
||||
(gfxFloat)gfxPlatformMac::GetPlatform()->GetAntiAliasingThreshold()) {
|
||||
cairo_font_options_set_antialias(fontOptions, CAIRO_ANTIALIAS_NONE);
|
||||
mAntialiasOption = kAntialiasNone;
|
||||
} else if (mStyle.useGrayscaleAntialiasing) {
|
||||
cairo_font_options_set_antialias(fontOptions, CAIRO_ANTIALIAS_GRAY);
|
||||
mAntialiasOption = kAntialiasGrayscale;
|
||||
}
|
||||
|
||||
mScaledFont = cairo_scaled_font_create(mFontFace, &sizeMatrix, &ctm,
|
||||
|
Loading…
Reference in New Issue
Block a user