| Article | 70002482 |
| Type | Wish |
| Product | Engine |
| Date Added | 2/26/2024 12:00:00 AM |
| Fixed | 11.1.3.0 (2/26/2024 12:00:00 AM) |
| Submitted by | Schell Thomas |
Summary
Wish to have a method to calculate the outer boundary of some entities
Solution
In version 11.1.3 we have implemented and exported two methods in the commandAction of the Document like below
summary> Calculates the outer boundary of a given selection and a point inside the closed area.
param name="SelSet">A selection of vdFigures (see
|
Some entities that we want to calculate the outer boundary (lines , arcs , polyline with bulges) |
Outer Boundary |
|
|
|
Some entities that we want to calculate the inner boundary (lines , arcs , polyline with bulges) |
Inner Boundary |
|
|
|
|
Or in the menu under Modify-> Boundary
C# Code
Vertexes verts = doc.CommandAction.FindOutBoundCurve(null);
if (verts != null && verts.Count > 0)
{
//Create a thick red polyline to see the result
VectorDraw.Professional.vdFigures.vdPolyline result = new vdPolyline(doc);
result.PenColor.ColorIndex = 0;
result.LineWeight = VdConstLineWeight.LW_158;
result.VertexList = new Vertexes(verts);
doc.Model.Entities.AddItem(result);
doc.Redraw(true);
}
