graphinglib.Polygon.create_symmetric_difference#

Polygon.create_symmetric_difference(other: Self, copy_style: bool = False) list[Self][source]#

Returns the symmetric difference of the polygon with another polygon.

In general, this can create more than one polygon, so the result is returned as a list of polygons even if there is only one.

Parameters:
otherPolygon

The other polygon to find the symmetric difference with.

copy_stylebool, optional

If True, the current polygon’s parameters are copied to the new polygon. If False, the new polygon will have default parameters. Default is False.

Returns:
list[Polygon]

A list of polygons resulting from the symmetric difference.