Skip to main content

Module noteworthy

Module noteworthy 

Source
Expand description

NoteWorthy Composer’s text format, .nwctxt: music21’s noteworthy.translate.

A file is a line per object, each |Command|Name:value|Name:value, and from_noteworthy reads it into a score of a part per staff. The binary .nwc format is read by from_nwc, which writes it out as those lines first, as music21 does.

Modules§

placement
Where music21’s NoteWorthy translator places notes, rests and marks in a measure, and how it joins slurs and ties: the one implementation, generic over what the measures are.

Structs§

Member
A note as a chord or a staff holds it.
NwcFont
A font the header names: music21’s FontDict.
NwcHeader
What a file’s header says: music21’s NWCConverter.parseHeader.
NwcObject
One object of a staff: music21’s NWCObject.
NwcReader
music21’s NWCConverter as a reader: the file, where it has got to in it, its version, and the alteration last written on each staff position, by the position modulo seven, until a barline.
NwcStaff
A staff and its objects: music21’s NWCStaff.

Enums§

BarStyle
What a barline Style does to the measure: music21’s createBarlines.
Object
What an object is, as much of it as is written out.

Constants§

ALTERATION_TEXTS
music21’s constants.AlterationTexts: x is a double sharp, v a double flat.
BAR_STYLES
music21’s constants.BarStyles.
CLEF_NAMES
music21’s constants.ClefNames.
DURATION_VALUES
music21’s constants.DurationValues.
FLAT_MASK
music21’s constants.FlatMask.
MIDI_INSTRUMENTS
music21’s constants.MidiInstruments, the General MIDI names by program.
OCTAVE_SHIFT_NAMES
music21’s constants.OctaveShiftNames.
SHARP_MASK
music21’s constants.SharpMask.

Functions§

bar_style
The barline a Style names.
clef_named
music21’s createClef: the clef a Type and OctaveShift name, and the name music21’s reader keeps for it as currentClef.
dump_lines
music21’s dumpToNWCText: the title and author, then each staff’s lines.
duration_of
music21’s setDurationForObject: the length a Dur value gives, with its dots, grace and triplet.
first_number
The staff position in a Pos value: its first whole number, as music21 finds it with -?\d+.
flow_kind
music21’s createOtherRepetitions: the mark a flow Style names.
from_noteworthy
Reads the text of a NoteWorthy Composer .nwctxt file into a score, as music21’s converter.parse reads one.
from_nwc
Reads a NoteWorthy Composer .nwc file’s bytes into a score, as music21’s converter.parse reads one: each staff and object written out as a line of the text format (nwc_lines) and those read by super::from_noteworthy’s reader.
key_sharps
music21’s createKey: sharps less flats in a Signature value.
lyrics
music21’s createLyrics: a verse split into the syllables sung to each note, a syllable after a hyphen written with one before it.
meter_ratio
music21’s createTimeSignature: a Signature value as a ratio.
nwc_lines
The lines of NoteWorthy text a .nwc file’s bytes stand for, as music21’s dumpToNWCText writes them: the title and author, then for each staff its name, its instrument and its objects.
staff_positions
The positions of a staff under a clef, as music21’s noteworthy.dictionaries lays them out: the octave of the lowest of seven positions, that position, and the steps from it. The clef is named as music21’s reader keeps it (TREBLE, BASS8dw, ALTO, …).
step_and_octave
The step and octave of a staff position under a clef: music21’s getStepAndOctaveFromPosition. Position 1 under the treble clef is C5, and each position up or down is a step.