The Parameters Explained             

ColorClock's parameters are explained below, with reference to the clickable example code in the left frame: you can click a parameter from the example code to jump to its explanation, or simply read this page from top to toe.


Applet Width & Height
The applet height can be just about anything you like, as long as its sufficient to display the text at your chosen Font size. It's worth checking the result in Netscape as well as Internet Explorer since Netscape tends to require more space for text than is normal. If you opt to have ColorClock display an alternative format when the mouse enters the applet, the results are more pleasing if the applet-height is reduced to the minimum possible. The text is always vertically centered within the applet.

Applet width should be long enough to display the longest line of text your chosen Format will show, at your chosen font size (allowing for the fact that we get days like Saturday and months like September which take up a bit more space than a Friday in May).

TIP: When judging applet dimensions, it's helpful to temporarily set the BgColor to something that stands out from your web page's background while you make the necessary adjustments.

To make the setting up easier, ColorClock includes a Testmode that displays the minimum width/height for the applet.

BgColor
A hex triplet specifying the background color of the applet, which would usually be set to match the color of your page's body background. The default value is 000000 (black).

TextColor
The color of the font used to display the time/date, as a hex triplet. The default color is 00FF00 (lime).

TextFocusColor
The color of the text used to display the alternative time/date format if you've chosen to use this feature by including the SwitchFormat parameter. The default color is FF0000 (red).

3D
An optional 3D text effect which is applied to all displayed text using the chosen setting. There are five possible settings for this parameter, four of which are presets. The four preset values for this parameter are off (the default, producing no effect), light which creates the effect using a lighter version of the current TextColor or TextFocusColor, dark which uses a darker version of the current text color, and gray which uses a fixed color (C0C0C0) to produce the effect. How effective the results will be depends a lot upon your text color(s) and your BgColor, and some experimentation may be needed. As usual, none of these values is case-sensitive.

The fifth option is to enter your own hex color into this parameter (such as FF0000 for bright red). This color will be used to create the 3D effect for both date/time formats.

3DOffset
The 3D effect places a copy of the text slightly to the left of the main text. By default, this copy is placed 2 pixels to the left, so the default setting for this parameter is 2. However, you can change this by entering any positive number. Note that if you enter 0 here, it's the equivalent of turning off the 3D effect, and the applet will do just that to save itself some processing effort.

Font
A comma-delimited string giving the name, style and size of the font you want to use for the text. The default settings are TimesRoman, in bold, at size 18, which would be written as TimesRoman,bold,18. Two important things to note: first, there must be no spaces in this entry; second, the three items must appear in the order name,style,size. Note that the style part of this setting can be plain, bold, italic or bolditalic, and these are not case-sensitive.

Align
A choice of three non-case-sensitive values - left, right or center - that let you choose the horizontal alignment for the text within the applet. The default is center.

Format
ColorClock lets you choose from 14 preset time/date formats, and this is the parameter in which you do it. ColorClock can display hours, minutes, seconds, day, numerical day, month and year, and this parameter uses combinations of the initial letters from that list. The possible formats are:

  • hm: hours and minutes, in the form 11:59

  • hms: hours, minutes and seconds, in the form 11:59:32

  • nmy: number, month and year (13 July 1998)

  • mny: month, number, year (July 13 1998)

  • dnmy: day, number, month and year (Monday, 13 July 1998)

  • dmny: day, month, number and year (Monday, July 13 1998)

  • hmsnmy: hours, minutes, seconds, number, month, year (11:59:32  13 July 1998)

  • hmsmny: hours, minutes, seconds, month, number, year (11:59:32  July 13 1998)

  • nmyhms: number, month, year, hours, minutes, seconds (13 July 1998  11:59:32)

  • mnyhms: month, number, year, hours, minutes, seconds (July 13 1998  11:59:32)

  • dmnyhms: day, month, number, year, hours, minutes, seconds (11:59:32  Monday, July 13 1998)

  • dnmyhms: day, number, month, year, hours, minutes, seconds (11:59:32  Monday, 13 July 1998)

  • hmsdmny: hours, minutes, seconds, day, month, number, year (11:59:32  Monday, July 13 1998)

  • hmsdnmy: hours, minutes, seconds, day, number, month, year (11:59:32  Monday, 13 July 1998)
  • The default setting for this parameter is the last in the list.

    SwitchFormat
    ColorClock can optionally display a second time/date format, selected using this parameter. The same 14 format options are available for this parameter as for the Format parameter above, entered in the same way. The default for this parameter is to use whatever you selected for your main Format parameter, so there's no need to include this parameter unless you want the display to change. This second format will use the same font and alignment, but will be displayed using your chosen TextFocusColor. When this second format will be shown is selected by means of the AutoSwitch parameter.

    The expected use of this alternative format is in displaying the current time in the Format parameter (such as "hms") and the date in this SwitchFormat parameter, although you can obviously use it in any way you want to.

    AutoSwitch
    This parameter determines when and how the alternative time/date selected in the SwitchFormat parameter will be displayed. If you haven't included the SwitchFormat parameter, the setting for this one will have no effect and can be left out also. This parameter offers four non-case-sensitive options:

  • no: The main Format won't change to the SwitchFormat automatically; instead the SwitchFormat will only be shown when (and if) the mouse enters the applet.

  • yes: The SwitchFormat will be shown every 10 seconds, and remain displayed for 1 second.

  • double: The SwitchFormat will be shown every 10 seconds, and remain displayed for twice as long (viz. 2 seconds).

  • twice: The SwitchFormat will be shown every 5 seconds, and remain displayed for 1 second.
  • The default setting is no. If this parameter is set to anything other than no (so that the switching happens automatically), any mouse movement inside the applet will be ignored.

    NumericalDate
    Another yes or no parameter, for which the default is no. If you choose 'yes', any Format (or SwitchFormat) that involves a date will display it in numerical form (such as 13/07/98 for the 'nmy' format, or 07/13/98 for the 'mny' format).

    Testmode*
    A straightforward yes or no parameter. Most of the time you'll leave this set at its default no (when uploading the files to your server, for example). When setting up the applet, set this parameter to yes and then move the mouse over the applet. The minimum width and height for the applet will be displayed in the statusbar. You can then copy these unchanged to set your applet dimensions, or simply use them to ensure that the dimensions you've chosen are sufficient.

    Testmode takes into account the setting for your 3DOffset (if used), your choice of font, and the longer of your two date/time formats. In addition of course (because this is the point of having a Testmode!), it bases its measurements on the longest possible line of text it will ever have to display. If you're setting up your applet on 1st May the applet width might look unnecessarily large, but you'll feel differently about that come 22nd September!

    *In this evaluation copy, Testmode is non-functioning.


































    .