Procedure SetOriginAbsolute sets the position of the origin relative to the center of the document drawing space.
PROCEDURE SetOriginAbsolute(
xValue : REAL;
yValue : REAL);def vs.SetOriginAbsolute(xValue, yValue):
return None| Name | Type | Description |
|---|---|---|
| xValue | REAL | X coordinate of origin. |
| yValue | REAL | Y coordinate of origin. |
The difference between SetOrigin and SetOriginAbsolute is that SetOrigin shifts the origin the specified amount, where SetOriginAbsolute sets the origin to the specified values.
See the VectorLab article on origins by Gerard Jonker.
BEGIN
GetOrigin (x0, y0);
SetOriginAbsolute (0, 0);
kToolCompleteEventID: BEGIN
IF ResourceIsOK THEN
ptMode := kPolyPointTool;
GetOrigin(origin.x, origin.y);
SetOriginAbsolute(0, 0);
sheetLayerH := ActLayer;
bSheetLayer := FALSE;
IF (sheetLayerH <> nil) & (GetObjectVariableInt(sheetLayerH, 154) = 2) THEN BEGIN
boo := GetSheetLayerUserOrigin(sheetLayerH, sheetOrigin.x, sheetOrigin.y);
Layer(LayerChStr);
MyLayerScale := GetLScale(ActLayer);
END;
GetOrigin(Xo,Yo);
SetOriginAbsolute(0,0);
PlaceWorksheet;
SetOriginAbsolute(Xo,Yo);
IF MaxError THEN AlrtDialog(kStrMaxError);
IF DisplayErrorMessage THEN AlrtDialog(kStrOverlap);import vs
# Procedure SetOriginAbsolute sets the position of the origin relative to the
# center of the document drawing space.
xValue = 1.0
yValue = 2.0
vs.SetOriginAbsolute(xValue, yValue)VS Functions: SetOrigin
Availability: from VectorWorks8.0