lilypond-user
[Top][All Lists]
Advanced

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

Re: Scheme function returning \book


From: Lukas-Fabian Moser
Subject: Re: Scheme function returning \book
Date: Wed, 16 Jan 2019 00:46:27 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.2.1


\version "2.19.82"

test = #(define-scheme-function (suffix) (string?)  #{
   \book {
     \bookOutputSuffix #suffix
     \score {
       d4
     }
   }
#} )

\test "surname"

(still) causes a "Bad expression type" error.
Ah, well.  Turns out that copying the code for \xxx here where \xxx was
a book identifier was not really a good idea before anybody figures out
and defines the difference between a book and a bookpart.  Currently it
is not viable to distinguish them.

\book { \test "surname" }

could conceivably just close its eyes and say "ok, let's treat it as a
book rather than a bookpart" but doesn't.  Does anybody have an idea
what is supposed to distinguish a book from a bookpart outside of actual

\book {
   \bookpart { ... } }

usage?

I suspect that I do not understand the question correctly; at least I certainly do not understand the technicalities involved.

For me, as a user, the point is just that a book generates a stand-alone file whose filename can be defined indepentently of everything else. (Also, I noticed that whereas bookparts can have their own \paper blocks, it seems that the generated pdf has one paper size for all which is filled to varying degrees?)

But am I right in thinking that your question pertains to inherent structural properties of the generated expressions so they can be distinguished to be of one type or the other in an internal representation that does not sport a label 'book'?




reply via email to

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