Add Chords
Maestro doesn't have any concept of chords, so notes in the same x column are just overlaid on one another. In the case of notes with barbs (quavers, etc) this can result in messy or unintelligible layouts. 'Staggered' notes (where note heads are in too close proximity and need to be nudged) are just shifted right, with no proper algorithm to determine which note heads need to be moved or where they should go.
This merge request:
- Expands Note blocks in memory to 1 word to make space to hold extra positioning data
- Calculates Chord and Stagger data for Notes within Gates
- Updates typesetting routines to space and redraw chords accurately, including only drawing single barbs for chords with barbed tails
- Adds initial documentation for the internal changes
The changes to the code are quite extensive, but as well as allowing chords, these changes form the basis for a future system of note beams (ie, drawing quaver runs, etc, properly joined up rather than as individual notes).
Admin: Tested with a variety of Maestro files. NB. Maestro has never done any bounds checking when writing data to memory, instead just reserving a huge Wimpslot and hoping for the best. Making the size of the Note blocks bigger might therefore cause problems with very large scores. If this Merge request is accepted, my intention next is to revise the memory handling so that all the music data is held in a resizable heap block with proper bounds checking.