lilypond-user
[Top][All Lists]
Advanced

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

Edition Engraver and staff changes


From: Partitura Organum
Subject: Edition Engraver and staff changes
Date: Tue, 14 Aug 2018 21:51:57 +0200
User-agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1

Hello all,

In organ music it is quite common that one of the hands plays a part that is either to high or to low for the  'common' clefs, but that can be perfectly rendered with the alto clef. Not many organists are still able to read the alto clef, so I usually make to versions, one with the alto clef, and one with the part distributed over two staves (see images for an example).








Since the notes do not change, only the way they are rendered, I thought it would be a good use case for the edition engraver.  Problem however is that the Edition Engraver references contexts and I cannot tell one context to become another. The command 'change Staff' cannot be used with the Edition Engraver. Below is my (not so minimal) not-working example. Is there a way to tell the Edition Engraver that a part should switch Staff? Or is the Edition Engraver not suitable for my use case (which means that I should continue to do it manually)?


%======================
\include "/oll-core/package.ily"
\loadPackage edition-engraver
%\addEdition alto
\addEdition nonalto
\consistToContexts #edition-engraver Score.Staff.Voice

righthand = \relative c''{
  a2 a |
  b1 |
  c4 b a2\trill
}

lefthand = \relative c'{
  f8 e d c d c b a |
  gis8 a b c d e fis gis |
  a8 a, b cis d d, e fis |
}

pedal = \relative c {
  b2 d  |
  e1  |
  a,2 c
}

lefthandnonalto=\relative c'{
  \clef bass
  \change Staff="right" \voiceTwo f8 e d c d c \change Staff="left" \oneVoice b a |
  gis a b c \change Staff="right" \voiceTwo d e fis gis |
  a \change Staff="left" \oneVoice a, b cis d d, e fis |
}


\editionMod alto 1 0/4 left.Voice.A \clef alto

\editionMod nonalto 1 0/4 right.Voice.A \voiceOne
\editionMod nonalto 1 0/4 left.Voice.A \change Staff="right"
\editionMod nonalto 1 0/4 left.Voice.A \voiceTwo

\score {
  <<
    \new Staff = "right" \with {
          \editionID right
    }
    \new Voice {  \righthand }
  
   \new Staff = "left" \with {
          \editionID left
    }
    %\new Voice { \lefthand}
    \new Voice { \lefthandnonalto}
   
    \new Staff {
      \clef bass \pedal
    }
  >>
}
%===========================================

Regards,
Auke


reply via email to

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