Hi all,
I came up with the following code to color certain notes grey and make
them smaller, to mark them as optional. (It's for playing fast fiddle
tunes on trumpet, where I have to strategically drop notes to keep up.)
I thought about submitting it to the LSR, but it uses 2.19.x
functionality like \etc . So I thought I'd post it here for now.
Anything I'm missing that would improve it?
Cheers,
-Paul
\version "2.19.63"
makeGrey =
#(define-scheme-function
(n) (number?)
(rgb-color n n n))
makeNoteModifier =
#(define-music-function
(size color music) (number? color? ly:music?)
#{
\override NoteHead.color = #color
\override Stem.color = #color
\override Flag.color = #color
\override Dots.color = #color
\override Accidental.color = #color
\override NoteHead.font-size = #size
\override Accidental.font-size = #size
#music
\revert NoteHead.color
\revert Stem.color
\revert Flag.color
\revert Dots.color
\revert Accidental.color
\revert NoteHead.font-size
\revert Accidental.font-size
#})
opt = \makeNoteModifier -2 \makeGrey 0.75 \etc
blueNote = \makeNoteModifier 0 #blue \etc
\fixed c' {
c8 \opt d e \opt fis
g \opt { a bes c }
c4. \opt c4. c4
\blueNote c16 r c16 r r2.
}
_______________________________________________
lilypond-user mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/lilypond-user