[Top][All Lists]

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

Re: edition-engraver and multiple scores

From: Jan-Peter Voigt
Subject: Re: edition-engraver and multiple scores
Date: Tue, 03 Apr 2018 16:07:45 +0200
User-agent: K-9 Mail for Android

Hi Urs,

I am not at my desk right now, but IISC you named the right thing: Every score needs its own ID so that the EE is able to target the right score.
We might *additionally* store mods as a Score context prop. for certain use cases. But still I strongly vote for IDs per score.


Am 3. April 2018 11:34:58 MESZ schrieb Urs Liska <address@hidden>:

I ran into an issue with the edition-engraver, targeting individual scores when multiple scores are compiled within a bookpart.

It's actually within the 'page-layout' or rather the 'breaks' openLilyLib package, and I can imagine that my issue is related to another one that was raised recently (that either of these packages didn't work well with independent edition-engraver targets).

The 'breaks' package ( installs itself like this:

% Install editionID
\layout {
  \context {
    \editionID ##f breaks

which can later (e.g. in the page-layout.conditional-breaks package: be addressed with (for example)

       % insert invisible barlines to enable breaks within measures
       \editionModList conditional-breaks breaks.Score.A
       \bar "" #in-measure-breaks
This works perfectly - as long as there is only one score to be compiled. However, if more than one score is compiled (at least in the same bookpart) it seems that all the mods for all scores are merged together, with the result that in each score all the line breaks for all scores are applied.

Am I understanding it right that I would have to use \editionID in a layout block that only affects an individual score, giving them individual names?

And how could I do that if I don't have a literal \score {} block but generate the scores like the following (

         workgroup-book ; a \book {} object
         #{ \paper {} #}  ; non-functional, placeholder
         $defaultlayout ;; merged from all layout definitions

where 'workgroup-book' is a \book to which multiple bookparts are added with

   (ly:book-add-bookpart! workgroup-book
       (let ((movements (get-movement-list work-path)))
              (map (lambda (mvt)
                     (list (makeMovementTitle (append work-path (list mvt)))))
              (map (lambda (mvt)
                    (make-score (append work-path (list mvt))))
where a list of alternating title markups and scores are added to the bookpart, and the scores are created with (at its core)
         (make-music 'SimultaneousMusic 'elements
            (lambda (l) (not (null? l)))
            (map (lambda (elt) (staff elt)) elements))))

So IIUC it boils down to the question: how can I apply \editionID (or some equivalent code) to a score that is created with ly:make-score. As far as I have seen ly:make-score will only accept the music _expression_ and not the \layout {} or \midi {} blocks I can nest within a \score {} written in LilyPond language.
And: if I manage to "install" an edition ID within that _expression_, is it true that I can later address this score specifically?

Thanks for any hints or explanations

Diese Nachricht wurde von meinem Android-Gerät mit K-9 Mail gesendet.

reply via email to

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