//Purpose: This applet simply creates a checkbox component import java.awt.*; import java.applet.*; import java.awt.event.*; public class test12c extends Applet{ //Set background to yellow, public void init() { setBackground(Color.yellow); setFont(new Font("Helvetical", Font.BOLD, 12)); setLayout( new FlowLayout(FlowLayout.LEFT)); add(new Checkbox("Red", true)); add(new Checkbox("Red")); add(new Checkbox("Green")); add(new Checkbox("Blue")); add(new Checkbox("Pink")); } //Paint the current key at the current position public void paint(Graphics g) { //set drawing color g.setColor(Color.red); } }