Joining 2D polygons into a single outline with REGION and UNION
You have several adjoining plots, two overlapping buildings, or a part drawn as a rectangle and a circle, and you need one single outline: to measure the total area, to get the outer perimeter, or to dimension without interior lines. Drawing it by hand is slow and error-prone. AutoCAD's region commands do it in two steps, and they work the same way in LinceCAD.
1. Turn the polygons into regions with REGION
A region is a closed flat surface. REGION (alias REG) converts into regions:
- closed polylines, circles, ellipses and closed splines;
- also lines, arcs and open polylines that touch at their endpoints until they close an area.
Enter REGION, select the objects and press Enter. LinceCAD reports how many loops it found and how many regions it
created. Each region takes the layer, colour and linetype of the curve it came from, and the source objects are deleted,
unless the DELOBJ variable is 0, which keeps them.
Two important details:
- A closed curve inside another gives two independent regions, not one region with a hole. You make the hole by subtracting (section 3).
- Lines that cross without meeting at their endpoints, or that do not close, form no region and are left as they were.
To extract the area from a drawing like that use
BOUNDARY(aliasBO) with the Region object type: it asks for a point inside the area.
2. Join them with UNION
UNION (alias UNI) merges regions in the same plane into one:
- Enter
UNION. - Select two or more regions and press Enter.
- Overlapping regions merge into a single outline, without the interior lines, and islands are kept.
The source regions are always deleted (DELOBJ does not apply here) and the result takes the properties of the first one
selected, so pick first the one with the layer and colour you want. If there are fewer than two regions in the same
plane, the command warns you and changes nothing. Loose polylines do not work: convert them with REGION first.
If the regions do not touch, the result has several separate pieces: LinceCAD leaves one region per piece (AutoCAD makes a
single region with several faces; EXPLODE splits it into the same pieces).
3. Subtract and intersect
With the same regions you can do more:
SUBTRACT(aliasSU): select the base region, press Enter, select the ones to subtract and press Enter. Use it to make a hole: the inner area becomes an island. As a shortcut, if you select two or more in the first step and press Enter, the first is the base. The result keeps the base's properties.INTERSECT(aliasIN): keeps only the common part.
Limits worth knowing
- The regions must be in the same plane, parallel to XY.
- Arcs, circles, ellipses and splines are processed as a fine polygon (half a degree). The area matches AutoCAD's to more than four digits, but the final outline is segments, not arcs.
- The same commands also unite, subtract and intersect 3D solids; this guide covers only the 2D side.
Summary: which command for what
| I want to… | Command |
|---|---|
| Convert closed curves into regions | REGION (REG) |
| Extract an area from loose lines | BOUNDARY (BO) |
| Merge regions into a single outline | UNION (UNI) |
| Make a hole or cut out a shape | SUBTRACT (SU) |
| Keep the common part | INTERSECT (IN) |
| Go back to segments | EXPLODE (X) |
If you are weighing a switch from AutoCAD, the AutoCAD-compatible CAD checklist shows what else behaves the same.
Frequently asked questions
Why won't UNION join my polylines?
Because in 2D UNION only works on regions. Convert closed polylines with REGION first, then run UNION; it is the same workflow as in AutoCAD.
What happens to the original objects?
REGION deletes them unless DELOBJ is 0. UNION, SUBTRACT and INTERSECT always delete the source regions and leave a new one with the properties (layer, colour) of the first one selected.
Can I get a polyline back?
Explode the region with EXPLODE: it comes out as segments. For a single-stroke polyline, use BOUNDARY on the enclosed area first, with the Polyline type.
Do circles and arcs stay arcs after a union?
No: in LinceCAD they are processed as a very fine polygon (half a degree). The area matches AutoCAD's to more than four digits, but the result is broken into segments.
Try LinceCAD for 30 days with your own drawings. Downloads · See pricing · UNION in the manual.