Re: [PATCH] xcb: Initialize font options from Xft resources
Uli Schlachter <[email protected]>
| Newsgroups | gmane.comp.lib.cairo |
|---|---|
| Message-ID | <[email protected]> |
Hi, Am 12.09.2014 um 10:42 schrieb Lukáš Lalinský: > On Fri, Sep 12, 2014 at 9:46 AM, Lukáš Lalinský <[email protected]> wrote: >>>> + *options = *_cairo_xcb_screen_get_font_options >>>> (surface->screen); >>> >>> Still requires a pair of _cairo_xcb_connection_acquire() / >>> _cairo_xcb_connection_release() somewhere. Cairo-xlib does this in >>> _cairo_xlib_screen_get_font_options(), but you put an assert into >>> _cairo_xcb_screen_get_font_options() making this the caller's >>> responsibility. Either place is fine with me to do the necessary >>> locking. >> >> Thanks, I was not completely clear on how to do this before. I added it >> to _cairo_xcb_surface_get_font_options, as that seems consistent with the >> rest of the XCB code. > > Ok, I changed my mind already, because I realized how often the function is > called. _cairo_xcb_screen_get_font_options inside the cache-miss-if seems > to be a better place for that. I'll ignore the possible races here, because they shouldn't have any bad effects and because cairo-xlib does the same. I fixed up the spaces for indentation in cairo-xcb-resources.c and pushed the result as commit e691d242d592. Thanks a lot for working on this and sorry for being so pedantic. Cheers, Uli -- "In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move." -- cairo mailing list [email protected] http://lists.cairographics.org/mailman/listinfo/cairo