From 74e192417c4161d7e063b84e7a8268fafeeed11b Mon Sep 17 00:00:00 2001 From: Robert O'Callahan Date: Thu, 9 Jun 2011 08:13:02 +0100 Subject: [PATCH] Bug 661471. Part 6.1: Expose cairo_win32_get_system_text_quality. r=jfkthame --- gfx/cairo/cairo/src/cairo-dwrite-font.cpp | 2 +- gfx/cairo/cairo/src/cairo-win32-font.c | 4 ++-- gfx/cairo/cairo/src/cairo-win32-private.h | 3 --- gfx/cairo/cairo/src/cairo-win32.h | 2 ++ 4 files changed, 5 insertions(+), 6 deletions(-) diff --git a/gfx/cairo/cairo/src/cairo-dwrite-font.cpp b/gfx/cairo/cairo/src/cairo-dwrite-font.cpp index ab819084ade..8808215782b 100644 --- a/gfx/cairo/cairo/src/cairo-dwrite-font.cpp +++ b/gfx/cairo/cairo/src/cairo-dwrite-font.cpp @@ -468,7 +468,7 @@ _cairo_dwrite_font_face_scaled_font_create (void *abstract_face, // this means that if cleartype settings are changed but the scaled_fonts // are re-used, they might not adhere to the new system setting until re- // creation. - switch (_cairo_win32_get_system_text_quality()) { + switch (cairo_win32_get_system_text_quality()) { case CLEARTYPE_QUALITY: default_quality = CAIRO_ANTIALIAS_SUBPIXEL; break; diff --git a/gfx/cairo/cairo/src/cairo-win32-font.c b/gfx/cairo/cairo/src/cairo-win32-font.c index 940d896647c..6ba20d53d0c 100644 --- a/gfx/cairo/cairo/src/cairo-win32-font.c +++ b/gfx/cairo/cairo/src/cairo-win32-font.c @@ -258,7 +258,7 @@ _have_cleartype_quality (void) } BYTE -_cairo_win32_get_system_text_quality (void) +cairo_win32_get_system_text_quality (void) { BOOL font_smoothing; UINT smoothing_type; @@ -325,7 +325,7 @@ _win32_scaled_font_create (LOGFONTW *logfont, * here is the hint_metrics options. */ if (options->antialias == CAIRO_ANTIALIAS_DEFAULT) - f->quality = _cairo_win32_get_system_text_quality (); + f->quality = cairo_win32_get_system_text_quality (); else { switch (options->antialias) { case CAIRO_ANTIALIAS_NONE: diff --git a/gfx/cairo/cairo/src/cairo-win32-private.h b/gfx/cairo/cairo/src/cairo-win32-private.h index 6a28f56bffb..63f0fb4666a 100644 --- a/gfx/cairo/cairo/src/cairo-win32-private.h +++ b/gfx/cairo/cairo/src/cairo-win32-private.h @@ -216,9 +216,6 @@ _cairo_win32_scaled_font_is_type1 (cairo_scaled_font_t *scaled_font); cairo_bool_t _cairo_win32_scaled_font_is_bitmap (cairo_scaled_font_t *scaled_font); -BYTE -_cairo_win32_get_system_text_quality (void); - #ifdef WINCE // These are the required stubs for windows mobile diff --git a/gfx/cairo/cairo/src/cairo-win32.h b/gfx/cairo/cairo/src/cairo-win32.h index cee1f66b1d1..b84352d7378 100644 --- a/gfx/cairo/cairo/src/cairo-win32.h +++ b/gfx/cairo/cairo/src/cairo-win32.h @@ -80,6 +80,8 @@ cairo_win32_surface_set_can_convert_to_dib (cairo_surface_t *surface, cairo_bool cairo_public cairo_status_t cairo_win32_surface_get_can_convert_to_dib (cairo_surface_t *surface, cairo_bool_t *can_convert); +BYTE cairo_win32_get_system_text_quality (void); + #if CAIRO_HAS_WIN32_FONT /*