On 14 Dec 2011, at 22:05, Xavier Scheuer wrote: > On 14 December 2011 20:21, Damian leGassick <damianlegass...@mac.com> wrote: >> Hi David >> >> thanks for the quick reply >> >> the to-end-of-line function is half way there, but if I modify your example >> to \repeat unfold 17 there is only one staff after the line break >> >> what I'd like is for both staves to remain until the end of the score. >> >> I know that in a simple example it's just as easy to add spacers but I've >> got a number of complex musicological examples where the trial and error >> involved in determining exactly what spacer values to use is proving very >> time consuming > > Hi, > > If you know which voice is the longest and if you use variables for > the voices, then you can use skip-of-length longestVoiceVariableName . > > %%%% > > \version "2.15.21" > > shortestVoice = \repeat unfold 8 e'1 > midLengthVoice = \repeat unfold 16 d'1 > longestVoice = \repeat unfold 24 c'1 > > \score { > << > \new Staff = "shortest" { > << > % in order to keep alive the staff (with spacer rests) > $(skip-of-length longestVoice) % 2.15.21 syntax > % #(skip-of-length longestVoice) % 2.14.2 syntax > \shortestVoice >>> > } > \new Staff = "midLength" { > << > % in order to keep alive the staff (with spacer rests) > $(skip-of-length longestVoice) % 2.15.21 syntax > % #(skip-of-length longestVoice) % 2.14.2 syntax > \midLengthVoice >>> > } > \new Staff = "longest" { > \longestVoice > } >>> > } > > %%%% > > Cheers, > Xavier > > -- > Xavier Scheuer <x.sche...@gmail.com>
Thanks Xavier, this works perfectly (although couldn't get it to work in 2.14 for some reason...) Damian _______________________________________________ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user