TermUI.Event.Tick (TermUI v1.0.0)

View Source

Host-created timer tick event.

Represents timing metadata for animations and time-based updates. The 1.0 runtime's Command.timer/2 and Command.interval/2 deliver their configured messages; they do not construct %Event.Tick{} automatically.

Summary

Functions

Creates a new tick event.

Returns the tick rate in Hz (ticks per second).

Types

t()

@type t() :: %TermUI.Event.Tick{interval: pos_integer(), timestamp: integer()}

Functions

new(interval, opts \\ [])

Creates a new tick event.

rate(tick)

Returns the tick rate in Hz (ticks per second).