pointOnLineClosestTo method

Coord pointOnLineClosestTo(
  1. Coord point
)

Implementation

Coord pointOnLineClosestTo(Coord point) {
  final perpLine = Line.fromSlopePoint(slope.perpendicular, point);
  return intersect(perpLine)!;
}