Nathan Pruett wrote:For a button, the majority of those are just method calls, as opposed to having to implement "button-like" features in a JLabel or JPanel. Here's a quick example of making a JButton into a "Link" - the only part I had to implement was to rollover to change the text color:
Hello Nathan,
This is a great Peice of code which I could also use to make my Jbutton to look like a hyperlink. On Click of the Hyperlink I would need to open up a Dialog. However I need to have some tweaks in here. The Label on the JButton should show a Hand Cursor when Hovered upon my Mouse Enter and Mouse Exit to the Normal Curson. How do I get the Hand Cursor
Regards,
Hemanth
Update: I got it.. Just Added
setCursor(Cursor.getPredefinedCursor(Cursor.HAND_CURSOR)); in mouseEntered. But Nathan, Thanks for the Code. Neat Stuff.