int insetsH = insets.top + insets.bottom; int insetsW = insets.left + insets.right; if (!comboBox.isEditable())
Insets arrowInsets = b.getInsets(); Insets comboInsets = comboBox.getInsets(); Icon icon = b.getComboIcon(); d.width += comboInsets.left + comboInsets.right; d.width += arrowInsets.left + arrowInsets.right; d.width += arrowInsets.right + icon.getIconWidth(); d.height += comboInsets.top + comboInsets.bottom; d.height += arrowInsets.top + arrowInsets.bottom; } else if (comboBox.isEditable() && arrowButton != null && editor != null)
  public Dimension getMinimumSize(JComponent c)  {    Dimension d = getDisplaySize();    MetalComboBoxButton b = (MetalComboBoxButton) arrowButton;    Insets insets = b.getInsets();    int insetsH = insets.top + insets.bottom;    int insetsW = insets.left + insets.right;    if (!comboBox.isEditable())      {        Icon icon = b.getComboIcon();    int iconWidth = icon.getIconWidth() + 6;        return new Dimension(d.width + insetsW + iconWidth, d.height + insetsH);      }    else      // FIXME: the following dimensions pass most of the Mauve tests, but      // I don't yet understand the logic behind this...it is probably wrong      return new Dimension(d.width + insetsW + (d.height + insetsH) - 4,           d.height + insetsH + 1);  }