diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2009-07-31 14:48:32 +0100 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2009-07-31 14:48:32 +0100 |
commit | 097484da6fd70867ed2128e78247eab5c43217fb (patch) | |
tree | f06f2640a7588498b758ac38533487a7b1e45e89 /boilerplate/cairo-boilerplate-xlib.c | |
parent | 397538a251ae19bb1a34650763eb9a80108a96de (diff) |
[boilerplate] Conditionally tweak the xlib surface
Prior to introduction of the buggy members to the surface, we obviously
cannot set them. However, the boilerplate code is meant to compile against
older revisions of the library so we need to check for the existence prior
to use.
Diffstat (limited to 'boilerplate/cairo-boilerplate-xlib.c')
-rw-r--r-- | boilerplate/cairo-boilerplate-xlib.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/boilerplate/cairo-boilerplate-xlib.c b/boilerplate/cairo-boilerplate-xlib.c index 6810dd66..d67a938f 100644 --- a/boilerplate/cairo-boilerplate-xlib.c +++ b/boilerplate/cairo-boilerplate-xlib.c @@ -257,9 +257,15 @@ cairo_boilerplate_xlib_surface_disable_render (cairo_surface_t *abstract_surface surface->base.content = CAIRO_CONTENT_COLOR; /* These flags are set based on known bugs and lack of RENDER support */ - surface->buggy_repeat = TRUE; - surface->buggy_pad_reflect = TRUE; +#if CAIRO_XLIB_SURFACE_HAS_BUGGY_GRADIENTS surface->buggy_gradients = TRUE; +#endif +#if CAIRO_XLIB_SURFACE_HAS_BUGGY_PAD_REFLECT + surface->buggy_pad_reflect = TRUE; +#endif +#if CAIRO_XLIB_SURFACE_HAS_BUGGY_REPEAT + surface->buggy_repeat = TRUE; +#endif return CAIRO_STATUS_SUCCESS; } |