return intersects(r.getX(), r.getY(), r.getWidth(), r.getHeight());
if (w <= 0 || h <= 0) return false; double x1 = getX1(); double y1 = getY1(); double x2 = getX2(); double y2 = getY2();  if (x1 >= x && x1 <= x + w && y1 >= y && y1 <= y + h) return true; if (x2 >= x && x2 <= x + w && y2 >= y && y2 <= y + h) return true;  double x3 = x + w; double y3 = y + h;  return (linesIntersect(x1, y1, x2, y2, x, y, x, y3) || linesIntersect(x1, y1, x2, y2, x, y3, x3, y3) || linesIntersect(x1, y1, x2, y2, x3, y3, x3, y) || linesIntersect(x1, y1, x2, y2, x3, y, x, y));
  public boolean intersects(Rectangle2D r)  {		return intersects(r.getX(), r.getY(), r.getWidth(), r.getHeight());	}