denemo-devel
[Top][All Lists]
Advanced

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

Re: [Denemo-devel] Book with Denemo


From: Richard Shann
Subject: Re: [Denemo-devel] Book with Denemo
Date: Thu, 05 May 2016 14:44:58 +0100

On Thu, 2016-05-05 at 11:24 +0200, Andreas Schneider wrote:
> Am 05.05.2016 um 11:00 schrieb Richard Shann:
> > On Wed, 2016-05-04 at 22:18 +0200, Andreas Schneider wrote:
> >> I want to make a small book with Denemo. How can I place a Lilypond
> >> \book { ... } context around the whole score (i.e. around all
> >> movements)? I guess I have to create some score directive, but how exactly?
> > 
> > I'm not sure of the answer to that off hand, 

Well, this puts a \book { before the first movement and } after the
last:

(d-PushPosition)
(while (d-PreviousMovement))
(d-DirectivePut-score-prefix "test" "\\book {\n")
(while (d-NextMovement))
(d-DirectivePut-movementcontrol-postfix "test" "\n}%end of book \n")
(d-PopPosition)

It would need a bit of further work to make it into a proper command -
if you added a further movement it would need to find the old end of
book and move it, (so setting the DENEMO_OVERRIDE_DYNAMIC override field
would probably be good and making it look for whether it was already
present), but before getting to that I see some peculiarities:

The 

#(set-default-paper-size "a4")
#(set-global-staff-size 18)

are issued by hard-wired code using the values in the  built in score
properties. These are *inside* the \book { which appears to make a
difference, though I don't understand quite what difference it is.
If you can experiment with this and find out whether it makes more sense
to move the d-DirectivePut-score-prefix output to immediately before the
\score then I should be able to move it.
The second thing I notice is that the \paper {} block is emitted after
this \book {  though that doesn't appear to affect the output. But again
it would be good to know where the \paper {} block *should* come.

Lastly, it is ugly that the closing of the \book { is being placed after
the last movement, it should be possible to do it with a
d-DirectivePut-score-postfix so that it would continue to work even when
further movements are added. It should be possible to arrange for this
by overriding the default placing of the output(*). If you can say this
is useful code to be able to add I can do this. One possibility, however
is that we just build it in to Denemo's LilyPond output that the \book
{ } is explicitly output for every Denemo score. (Or would it sometimes
be desirable to put several \book { } 's around groups of movements in a
Denemo score???)

Richard
(*) by default d-DirectivePut-score-postfix is output in every movement
after the start of the \score block, before the music.





reply via email to

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