containsXy method

bool containsXy(
  1. double x,
  2. double y, {
  3. double margin = 0,
})

Determine whether the rectangle contains the specified point (in the PDF page coordinates).

Implementation

bool containsXy(double x, double y, {double margin = 0}) =>
    x >= left - margin && x <= right + margin && y >= bottom - margin && y <= top + margin;