The event object
Type: Dictionary
The event object represents a discrete period of time during which one or more notes are performed, or in which a rest occurs.
All events other than whole-measure events require a value
attribute to provide their duration as a note value. This duration is implicitly multiplied by the current time modification ratio, as specified by the process of sequencing the content of the event’s containing element.
Keys:
Name | Type | Required? | Description |
---|---|---|---|
note value object | No | The duration of this event. This is required unless this event has measure=true. | |
id object | No | ||
event markings object | No | ||
boolean object | No | Whether this event is a whole-measure event — meaning its duration lasts the entire measure. This is used, for example, for rests that last an entire measure. If this value is set to true, then this event may not specify "value" and this event must either be empty or contain exactly one rest. |
|
An array of note objects | No | ||
orientation object | No | A specific orientation for this event. If not provided, the orientation is inherited from any ancestor element that specified it. If no ancestor did so, the orientation is determined automatically according to the implementation’s rendering rules. | |
rest object | No | ||
An array of slur objects | No | ||
smufl font object | No | The SMuFL-compliant font to be used when rendering this event. The primary purpose of this attribute is to override a global font assignment. |
|
staff number object | No | A specific staff index for this event. If not provided, the value is inherited from any ancestor element that specified it. If no ancestor did so, the value is determined automatically according to the implementation’s rendering rules. The primary purpose of this attribute is to override a default staff assignment at the sequence level — as in cross-staff keyboard notation. |
|
stem direction object | No | Whether the stem of the note(s) in this event is up or down. If not provided, this is left to consuming software to decide automatically. | |
The string "event"
|
Yes |
Examples
This object is used in the following examples: