void (JComponent c, Graphics2D g2) { g2.setColor(c.isEnabled() ? c.getBackground() : UIManager.getColor("Button.background")); if (!c.isEnabled()) { g2.setComposite(AlphaComposite.getInstance(AlphaComposite.SRC_OVER, 0.35f)); } Rectangle r = new Rectangle(c.getSize()); JBInsets.removeFrom(r, JBUI.insets(2)); adjustInWrapperRect(r, c); g2.fill(r); }