Hullo,
How can I get the XY position of a StaveNote after drawing it? I'd like to draw a green rect over a note to "highlight" it, like below:
ctx.fillRect(x, y, highlightWidth, highlightHeight);
ctx.fill();
But I am having trouble working out where to get the position information.
If it helps, I am creating/drawing my notes like this:
voice = new Vex.Flow.Voice(
num_beats: 6
beat_value: 4
resolution: Vex.Flow.RESOLUTION
);
voice.addTickables(staveNotes);
formatter.joinVoices([ voice ]).format([ voice ], (stave.x + stave.width) - stave.start_x);
voice.draw(ctx, stave);
Thanks.