[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Engraver not getting an event
From: |
Aaron Hill |
Subject: |
Engraver not getting an event |
Date: |
Tue, 02 Apr 2019 04:05:27 -0700 |
User-agent: |
Roundcube Webmail/1.3.8 |
NOTE: I know that \bendAfter currently does not support all of the
usages below; this all is coming from my investigation into how to
enable such support. My plan is to create a patched version of the
engraver in Scheme as a proof-of-concept; and if it works, I can port
the results back to C++ and submit a patch to the project. But I have
hit an unexpected stumbling block...
Please consider the following:
%%%%
\version "2.19.82"
debug_bend_engraver = #(make-engraver
(listeners
((bend-after-event engraver event)
(format (current-error-port)
"\ndebug_bend_engraver: bend-after-event during ~a at ~a"
(ly:context-current-moment (ly:translator-context engraver))
(ly:prob-property (ly:event-property event 'music-cause)
'origin)))))
\layout {
\context {
\Voice
\consists \debug_bend_engraver
}
}
\fixed g' {
g \bendAfter #-4 d2.
<g b>4 \bendAfter #-4 d2.
<g \bendAfter #-4 b>4 d2.
<< { g4 \bendAfter #-4 } { b4 } >> d2.
}
%%%%
I would expect the above to print out a debug line per each
bend-after-event. But oddly the third--the one attached to a note
within a chord--seems to go missing.
Adding in a \displayMusic doesn't really show anything different about
the third usage of \bendAfter. Just like the first and fourth
occurrences, the bend-after-event is part of the articulations for the
corresponding note-events. (The second instance is unique in that the
event is simply stored at the end of the chord's elements.)
It is my understanding that the event-chord-iterator handles
broadcasting all of the chord's elements, and then the
rhythmic-music-iterator will take care of broadcasting the articulations
for the note-events. But that does not seem to be happening.
Where have I gone wrong in my thinking?
-- Aaron Hill
- Engraver not getting an event,
Aaron Hill <=