cuthbertLab / music21j

Javascript port of music21 -- Toolkit for Computational Musicology
Other
144 stars 41 forks source link

Account for measure width changes during system break calculation #126

Closed jacobtylerwalls closed 2 years ago

jacobtylerwalls commented 3 years ago

Before systemWidthsAndBreaks() calculates system breaks (against maxSystemWidth) without taking into account new, wider measures from reiterating clef and meter on a new system, which was only done later in fixSystemInformation().

Now The width adjustments need to be performed in the same pass as calculating system widths, so I propose moving the logic into systemWidthsAndBreaks().

mscuthbert commented 3 years ago

This looks very good to me -- nice catch. Do the tests in testHTML look promising to you?

jacobtylerwalls commented 2 years ago

Do the tests in testHTML look promising to you?

The two tests employing maxSystemWidth both weren't currently working (pitchEditing_long_score and roundCanon), so I think multi-system stuff is still beta-enough that I'm not sure we need to bring those old tests "up to code" to move on with an improvement. Since your comment I have added a js test that fails on master, though.