Hi Damian, 

aah, Nick was faster than me... :-)

The easiest way I've found would be this:

% ---------------------------------------------------------------
\version "2.18.0"

#(define-markup-command (sd layout props sdnum) (markup?)
   "Put a number with a carat above the note."
   (interpret-markup layout props
     #{\markup {
       \override #'(baseline-skip . 0.5)
       \column { \small {^ #sdnum }}
       }
     #}))

{g^\markup \sd 3}
% ---------------------------------------------------------------

If you dont want to use "\markup" every time, you also could work like this:

% ---------------------------------------------------------------
\version "2.18.0"

sd = #(define-music-function (parser location sdnum)
        (markup?)
        "Put a number with a carat above the note."
        #{
          -\markup {
            \override #'(baseline-skip . 0.5)
            \column { \small {^ #sdnum }}
          }
        #})

{g^\sd "3"}
% ---------------------------------------------------------------

Cheers, 
Klaus



--
View this message in context: 
http://lilypond.1069038.n5.nabble.com/custom-markup-help-tp176923p176926.html
Sent from the User mailing list archive at Nabble.com.

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

Reply via email to