Point2D location = getLocation(null); Rectangle2D bounds = new Rectangle2D.Double(location.getX() - WIDTH / 2, location.getY(), WIDTH, HEIGHT);    return bounds;
Point2D location = getLocation(); return new Rectangle2D.Double(location.getX() - WIDTH / 2, location.getY(), WIDTH, HEIGHT);
  public Rectangle2D getBounds()  {    Point2D location = getLocation(null);    Rectangle2D bounds = new Rectangle2D.Double(location.getX() - WIDTH / 2, location.getY(), WIDTH, HEIGHT);    //bounds.x = bounds.x - WIDTH / 2;    //bounds.width = WIDTH;    //bounds.height = HEIGHT;    return bounds;  }