Pgking
Pgking

Reputation: 21

Lilypond : Adding lyrics into backslash temporary voices

I'm pretty new when it comes to details on Lilypond and I'm stuck on a problem. Whenever I introduce two new temporary voices with backslash <<{ }\\\\{ }>>, the lyrics skip over those voices :

Lyrics = \lyricmode {Et lux per -- pe -- tu -- a }
\score {
  \new ChoirStaff
  <<
  \new Voice = "soprano"
  \relative c' {
    \clef treble
    c4 f8 f
    <<{a a}\\{f f}>>
    c'4
  }
  \new Lyrics \lyricsto "soprano" { \Lyrics }
  >>
}

Here is the document: http://lilybin.com/xbi9lm/1

I've tried a lot of things, and one that does something interesting is this:

Lyrics = \lyricmode {Et lux per a }
LyricsTwo = \lyricmode {pe -- tu }

\score {
  \new ChoirStaff
  <<
  \new Voice = "soprano"
  \relative c' {
    \clef treble
    c4 f8 f
    <<{a a}\\{f f}\new Lyrics \lyricsto "2" {\LyricsTwo}>>
    c'4
  }
  \new Lyrics \lyricsto "soprano" { \Lyrics }
  \new Voice = "alto"
  \relative c' {
    \clef treble
    c1
  }
  >>
}

Here is the document : http://lilybin.com/xbi9lm/2

Using backslashes for temporary voices creates two voices named "1" and "2" so that's what I've tried, but somehow the lyrics get under the entire score ?

I use them a lot but for very short amount of notes/time.

I'm at a complete loss so if someone has a good solution for integrating lyrics into temporary multiple backslash voices, I'm all ears !

Upvotes: 2

Views: 280

Answers (1)

Anonymous
Anonymous

Reputation: 86280

While for keyboard music I also use the << { … } \\ { … } >> notation a lot, for music with lyrics I prefer to give Lilypond one voice onto which to hang the lyrics. I leave out \\, and Lilypond will regard the inside of << … >> as belonging to the same voice. We want only one of the two to belong, so we explicitly declare a different voice for the other.

Lyrics = \lyricmode { Et lux per -- pe -- tu -- a }

\score {
  \new ChoirStaff <<
    \new Voice = "soprano" \relative c' {
      \clef treble
      c4 f8 f
      <<
        { \voiceOne a a }
        \new Voice { \voiceTwo f f }
      >>
      \oneVoice c'4
    }
    \new Lyrics \lyricsto "soprano" { \Lyrics }
    \new Voice = "alto"
    \relative c' {
      \clef treble
      c1
    }
  >>
}

Output:

enter image description here

The \voiceOne, \voiceTwo and \oneVoice macros I call are what your double-backslash notation also calls behind the scenes to get the voices look like voice 1 and 2 (mainly the stem directions). I trust you to fix the beaming.

Upvotes: 3

Related Questions