[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: vertical spacing of rests
From: |
Peter Selinger |
Subject: |
Re: vertical spacing of rests |
Date: |
Tue, 25 Aug 2015 10:28:31 -0300 (ADT) |
Trevor Daniels wrote:
>
> address@hidden (Peter Selinger) writes:
>
> > this is a true newbie question. I am trying to engrave two polyphonic
> > voices on a single staff. Since the two voices have all their rests in
> > common, I only want to typeset each rest once, so I use spacer rests
> > in the second voice. Still the vertical spacing is such that all the
> > rests are put near the top of the staff. I would like them to appear
> > in their "normal" positions.
> >
> > From the manual, I know two ways to do this. Solution 1 is to enclose
> > each rest between \oneVoice and \voiceOne, forcing standard vertical
> > spacing:
> >
> > Solution 2 is to specify an explicit vertical position for each rest.
>
> > Neither solution is particularly elegant, as they both require every
> > rest to be marked up individually. Is there a global way to turn off
> > vertical spacing for rests in a context, i.e., some command whose
> > effect would be to make notes behave as with \voiceOne and rests
> > behave as with \oneVoice?
>
> I think using
>
> \override Rest.voiced-position = 0
>
> in the voice in which you have rests might do the trick for you.
>
> Trevor
This shows that I should read my emails in the correct order. Thanks
for the tip about voiced-position. This seems to be a new feature in
2.19?
Unlike staff-position, voiced-position does the right thing for all
rests, including r1 and R1.
Adding that to my previous example:
%----------------------------------------
\version "2.19.25"
<<
\compressFullBarRests
\new Staff {
\oneVoice
<>^"default for oneVoice"
| r\longa | r\breve | r1 | r2 r4 r8 r8 | R1*4 | R1*2 | R1 |
}
\new Staff {
\voiceOne
<>^"default for voiceOne"
| r\longa | r\breve | r1 | r2 r4 r8 r8 | R1*4 | R1*2 | R1 |
}
\new Staff {
\voiceOne
\override Rest.staff-position = #0
\override MultiMeasureRest.staff-position = #0
<>^"voiceOne with staff-position = 0"
| r\longa | r\breve | r1 | r2 r4 r8 r8 | R1*4 | R1*2 | R1 |
\revert Rest.staff-position
\revert MultiMeasureRest.staff-position
}
\new Staff {
\voiceOne
\override Rest.Y-offset = #0
\override MultiMeasureRest.Y-offset = #0
<>^"voiceOne with Y-offset = 0"
| r\longa | r\breve | r1 | r2 r4 r8 r8 | R1*4 | R1*2 | R1 |
\revert Rest.Y-offset
\revert MultiMeasureRest.Y-offset
}
\new Staff {
\voiceOne
\override Rest.voiced-position = #0
\override MultiMeasureRest.voiced-position = #0
<>^"voiceOne with voiced-position = 0"
| r\longa | r\breve | r1 | r2 r4 r8 r8 | R1*4 | R1*2 | R1 |
\revert Rest.voiced-position
\revert MultiMeasureRest.voiced-position
}
>>
%----------------------------------------
(see attached rests8b.pdf for the output). The fact that
voiced-position works correctly and staff-position doesn't seems to
further underscore the problem with (and possible bug in)
MultiMeasureRest.staff-position.
-- Peter
Re: vertical spacing of rests, Michael Rivers, 2015/08/22
Re: vertical spacing of rests, David Kastrup, 2015/08/24
- Re: vertical spacing of rests, Ralph Palmer, 2015/08/24
- Re: vertical spacing of rests, Trevor Daniels, 2015/08/24
- Re: vertical spacing of rests,
Peter Selinger <=
- Re: vertical spacing of rests, Trevor Daniels, 2015/08/25
- Re: vertical spacing of rests, Michael Gerdau, 2015/08/25
- Re: vertical spacing of rests, Phil Holmes, 2015/08/25
- Re: vertical spacing of rests, Peter Selinger, 2015/08/25
- Re: vertical spacing of rests, David Kastrup, 2015/08/25
- Re: vertical spacing of rests, Michael Gerdau, 2015/08/25
Re: vertical spacing of rests, Trevor Daniels, 2015/08/25
Re: vertical spacing of rests, 70147persson, 2015/08/25