[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: partcombine and tag
From: |
David Kastrup |
Subject: |
Re: partcombine and tag |
Date: |
Fri, 22 Apr 2016 16:05:51 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/25.1.50 (gnu/linux) |
Gianmaria Lari <address@hidden> writes:
> I'm trying to understand how to use partcombine and tag and I don't
> understand why compiling the following code I obtain two measures
>
> 4 4 | 4
>
> instead of just one
>
> 4 4 4
>
> In the attached image the resulting score.
>
> Here it is the code.
> %%%
> \version "2.19.40"
>
> note = \partcombine {e'4} {\tag #'pdfOut c4 \tag #'midiOut c'4}
\partcombine runs and creates a common score. Since none of the tags is
removed, the result contains both c4 and c'4. This is stored in \note.
I don't remember: doesn't partcombine complain when given parts of
different length?
> music =
> {
> \time 3/4
> \note \note \note
> }
Here you put three instances in a row.
> \score
> {
> \keepWithTag #'pdfOut \music
The \music has already been partcombined, so there are no traces of any
tags left any more. \keepWithTag doesn't do a thing on music without
tags.
> \layout {}
> }
Basically, you need to use the equivalent of \keepWithTag/\removeWithTag
_before_ running \partcombine. Afterwards, you only have a combined
list of events without any tags left.
It would be nice if \partcombine were rewritten to run just-in-time.
The current implementation runs it when encountered, however. Which
means that it also has no access to context properties and other
niceties.
--
David Kastrup