aspose file tools*
The moose likes Swing / AWT / SWT and the fly likes java swing Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "java swing" Watch "java swing" New topic
Author

java swing

puneetRatikon agarwal
Greenhorn

Joined: Jul 15, 2009
Posts: 3
how to change JButton background color???
Rob Spoor
Sheriff

Joined: Oct 27, 2005
Posts: 19670
    
  18

http://faq.javaranch.com/java/UseAMeaningfulSubjectLine. This sub forum is almost entirely about Java and Swing - the AWT, SWT and JFace threads are practically absent compared to the Swing threads.

Try checking the API: javax.swing.JButton. You search for something like "background". You find nothing declared by JButton itself, but wait! there is a method called setBackground in JComponent. And lo and behold:
Sets the background color of this component.


SCJP 1.4 - SCJP 6 - SCWCD 5 - OCEEJBD 6
How To Ask Questions How To Answer Questions
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: java swing