[cairo] Getting mozilla-specific changes merged in

Robert O'Callahan rocallahan at novell.com
Thu May 18 01:47:04 PDT 2006

I have a question about the cairo_get_clip_as_rectangles API: should the
returned rectangles be in user space or device space?

User space is more consistent with the rest of the cairo API. But
returning rectangles in device space would let us return useful
rectangles in strictly more cases.

To elucidate: as currently implemented, we can only return rectangles if
the clip is a union of pixel-aligned rectangles in device space. If
transforming those rectangles to user space produces rectangles that are
no longer axis-aligned, then we will just have to bail out saying
"sorry" (or we could change cairo_rectangle_t to specify
non-axis-aligned rectangles, but I'm not sure if that's desirable, nor
the best way to do it). On the other hand, if the clip rectangles are
axis-aligned in user space but not in device space, then we still can't
return anything useful in user coordinates because we won't have a
rectangle list in the internal clip data to start with.


More information about the cairo mailing list