setLength()
Set the line's length.
line.setLength(length)
Keeps the first end and the direction fixed, and moves the second end so the line is the given length.
Parameters
line.setLength(length)
| Parameter | Type | Default | Description |
|---|---|---|---|
length |
int or float |
required | The new length, in pixels. |