lilypond-user
[Top][All Lists]
Advanced

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

Re: Centering markup between staves


From: Simon Albrecht
Subject: Re: Centering markup between staves
Date: Fri, 25 Sep 2015 12:47:29 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.2.0

Hello Robert,

On 25.09.2015 01:17, Robert Clausecker wrote:
Hello all!

I'm currently trying to transcribe an organ score [1] which notes register
changes between the two staves for the left and right hand. For æsthetic
reasons, these annotations should be vertically centred precisely between
the two staves.

Here’s a really nice version which uses the Stanza_number_engraver (normally used in Lyrics contexts) to place the clavier indication before the moment for which it applies. Besides, this fortunately ensures perfect alignment with the dynamic following.
Also, the \general-align markup command helped simplify the code.

%%%%%%%%%%%%%%%
\version "2.19.27"
regR = \markup \general-align #Y #0 {
  \normal-text { R }
  \override #'(font-encoding . fetaBraces) \lookup #"brace60"
}

\score {
  \new PianoStaff <<
    \new Staff \relative c' {
      c4 d e f |
      g a b c |
    }
    \new Dynamics \with {
      \override DynamicText.self-alignment-Y = 0
      %\override TextScript.self-alignment-Y = 0
      \consists Stanza_number_engraver
    } {
      \set stanza = \regR s1\p
    }
    \new Staff \relative c {
      c4 d e f |
      g a b c |
    }
  >>
}
%%%%%%%%%%%%%
I hope this also work in more complicated situations.

Yours, Simon



reply via email to

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