mirror of
https://gitlab.freedesktop.org/cairo/cairo.git
synced 2026-05-06 09:18:11 +02:00
quartz: Make glyph antialiasing consistent with quartz-font
CAIRO_ANTIALIAS_{FAST,GOOD,BEST} were introduced and used in
cairo-quartz-font.c by commit 70cd3b473d.
Fixes the warnings:
cairo-quartz-surface.c: In function '_cairo_quartz_cg_glyphs':
cairo-quartz-surface.c:1976: warning: enumeration value 'CAIRO_ANTIALIAS_FAST' not handled in switch
cairo-quartz-surface.c:1976: warning: enumeration value 'CAIRO_ANTIALIAS_GOOD' not handled in switch
cairo-quartz-surface.c:1976: warning: enumeration value 'CAIRO_ANTIALIAS_BEST' not handled in switch
This commit is contained in:
parent
29145f4e48
commit
7058e8c181
1 changed files with 3 additions and 0 deletions
|
|
@ -1980,6 +1980,7 @@ _cairo_quartz_cg_glyphs (const cairo_compositor_t *compositor,
|
|||
|
||||
switch (scaled_font->options.antialias) {
|
||||
case CAIRO_ANTIALIAS_SUBPIXEL:
|
||||
case CAIRO_ANTIALIAS_BEST:
|
||||
CGContextSetShouldAntialias (state.cgMaskContext, TRUE);
|
||||
CGContextSetShouldSmoothFonts (state.cgMaskContext, TRUE);
|
||||
if (CGContextSetAllowsFontSmoothingPtr &&
|
||||
|
|
@ -1993,6 +1994,8 @@ _cairo_quartz_cg_glyphs (const cairo_compositor_t *compositor,
|
|||
CGContextSetShouldAntialias (state.cgMaskContext, FALSE);
|
||||
break;
|
||||
case CAIRO_ANTIALIAS_GRAY:
|
||||
case CAIRO_ANTIALIAS_GOOD:
|
||||
case CAIRO_ANTIALIAS_FAST:
|
||||
CGContextSetShouldAntialias (state.cgMaskContext, TRUE);
|
||||
CGContextSetShouldSmoothFonts (state.cgMaskContext, FALSE);
|
||||
break;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue