On 14 April 2018 at 15:15, David Kastrup <d...@gnu.org> wrote:

> Gianmaria Lari <gianmarial...@gmail.com> writes:
>
> > I don't understand the behaviour of this code:
> >
> > \version "2.19.81"
> > var = {a \tag #'here {b} a}
> > {\var} %Result: a b a
> > {\removeWithTag #'here \var}  %Result: a a
> > {\pushToTag #'here b! \removeWithTag #'here \var}  %Result: a a ;
> Expected:
> > a b! a
> >
> >
> > The result is:
> >
> > a b a - ok!
> > a a - ok!
> > a a - not ok; shouldn't be "a b! a" ??
>
> \removeWithTag removes the tagged expression.  Which includes the tag
> itself.
>

This was what I was afraid of :)

Any idea how I can obtain the same effect? I would like to be able to
substitute a note in a variable with another one.
Of course I could use "\pushToTag ... noteA" when I need noteA and  "\pushToTag
... noteB" when i need noteB but I would like that my variable make sense
also when I don't use \pushToTag command.
Thank you, g.
_______________________________________________
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user

Reply via email to