3

I have been typesetting liturgical chants with reciting notes. Using lilypond version 2.18.2, I get what I want, but when I switched to 2.20.0, there is way too much space between syllables in some cases. I have tried to tinker with several values of SpacingSpanner variables, but can't get the behavior I what I want. It appears some default has changed or a new feature been introduced, but I haven't been able to track down where/what it is.

Here is a MWE of the code that comes out differently, depending on whether it is typeset with lilypond 2.18.2 or 2.20.0:

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\version "2.18.2"
\language "english"

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\header
{
    tagline = ##f
}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\layout
{
    ragged-right = ##t
    \context
    {
        \Score
        \remove "Bar_engraver"
        \remove "Bar_number_engraver"
        \override SpacingSpanner #'spacing-increment = #2.0
        timing = ##f
    }
    \context
    {
        \Staff
        \remove "Clef_engraver"
        \remove "Time_signature_engraver"
        \remove "Stem_engraver"
        \remove "Beam_engraver"
        \hide Flag
        \override StaffSymbol.line-count = #2
        \override StaffSymbol.line-positions = #'( 0 -2 )
    }
    \context
    {
        \Voice
        \override Stem #'length = #0
    }
    \context
    {
        \Lyrics
        \override VerticalAxisGroup.staff-affinity = #UP
        \override VerticalAxisGroup.nonstaff-relatedstaff-spacing =
            #'(
                (basic-distance . 0)
                (minimum-distance . 0)
                (padding . 1)
                (stretchability . 0)
            )
        \override LyricText #'font-size = #0
        \override LyricText #'self-alignment-X = #CENTER
        \override LyricHyphen #'minimum-distance = #0.0
    }
}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

% music macros

longnote =
{
    \once \override NoteHead #'stencil = #ly:text-interface::print
    \once \override NoteHead #'text = #(markup #:concat(
        #:musicglyph "noteheads.s2la"
        #:hspace -0.5
        #:musicglyph "noteheads.s2la"
        #:hspace -0.1
        #:musicglyph "noteheads.s2la"))
}

divisioMajor =
{
    \bar "|"
}

divisioMaxima =
{
    \bar "|"
}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

% lyric macros

recite =
{
    \once \override LyricText #'self-alignment-X = #LEFT
}

#(define-markup-command (singer layout props text) (markup?)
    (interpret-markup layout props
        #{
            \markup { \raise #0.5 \fontsize#-1 \italic #text }
        #}
    )
)

officiant = \markup { \singer "Officiant" }
people = \markup { \singer "People" }

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

melodyLine = \transpose c c
{
    \relative c'
    {
        \clef treble
        \key f\major
        \stemDown

        f4^\officiant g
        \longnote a16
        bf4 g f2*1/2
        \divisioMajor
        \break
        f4^\people g a g f g2*1/2
        \divisioMaxima
        \break

        f4^\officiant g
        \longnote a16
        bf4 g f2*1/2
        \divisioMajor
        \break
        f4^\people g a g f g2*1/2
        \divisioMaxima
        \break

        f4^\officiant g
        \longnote a4
        bf4 g f2*1/2
        \divisioMajor
        \break
        f4^\people g a g f g2*1/2
        \divisioMaxima
    }
}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

verse = \lyricmode
{
    That this \recite "evening may be holy, good," and peace -- ful,
    We en -- treat you, O God.

    That your \recite "holy angels may lead us in paths of peace" and good -- will,
    We en -- treat you, O God.

    That we \recite "may be pardoned and forgiven for our sins and" of -- fen -- ses,
    We en -- treat you, O God.
}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\paper
{
    indent = 0\pt
}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\score
{
    \new Staff
    <<
        \new Voice = melody { \melodyLine }
        \new Lyrics \lyricsto melody \verse
    >>
    \layout{}
}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

Output with lilypond 2.18.2: Typeset with lilypond 2.18.2

Output with lilypond 2.20.0:

Typeset with lilypond 2.20.0

  • This isn't really an MWE, that is, it's not minimal. Just the first part of the chant shows the problem. All the rest could have been left out. – ksnortum May 12 at 12:46
3

Welcome to Music.SX! To be honest, I did not really find the culprit. However, the following code contains a proposal how to perhaps solve the problem.

I think the possible reason for this behaviour is that you set the length of the long notes to 16 (or 4). Although you set timing = #f, this seems to have some influence on the following notes. Hence, I changed all the long notes to \breves. Further, I wrapped the long notes into \cadenzaOff and \candenzaOn, which should put them into two separate bars that use their own spacing context. In order to simplify the input, I changed your \longnote macro into a music function.

One drawback of this approach is that bar lines will appear. In order to solve this, I set the bar lines to hidden in the \longnote macro. Because you want bar lines not to be hidden at the end of the line, I placed \undos in the relevant \divisioMajor and divisioMaxima macros.

The result is not exactly what you had with LilyPond 2.18, but I think it is close.

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\version "2.20.0"
\language "english"

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\header
{
    tagline = ##f
}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\layout
{
    ragged-right = ##t
    \context
    {
        \Score
        \remove "Bar_engraver"
        \remove "Bar_number_engraver"
        \override SpacingSpanner #'spacing-increment = #2.0
        timing = ##f
    }
    \context
    {
        \Staff
        \remove "Clef_engraver"
        \remove "Time_signature_engraver"
        \remove "Stem_engraver"
        \remove "Beam_engraver"
        \hide Flag
        \override StaffSymbol.line-count = #2
        \override StaffSymbol.line-positions = #'( 0 -2 )
    }
    \context
    {
        \Voice
        \override Stem #'length = #0
    }
    \context
    {
        \Lyrics
        \override VerticalAxisGroup.staff-affinity = #UP
        \override VerticalAxisGroup.nonstaff-relatedstaff-spacing =
            #'(
                (basic-distance . 0)
                (minimum-distance . 0)
                (padding . 1)
                (stretchability . 0)
            )
        \override LyricText #'font-size = #0
        \override LyricText #'self-alignment-X = #CENTER
        \override LyricHyphen #'minimum-distance = #0.0
    }
}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

% music macros

longnote = #(define-music-function (note) (ly:music?)
    #{
        \hide Staff.BarLine
        \cadenzaOff
        \once \override NoteHead #'stencil = #ly:text-interface::print
        \once \override NoteHead #'text = #(markup #:concat(
            #:musicglyph "noteheads.s2la"
            #:hspace -0.5
            #:musicglyph "noteheads.s2la"
            #:hspace -0.1
            #:musicglyph "noteheads.s2la"))
        #note
        \cadenzaOn
    #})


divisioMajor =
{
    \undo \hide Staff.BarLine
    \bar "|"
}

divisioMaxima =
{
    \undo \hide Staff.BarLine
    \bar "|"
}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

% lyric macros

recite =
{
    \once \override LyricText #'self-alignment-X = #LEFT
}

#(define-markup-command (singer layout props text) (markup?)
    (interpret-markup layout props
        #{
            \markup { \raise #0.5 \fontsize#-1 \italic #text }
        #}
    )
)

officiant = \markup { \singer "Officiant" }
people = \markup { \singer "People" }

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

melodyLine = \transpose c c
{
    \relative c'
    {
        \clef treble
        \key f\major
        \stemDown

        f4^\officiant g 
        \longnote a\breve 
        bf4 g f2*1/2
        \divisioMajor
        \break
        f4^\people g a g f g2*1/2
        \divisioMaxima
        \break

        f4^\officiant g 
        \longnote a\breve 
        bf4 g f2*1/2 
        \divisioMajor
        \break
        f4^\people g a g f g2*1/2
        \divisioMaxima
        \break

        f4^\officiant g 
        \longnote a\breve 
        bf4 g f2*1/2
        \divisioMajor
        \break
        f4^\people g a g f g2*1/2
        \divisioMaxima
    }
}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

verse = \lyricmode
{
    That this \recite "evening may be holy, good," and peace -- ful,
    We en -- treat you, O God.

    That your \recite "holy angels may lead us in paths of peace" and good -- will,
    We en -- treat you, O God.

    That we \recite "may be pardoned and forgiven for our sins and" of -- fen -- ses,
    We en -- treat you, O God.
}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\paper
{
    indent = 0\pt
}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\score
{
    \new Staff
    <<
        \new Voice = melody { \melodyLine }
        \new Lyrics \lyricsto melody \verse
    >>
    %\layout{}
}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

Result:

enter image description here

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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