drawLine method

void drawLine(
  1. double x1,
  2. double y1,
  3. double x2,
  4. double y2,
)

Draws a line between two coordinates.

Implementation

void drawLine(double x1, double y1, double x2, double y2) {
  moveTo(x1, y1);
  lineTo(x2, y2);
}