object

GradientBasicGeometry

Gradient geometry defines much of the appearance of the gradient within the path.

Properties
PropertyTypeRequired
classconstRequired
flagintegerRequired
xOriginnumberRequired
yOriginnumberRequired
anglenumberRequired
lengthnumberRequired
matrixMatrixRequired
widthRationumberRequired

class

Required

Description

no description

Type

const

Value

constant: the value of this property must be equal to:

json
"gradientBasicGeometry"

flag

Required

Description

This argument defines how the gradient will be rendered.For simple filled paths, flag takes the value 1.

Type

integer

Value

enum: the value of this property must be equal to one of the following values:

ValueExplanation
0Do not issue a clip.
1Issue a clip.
2Disable rendering.

xOrigin

Required

Description

xOrigin and yOrigin give the origin of the gradient in page coordinates. The origin can be located anywhere on the artwork, and corresponds to 0 on the gradient ramp.

Type

number

yOrigin

Required

Description

Refer to xOriginal for details.

Type

number

angle

Required

Description

This argument specifies the direction of the gradient vector, in degrees. The gradient ramp extends from the origin at the value of angle, which is measured counterclockwise from the x axis.

Type

number

length

Required

Description

This argument specifies the distance over which the gradient ramp is applied. The ramp will be scaled so that its 100% value is the end of the length. This parameter may be greater than 1.

Type

number

matrix

Required

Description

The six values make up a transformation matrix. When a gradient is first applied to an object, these values are the identity matrix. If the user transforms the object, the user transformation matrix is concatenated to the gradient instance’s matrix.

Type

Matrix

widthRatio

Required

Description

0.5 Indicates that the width is half the length. 2 Indicates that the width is twice the length. and so on.

Type

number

Daruma Feedback