lilypond-user
[Top][All Lists]
Advanced

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

Re: mixed piano bracket style


From: Valentin Petzel
Subject: Re: mixed piano bracket style
Date: Fri, 28 Jan 2022 22:17:04 +0100

Hello Michael,

Nothing about the Dynamics context, I just messed up the code for the part if 
there is no break (why did I not test this?). The appended file fixes this.

Also if you want this as a general style it is probably better to put it into 
a layout or a with block.

Cheers,
Valentin

Am Freitag, 28. Jänner 2022, 21:17:21 CET schrieb Michael Rivers:
> Thanks, Valentin. That looks great. However, when I use it in a Dynamics
> context, I get an error message. Is there something else I would need to do
> to transplant this to a Dynamics context? I appreciate the work you did to
> make this.
> 
> Best,
> Michael
> 
> \version "2.23.5"
> 
> right = \relative c'' {
> 
> }
> 
> left = \relative c' {
>   c1 | c1 |
> 
> }
> 
> ped = {
>   \override Dynamics.PianoPedalBracket.edge-height = #'(0 . 0)
>   \override Dynamics.PianoPedalBracket.stencil =
>   #(grob-transformer 'stencil
>      (lambda (grob orig)
>        (let* ((star (grob-interpret-markup grob (markup #:musicglyph
> "pedal.*")))
>               (gr_orig (ly:grob-original grob))
>               (sibs (if (ly:grob? gr_orig) (ly:spanner-broken-into gr_orig)
> '())))
>          (if (and (ly:grob? gr_orig) (eq? grob (last sibs)))
>            (ly:stencil-combine-at-edge orig X RIGHT star -0.82)
>            orig))))
>         \set Dynamics.pedalSustainStyle = #'mixed
> 
>         s1\sustainOn |
>         s\sustainOff |
> }
> 
> \score {
>   \new PianoStaff <<
>     \new Staff = "right" \right
>     \new Staff = "left" { \clef bass \left }
>     \new Dynamics \ped
> 
> }
> 
> Drawing systems...
> C:/Users/micha/AppData/Local/Temp/frescobaldi-c_q44hr8/tmpgtfg9hts/document.
> ly:20:48 <0>: In procedure last in expression (last sibs):
> 
> C:/Users/micha/AppData/Local/Temp/frescobaldi-c_q44hr8/tmpgtfg9hts/document.
> ly:20:48 <1>: Wrong type argument in position 1 (expecting pair): ()
> 
> Exited with return code 1.
> 
> On Thu, Jan 27, 2022 at 5:37 PM Valentin Petzel <valentin@petzel.at> wrote:
> > Hello Michael,
> > Could something like this work?
> > 
> > Cheers,
> > Valentin
> > 
> > Am Donnerstag, 27. Jänner 2022, 23:13:49 CET schrieb Michael Rivers:
> > > Does anyone know if there was ever an answer to this? I’m re-engraving a
> > > score that has a piano pedal style with “Ped”, then a solid line, then a
> > > “*” at the end. It’s close to “mixed” style but with an added “*” at the
> > > end.
> > > 
> > > 
> > > 
> > > Thanks in advance,
> > > 
> > > Michael

Attachment: SP-line.ly
Description: Text Data

Attachment: signature.asc
Description: This is a digitally signed message part.


reply via email to

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