/**
@author Per Reedtz Thomsen. Copyright (C) 1995 Per Reedtz Thomsen
Based on Rachel Gollub's Original clock Applet.
This program tries to demonstrate the use of parameters in the
Beta interface for Java, while also attempting to be useful.
The applet displays a digital clock. The display can be configured:
Font Family, size, and weight, as well as background and foreground
colors can be controlled from the html page that calls the applet.
The format of the displayed string can be controlled as well, using the
formatting fields from the UNIX date(1) command, with the following
exceptions:
j, u, W, n, t conversions are not supported.
Example of how to call the applet:
LEGALESE:
Permission to use, copy, modify, and distribute this software
and its documentation for NON-COMMERCIAL or COMMERCIAL purposes and
without fee is hereby granted.
No express promises are made, as to the usability of this software
for any purpose whatsoever. If you depend on this for anything, and
it breaks, and you lose money, don't come crying to me...
*/
import java.util.*;
import java.awt.*;
import java.applet.*;
// import java.io.*;
public class Clock2 extends Applet implements Runnable {
// Globals
Thread timer = null; // The timer thread
Color foregroundCol; // The foreground color
Color DefaultforegroundCol = new Color(0, 0, 0); // The default Foreground (Black)
Color backgroundCol; // The background color
Color DefaultbackgroundCol = new Color(192, 192, 192); // 'Browser Gray'
Date dummy = new Date(); // The first date to format the output from
Font showfont; // The font used for display
String lastdate = dummy.toLocaleString(); // The date to erase
String DateFmt = "%a, %B %e %T";
String[] weekDays = new String[7];
String[] months = new String[12];
/**
Get a color parameter from the html page ()
If the parameter is not given in the