|
From: | Giampaolo Orrigo |
Subject: | Re: Alignment problem |
Date: | Sun, 4 Jun 2017 17:32:52 -0400 |
Thanks, it's so much easier to help when we havean immediately accessible working code to play with.For most of this extract only two voices are needed inthe treble clef and two in the bass clef, i.e. voicesone and two in the treble and also voices one and twoin the bass. This is fine until you switch clefs inbar 6: then when you set the stem to be up you have twonotes with stems up (voiceOne), but with different durations.Not good.Here you need a third voice if you want thestems in the direction indicated, like this:Alto = \relative c'' {
\global
% Music follows here.
\showStaffSwitch
b, a g2 d' g~ g4 f e d c1 c2. b4
\change Staff=down \voiceThree
\once \override NoteColumn.force-hshift = 1.5
a g f e d2
\change Staff=up \voiceTwod'4 c
}You'll then find you can adjust the positioning usingforce-hshift on any note and with any value to suit yourpreference. Perhaps like this:Alto = \relative c'' {
\global
% Music follows here.
\showStaffSwitch
b, a g2 d' g~ g4 f e d c1 c2. b4
\change Staff=down \voiceThree
\once \override NoteColumn.force-hshift = 1.5
a g f e d2
\change Staff=up \voiceTwo d'4 c
}Baxo = \relative c {
\global
% Music follows here.
\showStaffSwitch
g1\rest g'2. f4 e4 d c b a g f2 f'1
\once \override NoteColumn.force-hshift = 1.5
f4 e d c bf a g2~
}NB Always avoid fiddling with the stem direction using\stemUp and \stemDown. If you feel the need to use theseyou almost certainly should be thinking of changing thevoice instead.Trevor----- Original Message -----From: Giampaolo OrrigoTo: Trevor DanielsCc: address@hiddenSent: Sunday, June 04, 2017 6:58 PMSubject: Re: Alignment problemTrevor,Thanks for the suggestion. I didn't want to overflow the email with code, but I see your point.Here the compilable example:\version "2.18.2"\language "english"\paper {#(set-paper-size "letter")}global = {\key c \major\time 2/2}Tiple = \relative c'' {\global% Music follows here.\showStaffSwitchd2. c4 b a g2~ g g c2. b4 a g f2 a1 bf2. a4}Alto = \relative c'' {\global% Music follows here.\showStaffSwitchb, a g2 d' g~ g4 f e d c1 c2. b4 \change Staff=down \stemUp a g f e d2 \change Staff=up \stemDown d'4 c}Tenor = \relative c' {\global% Music follows here.\showStaffSwitchg1 g g a a a g}Baxo = \relative c {\global% Music follows here.\showStaffSwitchg1\rest g'2. f4 e4 d c b a g f2 f'1 f4 e d c bf a g2~}\score {\new PianoStaff \with {instrumentName = "Organ"} <<\new Staff = "up" \with {} << \Tiple \\ \Alto >>\new Staff = "down" \with {} { \clef bass << \Tenor \\ \Baxo >> }>>\layout { }}And here the result:As you all can see, at staff 6 and 7 Tenor and Alto overlap. I tried to insert \override NoteColumn.force-hshift = #n with various n's both to the Alto and the Tenor but it has no effect whatsoever.Thanks for the help!
GeppoOn Sun, Jun 4, 2017 at 12:35 PM, Trevor Daniels <address@hidden> wrote:
Hi GeppoYou'd be more likely to get a reply if you posted animmediately compilable example showing the problem.Trevor----- Original Message -----From: Giampaolo OrrigoTo: address@hiddenSent: Saturday, June 03, 2017 12:02 AMSubject: Alignment problemHi,trying to type an organ piece.Here the original code:Tiple = \relative c'' {\global% Music follows here.\showStaffSwitchd'2. c4 b a g2~ g g c2. b4 a g f2 a1 bf2. a4}Alto = \relative c'' {\global% Music follows here.\showStaffSwitchb a g2 d' g~ g4 f e d c1 c2. b4 \change Staff=down \stemUp a g f e d2 \change Staff=up \stemDown d'4 c}Tenor = \relative c' {\global% Music follows here.\showStaffSwitchg g g a a a g}Baxo = \relative c {\global% Music follows here.\showStaffSwitchg\rest g'2. f4 e4 d c b a g f2 f'1 f4 e d c bf a g2~}When compiling I get the attached Capture1.jpg. The command\override NoteColumn.force-hshift = #-0.7Has no effect neither on the Alto nor on the Tenor.How can I correct the alignment of the notes?Thanks!
Geppo
_______________________________________________
lilypond-user mailing list
address@hidden
https://lists.gnu.org/mailman/listinfo/lilypond-user
[Prev in Thread] | Current Thread | [Next in Thread] |