[Top][All Lists]

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

Re: bookparts

From: Graeme Lee
Subject: Re: bookparts
Date: Mon, 5 Mar 2018 16:03:39 +1100
User-agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0

Hi Noeck.

On 5/03/2018 4:09 AM, Noeck wrote:

I need some further insights in what a bookpart is.
I've read the doc but it is very short on the issue:
My understanding from try and error is this (and I would be happy if you
could correct me or confirm the statements):

\paper blocks inside a \bookpart only affect this bookpart, while \paper
blocks outside affect everything. So it seems to be a scoping for paper

Q: Is it correct that the bookpart is a scope for paper blocks?
It overrides its parent \paper block in \book
If I put a \layout block in a \bookpart, lilypond complains and says:
Für Papier-Block wird \paper benötigt
(\paper needed for paper block) – whatever that means ...

Q: Is it correct that \layout blocks don't belong inside a \bookpart?

Here's a working example.  Full header on :

  \bookpart {
    \header {
      instrument = \markup { \smallCaps "Violin I" }
    \paper {
      oddHeaderMarkup = \markup {
        \column {
          \fill-line {
            \on-the-fly #not-single-page
            \fromproperty #'header:instrument
          " "
      evenHeaderMarkup = \oddHeaderMarkup
    \score {
      \new StaffGroup \keepWithTag #'vnp \Imusic
      \layout {
        \context {
          \override MultiMeasureRest.expand-limit = #2
          \override MetronomeMark.self-alignment-X = #0.2
          \override MetronomeMark.padding = #2
        \context {
          \Staff \override InstrumentName #'stencil = ##f
I can define variables at top-level and use them in any boobpart. But
defining a variable inside a bookpart fails ("Error: syntax error,
unexpected SYMBOL").

Q: Is it correct that I can't define a variable inside a bookpart?
Q: That means if I have many scores with many voices in my document,
    I need unique names for all of them and can not reuse \soprano for
    the next piece with different content?
Maybe explore using tags for your voices?

As my included files contain definitions, I cannot include them inside a
bookpart as far as I understand. So I need to put them at top level, right?

Q: Included files just behave as if the content was inserted at the same
Q: Includes must be at top level?

When does a \paper block apply? The order of score and \paper block
doesn't seem to decide upon it. From the example below I am puzzled why
the top-level paper block applies to the second score but not to the
first. It is after all scores but on top-level. Shouldn't it affect
either both or none?

The first score overrides the top level \paper block with its own.
*What I want to achieve* is to have ~10 independent pieces and
concatenate all of them into one book as well as printing everyone on
its own. The separate pieces should have taglines etc. on the first/last
page as usual. But the book should not repeat them for every piece. Each
piece should start a new page in the book. I dreamed of just including
all the scores into one document. But the output is terrible (errors as
the ones above etc.).

Q: Should I use bookparts at all or just \pageBreaks?

Thanks for reading until here! :)


\bookpart {
   \paper {
     left-margin = 8\cm

   \markup "ASD"
   \score {  { a } }

\bookpart {
   { b }
   \header {
     title= "Title"

\paper {
   top-margin = 5\cm

lilypond-user mailing list

reply via email to

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