[cairo] Surface error not set when using cairo_show_text() with invalid utf8
cairouser at yahoo.com
Tue Nov 2 06:16:28 PDT 2010
I can see you gave this some thought :)
I fully agree - there is little reason for drawing surface to become
*completely unusable* because there was an erroneous character in utf8
text somewhere. It's a *big* problem for us, since we don't always
control the text.
Any time a bad utf8 character comes up - all rendering is lost until
the next iteration. I had to add (at expense of wasted CPU cycles) a
utf8 check, essentially similar to what's inside cairo, to catch some
of the more obvious problems before they go into cairo text rendering.
However, due to complexity of data inputs it is not possible to verify
all incoming text. It would be great if cairo handling of utf8 errors
was more lenient (as in - ignore it and keep drawing).
Bill Spitzak wrote:
> PLEASE do not make UTF-8 errors stop any output!
> A lot of deluded systems engineers think doing this will "force people
> to use Unicode correctly". But it does not, in fact it does the exact
More information about the cairo