Am Fr., 27. Mai 2022 um 11:22 Uhr schrieb Thomas Morley
<thomasmorle...@gmail.com>:
>
> Hi,
>
> lsr-snippet "Variable bow thickness depending on length"
> https://lsr.di.unimi.it/LSR/Item?u=1&id=1028 looks at 'control-points
> to calculate a modified thickness.
>
> For recent lily-versions this throws
> programming error: cyclic dependency: calculation-in-progress
> encountered for Slur.thickness
> as soon as 'control-points are called in a thickness-override.
>
> Stripped down example:
>
> \version "2.23.9"
>
> {
>   \override Slur.thickness =
>   #(lambda (grob)
>     ;; all of below trigger the programming error
>     (ly:slur::calc-control-points grob)
>     ;(ly:grob-property grob 'control-points)
>     ;((assoc-get 'control-points (ly:grob-basic-properties grob)) grob)
>     2)
>
>   b1( b')
> }
>
> I think I can make it work with an override for 'after-line-breaking
> (calling 'control-points, set 'thickness to the result of calculations
> based on the 'control-points and finally redo setting
> 'control-points).
>
> Is there a better way?
>
> Thanks,
>   Harm

Snippet "Modifying a slur by offsetting the positions property"
https://lsr.di.unimi.it/LSR/Item?u=1&id=748 had a similar problem.
I fixed it in s similar way. (Old code is still there, but commented for now)

Cheers,
  Harm

Reply via email to