I always assume any automatic scheme would produce results other than exactly what the user desires at least some of the time. So my preference is usually for simple algorithms that provide predictable defaults, and expect that users will sometimes need to adjust manually from there. Which is to say, I don't expect perfection, but hope for something that works well in the usual case and doesn't make it difficult to manually adjust for the unusual case.
In this situation, I think what makes sense to me is a simple algorithm that says something like, "if syllable begins with a digit, left align on first non-digit (whether punctuation, space, or letter)". So in a syllable like "1. The" (with a "hard" space), the "." would be aligned under the note, the "1" to the left of that. I think this is more or less standard, although I'm no expert on this. If you've got something that needs different alignment, you could just adjust manually to get it how you like it.
We could also consider adding an option to suppress this automatic left alignment - and perhaps apply it also to melisma.
If a lyric syllable has leading digits, they are treated as a verse number, and the lyric is left-aligned on the first "word" character (somethng other than digit, punctuation, or space). Lyrics consisting of digits and punctuation *only* are not affected.
That seems to be a Qt size.calculation issue. It's often off just a little. But it really is aligning after the space in theory, as you can see if you put in multiple spaces.
Apologies if I'm missing something, but why are the first words of the top three stanzas left-aligned to the notehead (or the space, currently)? Is it because of the "11" not having a number?
The important thing is to right-align the verse numbers. The alignment of the the lyrics themselves is a secondary factor. Both MuseScore (with my PR) and LilyPond achieve the primary goal; they just have different approaches to the secondary factor. I have seen both in published music. I went with the approach of left aligning the lyric because:
a) that's how it was already being done with the previous implementation using Verse Number elements
b) the point of this scheme was to avoid breaking up the number and syllable into separate elements, and that's what LilyPond is doing (automatically changing the amount of space between the number and syllable)
c) if we wish to avoid use of the Verse Number element, achieving the LilyPond effect would require layout of one syllable to be dependent on content of other verses, which is something we cannot do right now.
If we decided it was important to go with the LilyPond style, it *is* possible, but it would pretty much require us to go back to using separate Verse Number elements. Advantage, I guess, would be you could have the special text style. It would be possible to still parse the verse number automatically - that is, we could still avoid the need for the Verse Number element on the palette..
Comments
Not sure we'd really want this
what about something like
I always assume any automatic scheme would produce results other than exactly what the user desires at least some of the time. So my preference is usually for simple algorithms that provide predictable defaults, and expect that users will sometimes need to adjust manually from there. Which is to say, I don't expect perfection, but hope for something that works well in the usual case and doesn't make it difficult to manually adjust for the unusual case.
In this situation, I think what makes sense to me is a simple algorithm that says something like, "if syllable begins with a digit, left align on first non-digit (whether punctuation, space, or letter)". So in a syllable like "1. The" (with a "hard" space), the "." would be aligned under the note, the "1" to the left of that. I think this is more or less standard, although I'm no expert on this. If you've got something that needs different alignment, you could just adjust manually to get it how you like it.
We could also consider adding an option to suppress this automatic left alignment - and perhaps apply it also to melisma.
Unless someone else is already looking at this, I'll give it a go...
https://github.com/musescore/MuseScore/pull/1391
If a lyric syllable has leading digits, they are treated as a verse number, and the lyric is left-aligned on the first "word" character (somethng other than digit, punctuation, or space). Lyrics consisting of digits and punctuation *only* are not affected.
Also, leading punction is ignored, although the lyric is still centered - see #24856: Ignore "parenthesized expressions" that precede lyric syllables.
Here is the vtest:
It looks more like left aligned to the space between number and syllable?
That seems to be a Qt size.calculation issue. It's often off just a little. But it really is aligning after the space in theory, as you can see if you put in multiple spaces.
How about something like
1. One
2. <some break symbol here>
3. three
(Just in case I find out how to enter such a break symbol in the first place ;-))
Apologies if I'm missing something, but why are the first words of the top three stanzas left-aligned to the notehead (or the space, currently)? Is it because of the "11" not having a number?
Here is LilyPond (if I'm doing it correctly):
Here are some published examples:
The important thing is to right-align the verse numbers. The alignment of the the lyrics themselves is a secondary factor. Both MuseScore (with my PR) and LilyPond achieve the primary goal; they just have different approaches to the secondary factor. I have seen both in published music. I went with the approach of left aligning the lyric because:
a) that's how it was already being done with the previous implementation using Verse Number elements
b) the point of this scheme was to avoid breaking up the number and syllable into separate elements, and that's what LilyPond is doing (automatically changing the amount of space between the number and syllable)
c) if we wish to avoid use of the Verse Number element, achieving the LilyPond effect would require layout of one syllable to be dependent on content of other verses, which is something we cannot do right now.
If we decided it was important to go with the LilyPond style, it *is* possible, but it would pretty much require us to go back to using separate Verse Number elements. Advantage, I guess, would be you could have the special text style. It would be possible to still parse the verse number automatically - that is, we could still avoid the need for the Verse Number element on the palette..
Fixed in 0e9dd1a35e
Automatically closed -- issue fixed for 2 weeks with no activity.
Following up on the discussion in #8 and #9, I filed this: #44951: Centre lyric to notehead in stanza