paulrosen / abcjs

javascript for rendering abc music notation
Other
1.94k stars 285 forks source link

Improvements in tab label handling #975

Closed seisiuneer closed 11 months ago

seisiuneer commented 11 months ago

This fixes the excessive spacing inject with tab labels displayed as well as restricts the tab label to just the first staff.

Unfortunately, the solution doesn't work for multiple-voice tunes, it will need to both adjust the staff top for the grouped tab staves within the voice as well as the following grouped staves, which will all have to move down the total of the height added by the previous staff labels.

To avoid all of this, I'm making the tradeoff of just not allowing tab labels on multi-voice tunes.

I totally understand if this is not something you'd want to ship as a general solution for the library, but we can use it as a starting point for a proper solution in the future.

paulrosen commented 11 months ago

Yeah, I looked at it and don't want to remove the labels from multi-voice tunes.

I like the tightening of the staves. There is something else I noticed that is a regression. See the test http://localhost:5501/tests/all.html?grep=Tablature%20kitchen%20sink

Notice that the "Inserted subtitle" line is in the middle of the staff. That was probably always like that - but having the label pushed the next staff down and it wasn't noticed.