Send this to a friend
1 Insets noInsets = new Insets(0,0,0,0);
2 ImageIcon bg = new ImageIcon("bt1.png");
3 JButton btn = new JButton(bg);
4 btn.setBounds(0,0,32,32);
5 btn.setMargin(noInsets);
6 btn.setBorder(BorderFactory.createEmptyBorder());
7 btn.setContentAreaFilled(false);
Insets noInsets = new Insets(0,0,0,0);
ImageIcon bg = new ImageIcon("bt1.png");
JButton btn = new JButton(bg);
btn.setBounds(0,0,32,32);
btn.setMargin(noInsets);
btn.setBorder(BorderFactory.createEmptyBorder());
btn.setContentAreaFilled(false);