I now have a much nicer design that should accommodate for these intricacies nicely, and am part way through implementing it. The design involves maintaining separate contexts for groups of Tickables (which is an abstraction for anything with a duration, such as notes, tabs, lyric-pieces, or chords) and Modifiers (an abstraction which includes accidentals, dots, bends, etc.) Higher-level formatters can be plugged in that work within these contexts to size, kern, and position the glyphs.
All you need to do is write your tests, and QUnit takes care of managing, running, and reporting.
Anyhow, I do have a few things to show for all of this. First, is the support for note bends in tablature. Notice how the lower bend is pushed further to the right? This is because they're in the same ModifierContext.
I also added slides, hammerons, and pulloffs.
I fixed the size of the accidentals. (I hope this is correct.)
And finally, note-heads are correctly displaced for notes that are right next to each other.
|Displaced Note Heads|
That's all for this week, folks!