The mode attribute specifies whether a onscreen clock functions like a timer, progress bar, stopwatch, or a regular clock.
<clock>
Name | Type | Description | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
clockmode | clockmodeenum |
|
When in progress bar mode, the bar runs horizontally if the width is greater than the height, and vertically if the height is greater than the width. The color of the bar is determined by the txColor attribute and the background by the txBGColor attribute.
The following shows a stopwatch that displays the elapsed minutes and seconds:
<clock a>
/ mode = stopwatch
/ format = "mm:ss"
</clock>
The following displays a green horizontal progressbar on a light gray background with a 10 second duration:
<clock a>
/ mode = progressbar
/ timeout = 10000
/ size = (200px, 20px)
/ txColor = green
/ txBGColor = lightgray
</clock>