On Wed, 03 Nov 2010 12:35:23 -0700, Jan Warchoł 
<lemniskata.bernoulli...@gmail.com> wrote:

2010/11/3 Keith E OHara <k-ohara5...@oco.net>

I don't fully understand... Are you refering to the lyricsStaff.png picture?
Yes.  You understood correctly.  (I confused th order of the pictures)

[ . . . ] In this case
they should be centered (because they apply to both staves) and i told
LilyPond to do so:
\new Lyrics \with { \override VerticalAxisGroup #'staff-affinity = #CENTER }
but the result was wrong.

I think I see.  Lilypond centers the *baseline* of the text between the staves, 
which puts the 'center' of the lyrics too high.

To get visually-centered lyrics, the user has to decide what height of text he 
wants to center, and request that the baseline be one text-height closer to the 
lower staff than to the upper, with balanced stretchability :
  \override VerticalAxisGroup #'inter-staff-spacing = #'(
          (space . 4.5) (stretchability . 9) (padding . 0.8))
  \override VerticalAxisGroup #'non-affinity-spacing = #'(
          (space . 3.6) (stretchability . 9) (padding . 1.6))
We could enhance the relevant snippet (http://lsr.dsi.unimi.it/LSR/Item?id=356) 
so that the Lyrics remain centered when the staff is stretched, after 2.14 is 
stable.

So, as I understand the last two messages, it is not always required to keep 
lyrics closer to their associated staff than to the other neighbor staff.   It 
is sufficient to provide enough 'padding to keep lyrics away from 
non-associated notes and dynamics.  That can be done with minor adjustments to 
the overrides already in the Lyrics section of engraver-init.ly
    \override VerticalAxisGroup #'inter-staff-spacing = #'(
      (minimum-distance . 5.5) (padding . 0.5))
    \override VerticalAxisGroup #'non-affinity-spacing #'padding = #1.5


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

Reply via email to