Originally Posted by Eranga
|
The way serjant explain is really nice.
On the other way, which I explain you can use labels easily on the frame, and add images to those labels. That's the most easiest way I can see.
|
I have already tried it but Two problem with Label is:-
1. We can not select JLable
2. Text/Caption is not appearing at the bottom of Image Label however text position property is set.
|
Quote:
|
Use a GridLayout with JButtons that have setContentAreaFilled(false) and setBorderPainted(false). You may also want to setRolloverEnabled(false).
Set an icon and text to each button, and setHorizontalTextPosition(SwingConstants.CENTER) / setVerticalTextPosition(SwingConstants.TOP)
|
Thanks Burke, I will try it; I hope JButton is best to solve my problem and your idea will work.