lilypond-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Make shortVocalName attach to lyrics like stanza


From: Dinh Hoang Tu
Subject: Make shortVocalName attach to lyrics like stanza
Date: Wed, 30 Mar 2022 21:38:03 +0700

Hello Lilypond team and users,

I'm engraving songs with many verses, and I would like to have stanza numbers in front of each line instead of only first line.
I found vocalName and shortVocalName seems suitable for this purpose, but their positions do not adhere to verses like stanza does.

Is there any way to make vocalName/shortVocalName attach to verse like stanza, or any other way to achieve this?

\version "2.22.1"
musicOne = \relative {
  \repeat unfold 100 { c'' }
}
verseOne = \lyricmode {
  \set vocalName = "1."
  \set shortVocalName = "1." % on each new line, but too far from text
  \repeat unfold 100 { a }
}
verseTwo = \lyricmode {
  \set stanza = "2." % attach to text but only first line, not following new lines
  \repeat unfold 100 { a }
}
\score {
  <<
    \new Voice = "one" {
      \time 2/4
      \musicOne
    }
    \new Lyrics \lyricsto "one" {
      \verseOne
    }
    \new Lyrics \lyricsto "one" {
      \verseTwo
    }
  >>
  \layout {
    \context {
      \Score
      \override vocalName #'extra-offset = #'(-10 . 0) % not effective
      \override shortVocalName #'extra-offset = #'(-10 . 0) % not effective
    }
  }
}


Any help is appreciated.

Kind regards,
Tu DINH

Attachment: shortVocalName.pdf
Description: Adobe PDF document


reply via email to

[Prev in Thread] Current Thread [Next in Thread]