[cairo] Creating CMYK and spot colors using Postscript backend

Craig Ringer craig at postnewspapers.com.au
Tue May 15 12:19:55 PDT 2007


Bill Spitzak wrote:
> Craig Ringer wrote:
>> Bill Spitzak wrote:
>>
>>> In general, throwing errors or producing no output makes graphics
>>> programs extremely fragile and bug-prone and should never be done if at
>>> all possible. Another example is that poorly-formed UTF8 should draw as
>>> many glyphs as possible and must always draw a box or something for
>>> every erroneous byte.
>>
>> In both those cases, as an application developer I'd be happy if the
>> graphics code produced output (even bad output) - but *told* me that it
>> was incorrect. However, it'd be extremely frustrating to have silent
>> failures and mis-rendering.
> 
> Yes I agree, if you could query Cairo and have it tell you if something
> went wrong, that would be very useful. However it should still do the
> best-effort output and it should not prevent further rendering calls
> from working. Ie. an error can turn on an error flag but this has no
> other effect other than making the error query return true.

That sounds sensible to me, especially if you can query for more
information about the error, or ideally get a full list of errors after
rendering is complete.

--
Craig Ringer



More information about the cairo mailing list