void (Rectangle r) { JViewport viewport = ComponentUtil.getParentOfType((Class<? extends JViewport>)JViewport.class, (Component)this); if (viewport != null) { r = SwingUtilities.convertRectangle(this, r, viewport); viewport.scrollRectToVisible(r); } }