Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Colored buttons on a Mac?



I find making colored buttons very easy on a PC but not on a Mac. If this
was a MRJ fault then there would be complaints all over the Internet. I
can't find any so I must be doing something wrong. I am using MacOS 8.6 or
9.1, CodeWarrior Pro for Java R5 and MRJ 2.2.4. Here is my applet. It
produces a blue button with red writing on a PC but gray writing on a gray
button an a Mac. Does anybody have any ideas?

import java.awt.*;
import java.awt.event.*;
import java.applet.*;

public class OneButton extends Applet {

public void init(){
Button testBut = new Button("BUTTON");
testBut.setBackground(Color.blue);
testBut.setForeground(Color.red);
add(testBut);
}
}




Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.