Thomas Morley <thomasmorle...@gmail.com> writes: > Hi Marc, > > two Problems: > (1) > A postevent can't be attached to a music-variable, this feature will > be likely be available with next stable.
Well, next unstable anyway but I think I'll pull this one into the stable branch since it otherwise is too much of a candidate for the "experienced user gives advice to less experienced user and did not realise it doesn't work with stable" kind. And there's been no complaint about it for the people using/testing master. > (2) > afterGrace expects _two_ musical arguments. > Your code >> #{ >> \afterGrace >> $firstNote >> \glissando >> \once \override Stem.stencil = ##f >> \once \override Flag.stencil = ##f >> \parenthesize $secondNote >> #} > > provides $firstNote as first argument and \glissando as the second. > (And there is an optional argument for the `fraction´) This one will not be affected by the post-event sweep-up that should help with point 1. > You will want to have a first-note-with-starting-glissando as first argument > and > a parenthesize-second-note-with-overrides as second. Thus use brackets: > > bendDown = > #(define-music-function > (parser location firstNote secondNote) > (ly:music? ly:music?) > #{ > \afterGrace 15/16 > { > <>\glissando > $firstNote > } > > { > \once \override Stem.stencil = ##f > \once \override Flag.stencil = ##f > \parenthesize $secondNote > } > #} > ) Not a fan of using overrides in such situations since they might affect unrelated notes/constructs. I prefer tweaks here, like \parenthesize \single \omit Stem \single \omit Flag $secondNote All the best -- David Kastrup _______________________________________________ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user