| Article | 70002843 |
| Type | Wish |
| Product | WebJS |
| Date Added | 2/12/2026 12:00:00 AM |
| Fixed | 12.0.01 (2/12/2026 12:00:00 AM) |
| Submitted by | VectorDraw Team |
Summary
Support grips for Dimension objects in webControl
Solution
In version 12.0.01
Dimensions that supported by VDS also supports grips
Note:Supported dimensions can be tested with vddimmanager IsVDSdim method, they are usually linear rotated or aligned dimensions with UsingDefaultTextPosition property false
Example add a line and a dimension from line end points ,
put them together into a selection group.
As a result clicking on one of the entities , grips for both figures are enable and moving the grips of the endpoint both objects modified
//ensure enable grips
vdcanvas.GripManager.Enable = true;
vdcanvas.GripManager.SelectMode = vdConst.GRIPMODE_AUTO;
//ensure enable groups
vdcanvas.GroupsManager.IgnoreGroups = false;
var line1 = vdcanvas.AddLine([-4, -4, 0], [4, 4, 0], true);
vdcanvas.GroupsManager.AddItem("group1", line1);
//create the dimension object over line end points
var dimstyle = new vddimmanager();
dimstyle.TYPE = 'ALIGN';
dimstyle.BLK = 'ARROW';
dimstyle.TEXTH = '0.4';
dimstyle.PREC = '5';
dimstyle.SZEROS = '0';
var firstPoint = line1.StartPoint;//the first point of the line
var endPoint = line1.EndPoint;//the end point of the line
var rotation = vdgeo.GetAngle(firstPoint, endPoint);//the rotation between the two points
var polar = vdgeo.pointPolar(firstPoint, rotation + vdgeo.HALF_PI, 0.6);//find the point of the dimension
var dim = dimstyle.Create(vdcanvas, firstPoint, endPoint, polar, '');//the dimension will be added in the entities of the layout
vdcanvas.GroupsManager.AddItem("group1", dim);
setTimeout(vdcanvas.redraw);
