[cairo] Adding a boolean type

Keith Packard keithp at keithp.com
Tue Feb 1 00:27:34 PST 2005


Around 19 o'clock on Jan 31, Owen Taylor wrote:

> char vs. int: For Glib we picked int, to reduce the risk of
>   'GBoolean bool = flags & FLAG' traps, but mostly it doesn't matter,
>   and char seems to be more common in general.

I'd rather use 'int' -- I recall several mysterious problems in Xt 
resulting from the use of 'char' in that library.

>  CAIRO_FALSE vs. FALSE: For GLib, FALSE/TRUE are pretty much the 
>    only exception's to the namespace. We do:

Fwiw, Fontconfig uses FcFalse and FcTrue.  I have a slight preference for
the qualified names, but CAIRO_ is a lot longer than Fc...

-keith


-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 228 bytes
Desc: not available
Url : http://lists.freedesktop.org/archives/cairo/attachments/20050201/a05c2829/attachment.pgp


More information about the cairo mailing list