How to give a JButton both an ImageIcon and background color?
<p>Is there a way to do both</p>

<pre><code>button.setBackground(Color.green.darker());
</code></pre>

<p>and </p>

<pre><code>button.setIcon(new ImageIcon(buttonImg.getScaledInstance(15, 15, Image.SCALE_SMOOTH)));
</code></pre>

<p>so that both the image and the background color are visible? Is there some sort of transparency setting on the button's image that I'm missing? Any help would be greatly appreciated.</p>

<p>EDIT:</p>

<p>Here is the image I'm trying to use. As you can see, it has transparency.
<a href="http://www.clipartlord.com/wp-content/uploads/2013/09/bomb3.png" rel="nofollow">http://www.clipartlord.com/wp-content/uploads/2013/09/bomb3.png</a></p>

<p>What I am trying to get is the image to show up on the Button with the background color of green filling in the transparency. Right now when I try to do it, if I add the image at all, the background color is not visible whatsoever. But if I don't add the image, the background color is visible. I hope this helps.</p>