A bookpart cannot contain statements like

music = { c'1 }

After the include processing, your file test.ly begins with something like:

\bookpart {
  music = { c'1 }
  \score { \music }
}

whereas, you should have

music = { c'1 }
\bookpart {
  \score { \music }
}

On 29/12/17 18:35, Shane Brandes wrote:
o.k. back to the include with book part problem. Here is my almost
minimal code example, which consists of files a.ly, b.ly and test.ly.
The two files compile alone correctly but when stuck in the bookpart
they go to pieces. I even tried it running lilypond-book as a tex file
which interestingly yields no page break but otherwise identically
incorrect.

%--- file a.ly
\version "2.17.97"

\header {
   title = "a"

}




righteOne = \relative g' {
     \clef "treble"
         g8
     }


righteTwo = \relative a' {

     d2
     }

lefteOne = \relative c' {
     \clef "bass"
     }

lefteTwo =  \relative a, {
     \clef "bass"  r2

     }


\score {
   \new PianoStaff \with {
     instrumentName = "Organ"
   } <<
     \new Staff = "right"  << \righteOne \\ \righteTwo >>
     \new Staff = "left"  { \clef bass << \lefteOne \\ \lefteTwo >> }
   >>
   \layout { }

}

%--- file b.ly

\version "2.17.97"

\header {

   title = "b"

}


\layout {
   \context {
     \Score
     \remove "Bar_number_engraver"
   }
}



rightTwo = \relative c'' {


r2
}

rightOne = \relative c'' {

   a2.
}

leftOne = \relative c' {

  a2.
}

leftTwo = \relative c' {


}

pedal = \relative c {

  c4 }

\score {
   <<
     \new PianoStaff \with {
       instrumentName = "Organ"
     } <<
       \new Staff = "right"  << \rightOne \\ \rightTwo >>
       \new Staff = "left"  { \clef bass << \leftOne \\ \leftTwo >> }
     >>
     \new Staff = "pedal"{ \clef bass \pedal }
   >>
   \layout { }

}

%---- bookpart test.ly

\bookpart {\include "a.ly"}
\bookpart {\include "b.ly"}


--
Timothy Lanfear, Bristol, UK.


_______________________________________________
lilypond-user mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/lilypond-user

Reply via email to