VS:SetOrigin

From Vectorworks Developer
Jump to navigation Jump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

.VectorScript|VectorScript ..VS:Function Reference|Function Reference ..VS:Function_Reference_Appendix|Appendix

Description

Shifts the position of the document origin. The function does not modify the relative

positions of objects in the document; the coordinate locations of objects, however, will change when the origin location is modified.

PROCEDURE SetOrigin(
x :REAL;
y :REAL);
def vs.SetOrigin(x, y):
    return None

Parameters

x REAL X-offset from current origin.
y REAL Y-offset from current origin.

Remarks

The difference between this and VS:SetOriginAbsolute is that this call shifts the origin the specified amount, where [{VS:SetOriginAbsolute]] sets the origin to the specified values.

See the <a href=http://www.vectorlab.info/index.php?title=Absolute_Origin>VectorLab article</a> on origins by Gerard Jonker.

Example

VectorScript

Rect(0,0,1,1);
SetOrigin(1,1);

{ Creates a rectangle with the bottom left point at coordinates (0,0), then moves the origin so that the top right point of the rectangle has coordinates (0,0). }

Python


Version

Availability: from All Versions

See Also

VS Functions:

VS:SetOriginAbsolute

VS Functions: [[VS:SetOriginAbsolute]]