[Top][All Lists]

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

Re: Scheme function returning \book

From: David Kastrup
Subject: Re: Scheme function returning \book
Date: Wed, 16 Jan 2019 01:09:13 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)

Lukas-Fabian Moser <address@hidden> writes:

>>> \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'?

As long as we don't come up with a satisfactory explanation what it
means to store a book or a bookpart in an expression and use it in one
or more locations, there is no way to sensibly handle the storage and
processing of bookparts independently from their use.

David Kastrup

reply via email to

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