[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Catch direction operators
From: |
Paul Morris |
Subject: |
Re: Catch direction operators |
Date: |
Tue, 8 Oct 2013 18:52:32 -0700 (PDT) |
David Kastrup wrote
> Looks fine. \colorizeDir is not actually being used as a tweak here,
> but then that makes pretty little sense anyway.
Ok, I've added it here:
http://lsr.dsi.unimi.it/LSR/Item?id=889
Since it requires 2.17 I had to comment out the whole thing, and add a
single note to get the LSR to accept it.
I also split colorizeDir up into two parts, as shown below. This seemed
easier to understand and avoids (re-)defining grob-colorize-dir for every
grob that gets colored. Let me know if that's not a good call.
HTH,
-Paul
#(define (grob-colorize-dir grob)
(let ((ev (event-cause grob)))
(case (and ev (ly:event-property ev 'direction))
((1) red)
((-1) blue)
(else '()))))
colorizeDir =
#(define-music-function (parser location item)
(symbol-list-or-music?)
#{ \tweak color #grob-colorize-dir #item #})
--
View this message in context:
http://lilypond.1069038.n5.nabble.com/Catch-direction-operators-tp151552p152012.html
Sent from the User mailing list archive at Nabble.com.