The last thing to do is to merge the R1/ You can do :
\new Staff <<
s4-\markup{Merge rests as per standard notation practice.}
\relative c'' { c4 d e b\rest | r2 e4 g | _*b,1\rest*_ } \\
\relative c'' { c4 b a b\rest | r a g2 | _*b1\rest *_}
>>
*but these are not centered.*
So you have to do :
\new Staff <<
s4-\markup{Merge rests as per standard notation practice.}
\relative c'' { c4 d e b\rest | r2 e4 g | *revert MultiMeasureRest
#'staff-position R1*} \\
\relative c'' { c4 b a b\rest | r a g2 | *\revert MultiMeasureRest
#'staff-position R1* }
>>
It's a kind of magic... thanks for your question which has made me read
again this doc :
http://lilypond.org/doc/v2.13/Documentation/notation/writing-rests#rests !
Jmarc
On 13/09/2010 11:11, bart deruyter wrote:
That is wonderfull :-), full control, and simple code, thanks a lot,
exactly what I was looking for.
grtz,
Bart
http://www.bartart3d.be/
2010/9/13 Éditions IN NOMINE <[email protected]
<mailto:[email protected]>>
Well, I'm completly amazed by scheme function, which I'm totally
unable to build. What I'd have done instead is :
\score {
\new Score <<
\new Staff <<
s4-\markup{LilyPond default, rests in both voices.}
\relative c'' { c4 d e r | r2 e4 g | R1 } \\
\relative c'' { c4 b a r | r a g2 | R1 }
>>
\new Staff <<
s4-\markup{Merge rests as per standard notation practice.}
\relative c'' { c4 d e _*b\rest*_ | r2 e4 g | R1 } \\ %*2
b\rest will merge at the same place...*
\relative c'' { c4 b a _*b\rest*_ | r a g2 | R1 }
>>
>>
\layout {}
}
which lead to merged rests... but it is a very secular way to do it !
Regards
JMarc
On 13/09/2010 10:45, bart deruyter wrote:
Hi,
I have found a way to merge rests when there are two voices on
one stave, but which evolve as one voice, to limit clutter on the
score on this page : http://lsr.dsi.unimi.it/LSR/Item?id=336 .
It is very usefull indeed, but isn't there a more general way to
merge rests. It's a lot of code for a task, that I think is often
needed. This code is limited to two voices, but I already have a
score laying around here with three voices. I know about hiding
rests, but then I'll have to change the position of the remaining
rests to the center of the staff, like the example of the snippet
shows. I'm quite a beginner, so I think that's pretty advanced
stuff already.
Any ideas for an alternative to the snippet?
Greetz,
Bart
http://www.bartart3d.be/
_______________________________________________
lilypond-user mailing list
[email protected] <mailto:[email protected]>
http://lists.gnu.org/mailman/listinfo/lilypond-user
_______________________________________________
lilypond-user mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/lilypond-user