constructor(stroke, opacity, [x], [y], [point1], [point2])

Class: Line.

Description:

Creates an instance of a Line shape.

Parameters:

Name Type Default Description

stroke

Stroke

A border of the shape.

opacity

number

1

Opacity of the shape (0 to 1).

[x]

number

0

Horizontal position from the left edge.

[y]

number

0

Vertical position from the top edge.

[point1]

number

An object with X and Y coordinates {x: number, y: number}.

[point2]

number

An object with X and Y coordinates {x: number, y: number}.