[PATCH 2/4] Rename region macros to mixed case and remove screen argument

Peter Harris pharris at opentext.com
Wed May 26 08:42:50 PDT 2010


On 2010-05-26 10:53, Keith Packard wrote:
> RegionContainsRect      <- Gets the argument order right, and seems
>                            to have the right semantic connotation.

Looks good.

> Should we rename TranslateRegion to RegionTranslate? And

Yes. (It looks like it already is scheduled to be, as part of your change?)

> RegionFromBitmap?

Also RegionFromRects? Seems stilted compared to RectsToRegion, but that
may just be years of looking at the existing name. It would be one of
the very few Region functions that didn't start with Region.

> Are there other functions that I'm missing still?

The others appear to be:
PrintRegion => RegionPrint
PointInRegion => RegionContainsPoint (for symmetry with Rect)

ValidRegion => RegionValid (or possibly ValidRegion =>
RegionAssertValid, to avoid confusion with RegionValidate)

NullRegion, which I'd rather leave as-is. It scans well along with the
rest of the NullFoo in the server, and the simple RegionNull translation
would collide with the function of the same name.

Your new regionstr.h also declares ClipSpans. Aren't spans an mi
concept? It might be better to leave miClipSpans in mispans.h, and move
the implementation to mispans.c. Or not. Purple!

Peter Harris
-- 
               Open Text Connectivity Solutions Group
Peter Harris                    http://connectivity.opentext.com/
Research and Development        Phone: +1 905 762 6001
pharris at opentext.com            Toll Free: 1 877 359 4866


More information about the xorg-devel mailing list