I have some hymns which are sung on the occasion of saint's days which have pronouns which refers to the saint. Obviously, these pronouns should be either "he", "his", "him" or "she", "her" depending on the gender of the saint. When producing scores which are unattached to a specific liturgy, I would put "he/she", "his/her", "him/her" in the lyrics, however, when including the hymn in a specific liturgy, I would like the pronoun to take the appropriate form. Is there a way to write (scheme) functions that allows me to set a flag at the beginning of the score indicating which pronoun type I want and the lyrics will change accordingly.

MWE:

\version "2.18.2"

gender = m % manually set to m(ale), f(emale), n(eutral)

heshe = he % change to function which picks between "he" "she" and "he/she" based on setting of \gender

hisher = his % change to function which picks between "his" "her" and "his/her" based on setting of \gender

himher = him % change to function which picks between "him" "her" and "him/her" based on setting of \gender

global = { \key c \major }

verse = \lyricmode {
  Filled with the Spir -- it, by \hisher earth -- ly la -- bours,
  Brought to your peo -- ple heal -- ing and com -- pas -- sion;
  Rais -- ing the fal -- len, re -- con -- cil -- ing sin -- ners,
  Glad -- ly \heshe served them.
}

music = {
  c' c' c' c' c' c' c' c' c' c' c'
  c' c' c' c' c' c' c' c' c' c' c'
  c' c' c' c' c' c' c' c' c' c' c'
  c' c' c' c' c'
}

\new Staff
<<
   \new Voice = "mel" { \global \music }
   \new Lyrics \lyricsto "mel" { \verse }
>>

--
✝✝✝✝✝✝✝✝✝✝✝✝✝✝✝✝✝✝✝✝✝✝✝✝✝
Br. Samuel, OSB
St. Anselm’s Abbey
Washington, DC
(R. Padraic Springuel)

PAX ☧ ΧΡΙΣΤΟΣ

_______________________________________________
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user

Reply via email to