ClockFace:
Filter:
ClockFace/Classes (extension) | GUI

ClockFace
ExtensionExtension

digital clock counter display

Class Methods

.new

creates a new ClockFace and GUI that, when played, will start at starttime and increment by inc according to tempo (in beats per SECOND).

Arguments:

starttime

Starting time

tempo

beats per second

inc

increment amount

alwaysOnTop

Should the window always be on top

Instance Methods

.play

Starts the clock

.stop

Stops the clock

.cursecs

sets the time on the clock to curtime. curtime is passed in seconds.

Arguments:

curtime

new time in seconds

.tempo

sets the current tempo in beats per second. Adjusts the internal TempoClock.

Arguments:

newBPS

new tempo in Beats Per Second

.mod

tell the ClockFace to calculate curtime with a modulo. Set to 0 or nil to remove a modulo.

Arguments:

newMod

modulo to use in calculating time

.onMod

when a mod is set, a Function to evaluate when the clock resets to 0.

.onBeat

if notNil, a Function to be evaluated whenever a new integer boundry is crossed. Can be used

for metronomic functions.

.alwaysOnTop

Sets whether the window should always be on top

Arguments:

bool

A boolean - true for alwaysOnTop, flalse for not

Examples