Skip to content

Latest commit

 

History

History
39 lines (30 loc) · 859 Bytes

File metadata and controls

39 lines (30 loc) · 859 Bytes

GetNumGradientSegments

Description

Gets the number of segments in the gradient.

FUNCTION GetNumGradientSegments(gradient : HANDLE): INTEGER;
def vs.GetNumGradientSegments(gradient):
    return INTEGER

Parameters

Name Type Description
gradient HANDLE The gradient from which to get the number of segments.

Remarks

Note: a gradient must always have at least 2 segments.

This also returns the number of levels in a hatch definition, like [{VS:GetObjectVariableInt]](HatchDefH, 660).

Examples

VectorScript

numSegments := GetNumGradientSegments(gradientHandle);

Python

numSegments = vs.GetNumGradientSegments(gradientHandle)

Version

Availability: from VectorWorks10.0

Category