5

I'm wondering if someone can point me to a snippet or other example as I'm yet to find a solution ...

I have a piece, a simple tune with 2 verses n Lilypond where the piano parts, melody and words are in separate files referenced as variables.

The melody starts with an anacrusis with a single syllable followed by the repeat marks. I've placed the first word of verse two at the end of the verseOneWords variable (which seems like a fudge) to get it picked up in the first alternative bar. I then want the last syllable of the second verse to appear under the note in the second alternative section.

How is this done?

I've copied the main score file, and words file, in case that gives insights into my (probably) amateur approach to Lilypond usage :)

%\version "..."

\language "english"

global =  {
    \tempo 4=100
    \time 4/4 \numericTimeSignature
    \key g \major
}

% words file
verseOneWords = \lyricmode {
  \set stanza = "1."
  You are old Fa -- ther Wil -- li -- am
  The young man said
  \set ignoreMelismata = ##t And your 
  \unset ignoreMelismata
  hair has be -- come ve -- ry white
  and yet you in -- cess -- ant -- ly stand on your head
  \set ignoreMelismata = ##t Do you \unset ignoreMelismata
  think at your age it is right? In my
}

verseTwoWords = \lyricmode {
  \set stanza = "2."
  \skip 1 \skip 1 youth Fa -- ther Wil -- li -- am rep -- lied 
  \set ignoreMelismata = ##t to his son \unset ignoreMelismata
  I feared it might in -- jure my brain
  But now that I'm per -- fect -- ly sure I have none
  I do it a -- gain and a --  gain
}

% melody file
melody = \relative c' {
  \clef treble
  % 1
  r1
  % 2
  r2 r4 g'8 fs |
  \repeat volta 2 {
    % 3
    g4 g8 fs g b a g |
    % 4
    a4 e8( e) a4 a8( g) |
    % 5
    fs4 fs8 e d4 a'8 b |
    % 6
    b2 r4 b4 |
    % 7
    c4 c8 b a g fs4 |
    % 8
    b4 b8 a g4 g8( fs) |
    % 9
    e4 e8 g fs4 e8 fs |
    % 10
  }
  \alternative {
    { g2 r4 g8 fs }
    { g2 r2 }
  }
  \bar "|."
}

\score {
<<
\new Staff = "Alice" \with { 
  instrumentName = "Alice" shortInstrumentName = "A" }
  \new Voice = "alice" {
    \global
    \melody
  }
  \new Lyrics \lyricsto "alice" {
    \verseOneWords
  }
  \new Lyrics\lyricsto "alice" {
    \verseTwoWords
  }
%\new PianoStaff {
%  <<
%    \new Staff {
%      \global
%      \right
%    }
%    
%    \new ChordNames \with { 
%      \override ChordName.font-size = #-1 }
%      \harmonies
%    
%    \new Staff {
%      \global
%      \left
%    }
%  >>
%}
>>
}

And to help, here's an image of the score. I want to get that final syllable in the final bar!

enter image description here

1 Answer 1

3

Firstly, I've edited the code in your question so that is compilable. This makes it much easier for people that are trying to help.


For a full bar rest (at the very start of the melody) should be written with a capital "R" i.e. R1 not r1. This places it in the centre of the bar, where it should be.

To get the last word into the second ending, you could just use skips (like you did as the start), but to stop the hyphens filling across the first ending bar, put the hyphens in short strings like this:

I do it a -- gain and "a -" \skip 1 \skip 1 \skip 1 "- gain."

You might also want the stanza number to appear before the second verse's anacrusis. And possibly duplicate the lyrics at the start and place them in parentheses:

...
  think at your age it is right? 
  \set stanza = "2."
  In my
}

verseTwoWords = \lyricmode {
  \set stanza = "2." 
  (In my) youth Fa -- ther Wil -- li -- am rep -- lied 
...

Score with duplicate lyrics in parentheses


Another (perhaps simpler) way to present this score would be by placing the anacrusis inside of the repeat structure:

Score with anacrusis inside the repeat

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.