lilypond-user
[Top][All Lists]
Advanced

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

Re: Sending around contexts


From: Kieren MacMillan
Subject: Re: Sending around contexts
Date: Fri, 29 Oct 2021 14:10:27 -0400

Hi Lukas,

> based on my recent experience with \after, I think it might be reasonable to 
> develop and test something like that outside of the regular codebase, in 
> order to see how it fares in everyday heavy use.

For sure.

> (To be honest, it's not clear to me yet what you're describing.)

Well, we currently have (https://lsr.di.unimi.it/LSR/Snippet?id=357)

%%%  SNIPPET BEGINS  %%%
\score {
  \new PianoStaff = "PianoStaff_pf" <<
    \new Staff = "Staff_pfUpper" << \global \upper >>
    \new Dynamics = "Dynamics_pf" \dynamics
    \new Staff = "Staff_pfLower" << \global \lower >>
    \new Dynamics = "pedal" \pedal
  >>
}
%%%  SNIPPET ENDS  %%%

and I think it would be great if [new] users could rather do something like

%%%  SNIPPET BEGINS  %%%
\score {
  \new PianoStaff = "PianoStaff_pf" <<
    \new Staff = "upper" \with { \sendTo dynamic-event "dynamics" } << \global 
\upper >>
    \new PianoDynamics = "dynamics" #(skip-of-length upper)
    \new Staff = "lower" \with { \sendTo dynamic-event "dynamics" \sendTo 
pedal-event "pedal" } << \global \lower >>
    \new PianoPedals = "pedal" #(skip-of-length lower)
  >>
}
%%%  SNIPPET ENDS  %%%

This would mean that dynamics in either the \lower or \upper variables would be 
centred “automagically”, and pedal markings entered in the \lower variable 
would “automagically” appear below the staff — all without having to use extra 
\dynamics and \pedal variables (with all the required skips, etc.). Obviously 
this doesn’t solve 100% of engraving needs… but likely this would cover the 
vast majority of scores most users want to engrave.

> one of the harder questions is the degree of generality one should strive for.

Absolutely — that’s kind of why (cf. my email to Valentin) I’m thinking we 
should keep discussing it on-list for at least a little while longer.

> I'd love to help, but I should warn that I'm clearly the least experienced of 
> all the people with merge privileges (which I only obtained a few weeks ago). 
> On the other hand, the great thing about this development model is that you 
> never have to rely on one person alone.

Great! Onward and upward.  =)
Kieren.
________________________________

Kieren MacMillan, composer (he/him/his)
‣ website: www.kierenmacmillan.info
‣ email: kieren@kierenmacmillan.info




reply via email to

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