r.translate(0, (int) r.getHeight());
r.translate(0, (int) r.getHeight() - 1);
  public int getLastVisibleIndex()  {    ComponentOrientation or = getComponentOrientation();    Rectangle r = getVisibleRect();    r.translate(0, (int) r.getHeight());    if (or == ComponentOrientation.LEFT_TO_RIGHT)      r.translate((int) r.getWidth(), 0);    return getUI().locationToIndex(this, r.getLocation());        }