I like to print solfege ( d r m f s l t) on to the note-head. The following snippet print numbers onto the note-head. Is it possible to adapt the following snippet to print solfege onto the note-head?

I don't know if it is want you want :
(and thanks to Frescobaldi to the automatic indentation ...)

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
#(define EzSolfegeEngraver#(define EzSolfegeEngraver
   (list
    (cons 'acknowledgers
      (list
       (cons 'note-head-interface
         (lambda (engraver grob source-engraver)
           (let* ((context (ly:translator-context engraver))
                  (tonic-pitch (ly:context-property context 'tonic))
                  (tonic-name (ly:pitch-notename tonic-pitch))
                  (delta (- 7 tonic-name))
(solfege-base (circular-list "S" "O" "L" "F" "E" "G" "E"))
                  (solfege (take (drop solfege-base delta) 7))
                  (note-names (apply vector solfege)))
             ; (display solfege)(newline)
             (ly:grob-set-property! grob 'note-names
               note-names))))))))
EzNum = {
  \easyHeadsOn
  \override Staff.StaffSymbol #'staff-space = #1.5 %1.4
  \override Staff.StaffSymbol #'line-thickness = #1.5 %1.4
  \override Staff.NoteHead #'font-size = #+3.2 %=3.0
  \override Staff.Clef #'font-size = #+1.35 %1.25
  \override Staff.TimeSignature #'font-size = #+1.35 %1.25
  \override Staff.Accidental #'font-size = #+1.35 %1.25
  \override Voice.NoteHead #'font-size = #-5.25 %-5.0
}

global = {  \key c\major \time 4/4 }
mux = \relative c' { \global \EzNum
                     c4 d e f g a b4 r
                     \key f\major
                     f g a bes c d e r
                     \key g\major
                     g, a b c d e fis r
}
\score {
  \new Staff { \mux}
  \layout {
    \context {
      \Voice
      \consists \EzSolfegeEngraver
    }
  }
}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%






--
Gilles

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

Reply via email to