Struct nannou_timeline::Context [−][src]
pub struct Context {
pub bars: Vec<TimeSig>,
pub ppqn: Ppqn,
pub ruler: Ruler,
pub track_style: TrackStyle,
pub timeline_id: Id,
pub canvas_id: Id,
pub scrollable_rectangle_id: Id,
pub playhead_id: Id,
pub scrollbar_id: Id,
// some fields omitted
}
Expand description
A Context
returned by the Timeline
widget for setting tracks, Playhead
and Scrollbar
.
Fields
bars: Vec<TimeSig>
The list of musical Bar
s that describes the temporal structure.
To avoid unnecessary allocations, this Vec
is “taken” from the Timeline
’s State
before
the Context
is returned. The Vec
is then swapped back to the Timeline
’s State
when
the Context
is drop
ped.
ppqn: Ppqn
The resolution of a single quarter note.
ruler: Ruler
The Ruler
constructed by the Timeline
.
track_style: TrackStyle
Track-specific styling attributes.
timeline_id: Id
The unique identifier used to instantiate the parent Timeline
for this Context
.
canvas_id: Id
The transparent upon which pinned tracks and the scrollable area are placed.
scrollable_rectangle_id: Id
The unique identifier for the scrollable canvas upon which tracks are placed.
playhead_id: Id
The unique identifier for the Timeline
’s Playhead
widget.
scrollbar_id: Id
The unique identifier for the Timeline
’s Scrollbar
widget.