lilypond-user
[Top][All Lists]
Advanced

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

Re: Changing context plugins


From: David Sumbler
Subject: Re: Changing context plugins
Date: Sat, 10 Dec 2016 17:32:34 +0000

On Mon, 2016-12-05 at 23:11 +0100, Thomas Morley wrote:
> 2016-12-05 16:29 GMT+01:00 David Sumbler <address@hidden>:
> 
> > 
> > But two questions have occurred to me arising out of this.
> > 
> > 1) Plug-ins for most contexts can be added or removed either in a
> > \layout block, as above, or when creating the context, e.g.
> > 
> > \new \Staff \with { consists Mark_engraver }
> This is invalid syntax, you probably meant:
> \new Staff \with { \consists Mark_engraver }
> 
> > 
> > 
> > But this second method can't, so far as I can see, be used with a
> > Score
> > context, because '\new \Score' is not allowed.  Can Score plug-ins
> > only
> > be added or removed within a \layout block?
> '\new \Score' is invalid syntax as well, but
> 
> \new Score \with { \remove "Mark_engraver" }
> <<
> \new Staff
>   \relative c'' { c4 \mark \default s c2 }
> \new Staff \with { \consists "Mark_engraver" }
>   \relative c'' { c4 s \mark \default c2 }
> > 
> > > 
> > > 
> works fine. Though, it could easily be written like:
> 
> \score {
>   <<
>   \new Staff
>     \relative c'' { c4 \mark \default s c2 }
>   \new Staff \with { \consists "Mark_engraver" }
>     \relative c'' { c4 s \mark \default c2 }
>   >>
>   \layout {
>     \context {
>       \Score
>       \remove "Mark_engraver"
>     }
>   }
> }
> 
> I vagely remember discussions about the topic years ago. Everyone
> agreed, so the possibility to write
> \new Score \with ...
> is not mentioned anywhere at all, but still valid syntax.
> 
> > 
> > 
> > 2) More importantly, is it possible to change these settings at an
> > arbitrary point in the music, i.e. after the context has been
> > created?
> Nope, not for the engravers being in the context or not.
> You have to go for properties of context/grob/whatever read/written
> by
> the relevant engravers.
> 
> Cheers,
>  Harm

Thanks for this reply and also to Carl for his reply with similar
information - even though the answer to my question was not the answer
I was hoping for!

Sorry about the syntax errors - that was just carelessness on my part.

David



reply via email to

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