Hello,

I'm typesetting a work and really want to preserve its notational
idiosyncrasies. One of them is an alternating way of using time signatures.
The attached MWEish does exactly what I want. The question, for me, is if
this could be done in a simpler way (just for learning!).

[image: image.png]
Thanks in advance!
F.
 \version "2.25.15"
 
\layout {
  \context{
    \Staff
    \name TopStaff
    \alias Staff
  }
  \context{
    \Staff
    \name BottomStaff
    \alias Staff
  }
  \context{
    \Staff
    \name MidStaff
    \alias Staff
  }  
  \context { \Score      \accepts TopStaff \accepts BottomStaff \accepts MidStaff }
  \context { \StaffGroup \accepts TopStaff \accepts BottomStaff \accepts MidStaff }
}  
  
\midi {
  \context {
    \Staff
    \name TopStaff
    \alias Staff
  }
  \context{
    \Staff
    \name BottomStaff
    \alias Staff
  }  
  \context{
    \Staff
    \name MidStaff
    \alias Staff
  }    
  \context { \Score      \accepts TopStaff \accepts BottomStaff \accepts MidStaff }
  \context { \StaffGroup \accepts TopStaff \accepts BottomStaff \accepts MidStaff }
}  

TSScore = { 
  \override TopStaff.TimeSignature.outside-staff-priority = #0
  \override TopStaff.TimeSignature.direction = #UP
  \override TopStaff.TimeSignature.break-align-symbol = #'staff-bar
  \override TopStaff.TimeSignature.font-size = #-2
  \override TopStaff.TimeSignature.break-visibility = ##(#f #t #t)
  \override BottomStaff.TimeSignature.outside-staff-priority = #0
  \override BottomStaff.TimeSignature.direction = #DOWN
  \override BottomStaff.TimeSignature.break-align-symbol = #'staff-bar
  \override BottomStaff.TimeSignature.font-size = #-2
  \override BottomStaff.TimeSignature.break-visibility = ##(#f #t #t)
  \omit MidStaff.TimeSignature
}

TSStaff = { 
  \revert TopStaff.TimeSignature.outside-staff-priority
  \revert TopStaff.TimeSignature.direction
  \revert TopStaff.TimeSignature.break-align-symbol
  \revert TopStaff.TimeSignature.font-size
  \revert TopStaff.TimeSignature.break-visibility
  \revert BottomStaff.TimeSignature.outside-staff-priority
  \revert BottomStaff.TimeSignature.direction
  \revert BottomStaff.TimeSignature.break-align-symbol
  \revert BottomStaff.TimeSignature.font-size
  \revert BottomStaff.TimeSignature.break-visibility
  \undo \omit MidStaff.TimeSignature  
}

ts = {
  \TSStaff \time 4/4 s1
  \TSScore \tempo "Allegro" \time 3/4 s2. 
  \TSStaff \time 6/8 \tempo "Adagio" s2. 
  \TSScore \time 2/4 \tempo "Allegretto" s2
  \time 2/2 s1 
  \time 6/4 s1. 
  \TSStaff \time 4/4 s1
  \time 3/4 s2. 
}
 
notesOne = \repeat unfold 58 { c'8 } 
notesTwo = \repeat unfold 58 { c'8 } 
notesThr = \repeat unfold 58 { c'8 } 

\score {
  \new StaffGroup {
  <<
    \new TopStaff = "one" <<\new Voice { << \ts \notesOne >> } >> 
    \new MidStaff = "two" <<\new Voice { << \ts \notesTwo >> } >> 
    \new BottomStaff = "thr" <<\new Voice { << \ts \notesThr >> } >> 
  >>
  } 
  \layout{}
  \midi {}
}

Reply via email to