blockly > utils > svgPaths > lineTo

utils.svgPaths.lineTo() function

Draw a line from the current point to the end point, which is the current point shifted by dx along the x-axis and dy along the y-axis. These coordinates are unitless and hence in the user coordinate system. See developer.mozilla.org/en-US/docs/Web/SVG/Tutorial/Paths#Line_commands

Signature:

export declare function lineTo(dx: number, dy: number): string;

Parameters

Parameter Type Description
dx number The relative x coordinate.
dy number The relative y coordinate.

Returns:

string

A string of the format ' l dx,dy '