This example uses two rectangles A and B to demonstrate the functions of each method of the System.Drawing.Region class.
Draw two rectangles

Get the part of the target rectangle that does not intersect with this Region
Get the part of this Region that does not intersect with the target rectangle

##Get the intersection of the two rectangles

Get the union of two rectangles

Get the disjoint parts of the union of two rectangles

Initialize this System.Drawing.Region

Display RegionData information

The above is the detailed content of Method usage of C# System.Drawing.Region class (illustration). For more information, please follow other related articles on the PHP Chinese website!