documentationfor yFiles for HTML 2.6

Usages of YVector

Method Return Values

toYVector ()in LineSegmentReturns the vector pointing from the first end point to the second end point of the line segment.
add (YVector, YVector)in YVectorAdds two vectors and returns the result.
getNormal (YVector)in YVectorReturns this vector with unit length.
orthoNormal (YVector)in YVectorReturns the vector which is orthogonal to the given one and has unit length.
rotate (number)in YVectorReturns a new YVector instance that is obtained by rotating this vector by the given angle (measured in radians) in clockwise direction (with regards to screen coordinates).
toYVector ()in PointCreates a YVector from a given Point.
getEdgeLabelUpVector (PreferredPlacementDescriptor, Direction)in EdgeLabelOrientationSupportCalculates the up vector of an edge label considering the preferred placement of the label as well as the direction of the edge segment the label is attached to.
getLabelUpVector (number)in EdgeLabelOrientationSupportCalculates the up vector for a label whose right vector is rotated clockwise by the given angle.

Method Parameters

AffineLine (YPoint, YVector)in AffineLineCreates an affine line which is defined by a point and a vector.
calcIntersection (YPoint, YVector, YPoint, YVector)in GeomCalculates the intersection point of two affine lines.
YOrientedRectangle (YPoint, YDimension, YVector)in YOrientedRectangleCreates a new instance using the provided values to initialize anchor, size, and up vector.
YVector (YVector)in YVectorCreates a new vector which is a copy of another vector.
add (YVector)in YVectorAdds a vector to this vector.
add (YVector, YVector)in YVectorAdds two vectors and returns the result.
add (YPoint, YVector)in YVectorAdds the vector to a point and returns the resulting point.
angle (YVector, YVector)in YVectorReturns the angle (measured in radians) between two vectors in clockwise order (with regards to screen coordinates) from v1 to v2.
getNormal (YVector)in YVectorReturns this vector with unit length.
orthoNormal (YVector)in YVectorReturns the vector which is orthogonal to the given one and has unit length.
rightOf (YVector, YVector)in YVectorReturns true if vector v1 is on the right side of v2.
scalarProduct (YVector, YVector)in YVectorReturns the value of the scalar product of two vectors.