Skip to content

Latest commit

 

History

History
52 lines (42 loc) · 1.26 KB

File metadata and controls

52 lines (42 loc) · 1.26 KB

GetGradientSpotPosition

Description

Gets the spot position of the specified gradient segment.

PROCEDURE GetGradientSpotPosition(
				gradient     : HANDLE;
				segmentIndex : INTEGER;
				VAR position : REAL);
def vs.GetGradientSpotPosition(gradient, segmentIndex):
    return position

Parameters

Name Type Description
gradient HANDLE Gradient that contains the segment.
segmentIndex INTEGER Segment from which to get the data.
position REAL Position of the segment's color spot relative to left-most point of the gradient.

Examples

VectorScript

GetGradientSpotPosition(gradientHandle, 4, spotPosition);

Python

spotPosition = vs.GetGradientSpotPosition(gradientHandle, 4)
GetGradientSpotPosition(gradient, 1, 1.0);
import vs

# Gets the spot position of the specified gradient segment.
gradient = vs.FSActLayer()  # handle to the first selected object on the active layer
segmentIndex = 1

result = vs.GetGradientSpotPosition(gradient, segmentIndex)

Version

Availability: from VectorWorks10.0

Category