Kieren MacMillan <[EMAIL PROTECTED]> writes: > What I want to get is > > (make-music > 'SequentialMusic > 'elements > (list (make-music 'ContextSpeccedMusic ...) > (make-music 'EventChord > 'elements > (list (make-music 'NoteEvent ...) > (make-music 'AbsoluteDynamicEvent ...)))))
So here you can see that, having an EventChord, you have to build a SequentialMusic expression, containing a ContextSpeccedMusic element for the property override, and the modified EventChord. %% not tested addDynText = #(define-music-function (parser location dyn text event-chord) (string? string? ly:music?) ;; add the AbsoluteDynamicEvent to the EventChord (set! (ly:music-property event-chord 'elements) (cons (make-music 'AbsoluteDynamicEvent 'text (markup #:dynamic dyn #:normal-text #:italic text)) (ly:music-property event-chord 'elements))) ;; return a SequentialMusic with a ContextSpeccedMusic ;; and the modified EventChord (make-music 'SequentialMusic 'elements (list (make-music 'ContextSpeccedMusic 'property-operations '() 'context-type 'Bottom 'element (make-music 'OverrideProperty 'once #t 'grob-property-path (list 'X-offset) 'grob-value -1.5 'symbol 'DynamicText 'pop-first #t)) event-chord))) _______________________________________________ lilypond-devel mailing list lilypond-devel@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-devel