This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Swing / AWT / SWT and the fly likes Help w/ custom JButton Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "Help w/ custom JButton" Watch "Help w/ custom JButton" New topic

Help w/ custom JButton

Tom Collins

Joined: Mar 13, 2006
Posts: 10
I am still somewhat new to Java and I am trying to make some custom shaped buttons. I have about 30 various "invisible" buttons I am trying to make. I have figured out how to resize and make invisible a normal JButton, but now I need to make some odd shaped buttons.

I would perfer to make the shape (basically the border) in photoshop and then turn that picture into a clickable button. I think that the shapes might be a little to difficult to draw in Java. One thing I would like to duplicate from my invisible JButtons is the ablility to show a doubled border when the mouse rolls over the button.

The code I'm using to make the Jbuttons invisible is:
but the border is NOT set to null.

I would appriciate any suggestions that you may have.

Tom Collins

Me fail english?! That's unpossible!
subject: Help w/ custom JButton
Similar Threads
BoxLayout - JButton size
JButton with bad Labels
Help adding JButton to a JPanel from another method!
JToggleButton background color
JButtons icon