editingIcon.paintIcon(this, g, 0, 0);
int y = Math.max(0, (getHeight() - editingIcon.getIconHeight()) / 2); editingIcon.paintIcon(this, g, 0, y); }  Color c = getBorderSelectionColor(); if (c != null) { g.setColor(c); g.drawRect(0, 0, getWidth() - 1, getHeight() - 1);
    public void paint(Graphics g)    {          if (editingIcon != null)            {          // From the previous version, the left margin is taken as half          // of the icon width.          editingIcon.paintIcon(this, g, 0, 0);        }      super.paint(g);    }