[cairo-commit] src/cairo-ft-font.c
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Sat Jun 1 03:07:34 UTC 2019
src/cairo-ft-font.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
New commits:
commit bab53d91a8543e2ddb15f9dce98ebb3f9bcd5d22
Author: Florian Müllner <fmuellner at gnome.org>
Date: Mon Mar 11 03:51:40 2019 +0100
ft-font: Fix color font support
FT_PIXEL_MODE_BGRA is an enum member, not a define, so it always appears
as 0 in the preprocessor conditions added in commit c0ed8ce1a11.
There is an existing define for color font support, use that instead.
diff --git a/src/cairo-ft-font.c b/src/cairo-ft-font.c
index fea489d01..6b2af3713 100644
--- a/src/cairo-ft-font.c
+++ b/src/cairo-ft-font.c
@@ -976,7 +976,7 @@ _compute_xrender_bitmap_size(FT_Bitmap *target,
pitch = width * 4;
break;
-#ifdef FT_PIXEL_MODE_BGRA
+#ifdef FT_LOAD_COLOR
case FT_PIXEL_MODE_BGRA:
/* each pixel is replicated into a 32-bit ARGB value */
pitch = width * 4;
@@ -1179,7 +1179,7 @@ _fill_xrender_bitmap(FT_Bitmap *target,
}
break;
-#ifdef FT_PIXEL_MODE_BGRA
+#ifdef FT_LOAD_COLOR
case FT_PIXEL_MODE_BGRA:
for (h = height; h > 0; h--, srcLine += src_pitch, dstLine += pitch)
memcpy (dstLine, srcLine, width * 4);
@@ -1293,7 +1293,7 @@ _get_bitmap_surface (FT_Bitmap *bitmap,
component_alpha = TRUE;
}
break;
-#ifdef FT_PIXEL_MODE_BGRA
+#ifdef FT_LOAD_COLOR
case FT_PIXEL_MODE_BGRA:
stride = width * 4;
if (own_buffer) {
More information about the cairo-commit
mailing list