Originally created by: *anonymous
Originally created by: janek.li...@gmail.com
Originally owned by: dak@gnu.org
\version "2.19.10"
% I define a custom Voice-like context with red notes:
\layout {
\context {
\Staff
\accepts "FooVoice"
}
\context {
\Voice
\name "FooVoice"
\alias Voice
\override NoteHead.color = #red
}
}
\markup { FooVoice works with "\\new Lyrics \\lyricsto": }
<<
\new FooVoice = foo { c'1 }
\new Lyrics \lyricsto foo { lol }
>>
\markup { But it doesn't work with "\\addlyrics": }
\new FooVoice { c'1 }
% \addlyrics forces creating a new Voice instead of a FooVoice -
% you can tell that it's a plain Voice because notehead is black.
\addlyrics { lol }
I'd be glad to pay 20 Euro for the fix.
Originally posted by: dak@gnu.org
That FooVoice is an alias of Voice can only be determined at iteration time while \addlyrics is a compile-time syntactic feature. From the parser's standpoint,
\new FooVoice { c'1 } \addlyrics { lol }
is indistinguishable from
\new Staff { c'1 } \addlyrics { lol }
So the main challenge is doing the right thing with the latter. I'm currently in the process of working on related stuff that would likely make something useful fall out here, so I am marking this issue as started.
Owner: dak@gnu.org
Status: Started
Originally posted by: dak@gnu.org
I think you'll find that issue 4097 implements a superset of this issue: your code works as expected with that patch. For a bottom context like FooVoice, the deficiencies of issue 4097 regarding melismata do not come into play, so you should be fine.
Mergedinto: 4097
Status: Duplicate
Originally posted by: janek.li...@gmail.com
That's great! I'll send the money tomorrow.