What I'm interested in is that wavy
line that comes across the bars (or sometimes between the staves),
usually preceded by some text with a \whiteout-like effect. The meaning
of this symbol is, "play exactly what other instrument plays". How can I
reproduce the same in Lilypond?
From what I've
learned yet, I'll have to create an engraver (in Scheme) that should
create a spanner (as the object could span several bars). Additionally, I
guess we already have some graphical primitive for wavy line, used in
glissandos and trills. But it's a bit obscure for me how to bind the
things together. I'm a bit new to extending Lilypond, so I'll be
grateful if someone experienced gives an outline of the solution.
Thanks in advance!
Dmitry
Sorry if my reply is not in the spirit of your question.
Which is to say, it is one thing if you are trying explicitly to
replicate an existing manuscript.
However, from a musical context, there is very little purpose
for this exercise.
The point of using the wavy lines is mostly
laziness--it is the easiest way to indicate that a part is doubled. There is nothing special about the wavy lines in terms of interpretation (except, of course, it becomes ambiguous in your example in which octave the composer wants the piano to play, since both guitar and bass are transposing instruments).
Since you're using lilypond, you could put the original parts in music variables, then actually print the entirety of the parts that are duplicated. This would be easier to accomplish, and be more accurate (especially if the octave matters).
I can see an argument that the wavy lines lets you digest a minimum of info on the page, which might help with initial comprehension. If that was important, you could still print "Col Guitar" and print the duplicated parts in a lighter shade of grey, or use cues (which prints with smaller notes).
However, I'd bet that most of the time these wavy lines are used, the composer/copyist/engraver would probably actually prefer to write the entire part out, but that would be too much work, and the wavy lines are good enough.
Especially since, if you are making parts for this score, you will have to do exactly that in order to make the piano part--this notation only makes sense in a score.