Hello,
With more trial and error than wisdom, I've managed to create a function to
attach an X to a note and tweak its position % \vibesDamper #'(0 . 0) note
%. This X between notes is a dampening notation for vibraphone. I'm really
happy with it, since I shall use it a lot.

One improvment I can think of now is to have it auto aligned with the note's
body (like, in the middle of the stem) and have the position tweak as an
optional parameter. How complex is this task? I feel I need some directions.

Here is my working script (which probably can be better written)

%%%

vibesDampX =
#(define-music-function (note) (ly:music?)
   (set! (ly:music-property note 'articulations)
         (cons
          (make-music
           'TextScriptEvent
           'direction 1
           'text
           (markup
            #:line
            (#:musicglyph "noteheads.s2cross")))
          (ly:music-property note 'articulations)
          ))note )

vibesDamper=
#(define-music-function (offset note) (pair? ly:music?)
   #{
     \once \override TextScript.extra-offset = #offset
     \vibesDampX #note
   #})

%%%



--
Sent from: http://lilypond.1069038.n5.nabble.com/User-f3.html

_______________________________________________
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user

Reply via email to