Le 03/06/2022 à 00:13, Steven A. Falco a écrit :
I've now got version of the piece with no warnings or errors
(attached), and it looks perfect.
I had to break some of the parts up so I could handle overlaps between
the guitar parts and the melody, and while still using the
"skip-of-length" constructs as much as possible.
I don't know if there is a cleaner way to handle the overlaps, but I'm
open to suggestions. Also, is there a way to do math on the skipped
lengths?
I could not figure out the scheme syntax for that yet, but if there
was a way to say something like "#(skip-of-length melody_notes) minus
one measure", that would be helpful.
In 2.23.9, you can already do \skip \melody_notes, which
skips the duration of \melody_notes. On the other hand, this
doesn't allow subtracting a length. For that, you could do
something like this:
\version "2.23.9"
mus = { c'1 2 4 4 1 1 }
skipLengthMinus =
#(define-music-function (music minus) (ly:music? ly:duration?)
(skip (ly:make-duration 0 0 (ly:moment-main (ly:moment-sub
(ly:music-length mus)
(ly:duration-length minus))))))
{ c'1 \skipLengthMinus \mus 1*2 c'1 }
The first argument to \skipLengthMinus is the music whose
length is the main source for the duration to skip. The
second argument is a duration to subtract from that.
Best,
Jean