Area.add() - sliptonic/FreeCAD GitHub Wiki

add((shape...), op=0): Add TopoShape(s) with given operation code

  • op(0): 0=Union,1=Difference,2=Intersection,3=Xor,4=Compound. Boolean operation. For the first four operations, see https://goo.gl/Gj8RUu. 'Compound' means no operation, normally used to do Area.sortWires().

The first shape's wires will be unioned together regardless of the op code given (except for 'Compound'). Subsequent shape's wire will be combined using the op code. All shape wires shall be coplanar, and are used to determine a working plane for face making and offseting. You can call setPlane() to supply a reference shape to determine the workplane in case the added shapes are all colinear lines.