contains method
Tests to see if the given point is within the path. (That is, whether the point would be in the visible portion of the path if the path was used with Canvas.clipPath.)
The point
argument is interpreted as an offset from the origin.
Returns true if the point is in the path, and false otherwise.
Implementation
bool contains(Offset point) {
assert(_offsetIsValid(point));
return _contains(point.dx, point.dy);
}