diff options
author | Lukáš Lalinský <lukas@oxygene.sk> | 2014-09-03 22:53:55 +0200 |
---|---|---|
committer | Uli Schlachter <psychon@znc.in> | 2014-09-12 18:19:44 +0200 |
commit | e691d242d592a8556e25659fb091a2031abee4c9 (patch) | |
tree | 9959ed9f811921417828d436f1a0fa0dd2a6e763 /src/cairo-xcb-private.h | |
parent | e77d0a5611fedce2bfa0940ff62f003c1f9cfa08 (diff) | |
download | cairo-e691d242d592a8556e25659fb091a2031abee4c9.tar.gz |
xcb: Initialize font options from Xft resources
There is a similar code in the Xlib backend. The logic here is the same, but
XCB doesn't support X resources directly, so there is some custom code
to get and parse the resources from the root window.
Signed-off-by: Lukáš Lalinský <lukas@oxygene.sk>
Reviewed-by: Uli Schlachter <psychon@znc.in>
Diffstat (limited to 'src/cairo-xcb-private.h')
-rw-r--r-- | src/cairo-xcb-private.h | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/src/cairo-xcb-private.h b/src/cairo-xcb-private.h index 134100a7b..26104584f 100644 --- a/src/cairo-xcb-private.h +++ b/src/cairo-xcb-private.h @@ -75,6 +75,7 @@ typedef struct _cairo_xcb_surface cairo_xcb_surface_t; typedef struct _cairo_xcb_picture cairo_xcb_picture_t; typedef struct _cairo_xcb_shm_mem_pool cairo_xcb_shm_mem_pool_t; typedef struct _cairo_xcb_shm_info cairo_xcb_shm_info_t; +typedef struct _cairo_xcb_resources cairo_xcb_resources_t; struct _cairo_xcb_shm_info { cairo_xcb_connection_t *connection; @@ -199,6 +200,9 @@ struct _cairo_xcb_screen { cairo_list_t link; cairo_list_t surfaces; cairo_list_t pictures; + + cairo_bool_t has_font_options; + cairo_font_options_t font_options; }; struct _cairo_xcb_connection { @@ -236,6 +240,14 @@ struct _cairo_xcb_connection { cairo_list_t link; }; +struct _cairo_xcb_resources { + cairo_bool_t xft_antialias; + int xft_lcdfilter; + cairo_bool_t xft_hinting; + int xft_hintstyle; + int xft_rgba; +}; + enum { CAIRO_XCB_HAS_RENDER = 0x0001, CAIRO_XCB_RENDER_HAS_FILL_RECTANGLES = 0x0002, @@ -357,6 +369,9 @@ _cairo_xcb_screen_get_gc (cairo_xcb_screen_t *screen, cairo_private void _cairo_xcb_screen_put_gc (cairo_xcb_screen_t *screen, int depth, xcb_gcontext_t gc); +cairo_private cairo_font_options_t * +_cairo_xcb_screen_get_font_options (cairo_xcb_screen_t *screen); + cairo_private cairo_status_t _cairo_xcb_screen_store_linear_picture (cairo_xcb_screen_t *screen, const cairo_linear_pattern_t *linear, @@ -773,4 +788,8 @@ slim_hidden_proto_no_warn (cairo_xcb_device_debug_set_precision); slim_hidden_proto_no_warn (cairo_xcb_device_debug_cap_xrender_version); #endif +cairo_private void +_cairo_xcb_resources_get (cairo_xcb_screen_t *screen, + cairo_xcb_resources_t *resources); + #endif /* CAIRO_XCB_PRIVATE_H */ |