Prevously all show_text_glyphs() clusters were using ActualText. This
fixes that.
I have a feeling that the following scenario is broken still though:
- show_text_glyphs maps glyph 1 to some utf8 text different from
what index_to_ucs4 will give for glyph 1. This will assign the
utf8 text to glyph 1's ToUnicode.
- show_glyphs shows glyph 1. Since cluster has no utf8 text, we
won't use ActualText and fall back to ToUnicode. But the ToUnicode
value assigned to glyph 1 is non-standard now. We should use
ActualText.
I have not verified this hypothesis though.
And update user-font text_to_glyphs() method to match.
Currently disable the win32-font text_to_glyphs(), until that one
is updated. Or better yet, remove it and implement ucs4_to_index().
It's the toy font API afterall.
The init func does not actually need to draw anything, but having a cairo_t
similar to that passed to render_glyph is handy for computing font extents.
This is because cairo makes doing some things really hard (if not impossible)
without a cairo_t.
The user-font-proxy test case is a great example of how the added cairo_t
makes life much easier.
When popping a group, transform it by the ctm centered at the origin
specified by the device_transform so that it ends up in the right place
when we try to paint. This fixes the regressions caused by
1a9809baab as shown by the pdf backend.
Adding warn_unused_result to pixman detected a couple of instances where
we abused the knowledge that the code currently can not fail, but in
deference to its independent existence we should be more cautious.
Keep the reference count as zero for temporary, on-stack patterns in
order to detect attempts to keep references beyond their scope. (And
mismatched _init()/_destroy()).
No idea if Ubuntu will ever learn not to modify public API of
common libraries without any clue of what kind of problems they
create by doing that. They could very well define
FC_UBUNTU_LCD_FILTER if they wanted to, but no, they defined
FC_LCD_FILTER as if it's an upstream thing. It wasn't.
This makes cairo_scaled_font_glyph_extents() match a similar pattern of
initialization in cairo_glyph_extents(). It also fixes the 'text-zero-len' test
that was broken by 676b221326.
because pdfTeX (and maybe other PDF consumers) can not handle it.
Previously the content stream was an Form dictionary because at the
time the content is written it is not known whether the content stream
will be belong to the page or be an XObject in a knockout group. With
the additional of the paginated surface function
set_fallback_images_required() this information is now known at the
time the content is emitted.