Site hosted by Angelfire.com: Build your free website today!
 

Example 2

Add code to process the fontColor parameter:

    Color fontColor; // add an instance field member
    ....
    public void init() {
        String color = getParameter("fontColor");
        if (color == null || color.length() == 0)
            color = "800080";
        fontColor = new Color(Integer.parseInt(color, 16));
        setGUI();
    }
    ....
    public void setGUI() {
        ....
        button1.setForeground(fontColor);
        button2.setForeground(fontColor);
        ....
    }