summaryrefslogtreecommitdiff
path: root/src/cairo-xlib-private.h
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2008-10-24 08:39:29 +0100
committerChris Wilson <chris@chris-wilson.co.uk>2008-10-30 17:52:13 +0000
commita0023758104b700751ba8d7a66d75db139eea6cb (patch)
tree24885d61fb34c1ad4e9fec0918bc6087a85b5bff /src/cairo-xlib-private.h
parent6706590d4e7ad19dae0b8e3efe6f573d5688e19a (diff)
downloadcairo-a0023758104b700751ba8d7a66d75db139eea6cb.tar.gz
[xlib] Defer querying of font options until first use
Constructing the font options cause the initialisation of Xlc and invoke several round-trips to the X server, significantly delaying the creation of the first surface. By deferring that operation until the first use of fonts then we avoid that overhead for very simple applications (like the test suite) and should improve start-up latency for larger application.
Diffstat (limited to 'src/cairo-xlib-private.h')
-rw-r--r--src/cairo-xlib-private.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/cairo-xlib-private.h b/src/cairo-xlib-private.h
index e381e584d..79cd6b56e 100644
--- a/src/cairo-xlib-private.h
+++ b/src/cairo-xlib-private.h
@@ -97,6 +97,7 @@ struct _cairo_xlib_screen_info {
Screen *screen;
cairo_bool_t has_render;
+ cairo_bool_t has_font_options;
cairo_font_options_t font_options;
GC gc[9];
@@ -151,6 +152,9 @@ _cairo_xlib_screen_get_gc (cairo_xlib_screen_info_t *info, int depth);
cairo_private cairo_status_t
_cairo_xlib_screen_put_gc (cairo_xlib_screen_info_t *info, int depth, GC gc, cairo_bool_t reset_clip);
+cairo_private cairo_font_options_t *
+_cairo_xlib_screen_get_font_options (cairo_xlib_screen_info_t *info);
+
cairo_private cairo_status_t
_cairo_xlib_screen_get_visual_info (cairo_xlib_screen_info_t *info,
Visual *visual,