Documented GVF_SAVE_VAR alongside other flags, and removed a query/doubt
[AROS.git] / rom / graphics / xorrectregion.c
blob746fd960441a6193ce16314726dd7e58977430fb
1 /*
2 Copyright © 1995-2001, The AROS Development Team. All rights reserved.
3 $Id$
5 Desc: Graphics function XorRectRegion()
6 Lang: english
7 */
8 #include "graphics_intern.h"
9 #include <graphics/regions.h>
10 #include "intregions.h"
12 /*****************************************************************************
14 NAME */
15 #include <proto/graphics.h>
17 AROS_LH2(BOOL, XorRectRegion,
19 /* SYNOPSIS */
20 AROS_LHA(struct Region *, Reg, A0),
21 AROS_LHA(struct Rectangle *, Rect, A1),
23 /* LOCATION */
24 struct GfxBase *, GfxBase, 93, Graphics)
26 /* FUNCTION
27 Exclusive-OR the given rectangle to the given
28 region
30 INPUTS
31 region - pointer to a region structure
32 rectangle - pointer to a rectangle structure
34 RESULT
35 TRUE if the operation was successful, else FALSE
36 (out of memory)
38 NOTES
39 All relevant data is copied, you may throw away the
40 given rectangle after calling this function
42 EXAMPLE
44 BUGS
46 SEE ALSO
47 AndRectRegion(), OrRectRegion(), ClearRectRegion()
49 INTERNALS
51 HISTORY
52 27-11-96 digulla automatically created from
53 graphics_lib.fd and clib/graphics_protos.h
54 19-01-97 mreckt intital version
56 *****************************************************************************/
58 AROS_LIBFUNC_INIT
60 struct Region R;
61 struct RegionRectangle rr;
63 if (IS_RECT_EVIL(Rect)) return TRUE;
65 InitRegion(&R);
67 R.bounds = *Rect;
68 R.RegionRectangle = &rr;
70 rr.Next = NULL;
71 MinX(&rr) = MinY(&rr) = 0;
72 MaxX(&rr) = Rect->MaxX - Rect->MinX;
73 MaxY(&rr) = Rect->MaxY - Rect->MinY;
75 return XorRegionRegion(&R, Reg);
77 AROS_LIBFUNC_EXIT
78 } /* XorRectRegion */