The major issue is that I disabled the clipping region. My debugging revealed that when the dimensions of the clipping rectangle translate to non-integral numbers of pixels, cairo fails to translate this rectangle into a pixman region in _cairo_traps_extract_region, and instead uses some fallback code that doesn’t support subpixel rendering. BTW, I wonder if this fallback code is also a performance problem...
I'm not familiar enough with Cairo to say what should be done about this, but maybe this will give someone else ideas.
Here is a proof-of-concept kludge. It’s a ~10 line patch that forces subpixel rendering in the cairo backend: anders. kaseorg. com/pub/ patches/ poppler- subpixel. patch>
<http://
The major issue is that I disabled the clipping region. My debugging revealed that when the dimensions of the clipping rectangle translate to non-integral numbers of pixels, cairo fails to translate this rectangle into a pixman region in _cairo_ traps_extract_ region, and instead uses some fallback code that doesn’t support subpixel rendering. BTW, I wonder if this fallback code is also a performance problem...
I'm not familiar enough with Cairo to say what should be done about this, but maybe this will give someone else ideas.