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

Keith Packard keithp at keithp.com
Wed May 26 07:53:43 PDT 2010


On Wed, 26 May 2010 10:10:49 -0400, Peter Harris <pharris at opentext.com> wrote:

> Oooo. An invitation to bikeshed.

Always a fun time!

> s/mi/dix/g instead of s/mi//g? Probably overkill for a single
> collision.

I'm hoping to eliminate the dix prefix used elsewhere; it's just noise.

> Alternatively, Soeren suggested RegionContainsRect upthread. (I can also
> see RegionOverlapsRect, as the function returns partial overlap results
> too.)

RectIn                  <- shortest, but doesn't reference "Region"
                           at all.

RegionInRect            <- shorter, still follows argument order,
                           but very misleading about return value

RectContainsRegion      <- replacing 'in' with 'contains', but
                           even more misleading about argument order.

RegionContainsRect      <- Gets the argument order right, and seems
                           to have the right semantic connotation.

Should we rename TranslateRegion to RegionTranslate? And
RegionFromBitmap? Are there other functions that I'm missing still?

-- 
keith.packard at intel.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://lists.x.org/archives/xorg-devel/attachments/20100526/adc9b8cb/attachment.pgp>


More information about the xorg-devel mailing list