fix #44841: reconcile lyricsline length adjustments #1657
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This change re-instates the portion of my code from #1638 that conflicted with @mgavioli changes in #1643, while preserving his changes as well.
This should now properly handle the layout of both types of LYRICSLINE in SLine::linePos(). Melisma lines get my code to calculate the endpoint more accurately relative to the righthand edge of the chord, hyphens get the original code to initially extend all the way to the next chord or end barline (this is adjusted later in LyricsLineSegment::layout()).
I also made an adjustment to in SLine::linePos() to allow hyphens to extend all the way to the end barline. Other lines in this category (HAIRPIN, TRILL, TEXTLINE) are terminated 1sp short of the barline, but this isn't appropriate for hyphens. The result was that a hyphen on the last note of a crowded system was being rendered shorter than necessary, with an extra 1sp of legroom going to waste.
@wschweer : I have been testing and reviewing things as thoroughly as I can, and so far so good. I fixed one crash that resulted from an unexpected interaction between commits, but aside from that and this one area where we knew there a potential conflict, all the code seems to be working well together.
Thanks, @mgavioli for undertaking this! An awful lot of lyric annoyances have been eliminated.