adding note in plugin: sound ok, but not display
I try to add notes from a plugin in musescore 2.0. So far I manage to make them play a give midi pitch (concert note?), but the note displayed is not matching.
How do I modify the displayed note from the plugin? or better: how to properly add a note from a plugin to not run into that issue at all?
code excerpt, that is repeated for various pitch (eg 40, 52, 64) at different cursors positions:
var tempChord = newElement(Element.CHORD);
var tempNote = newElement(Element.NOTE);
tempNote.pitch=pitch; //music played is ok, but note are strangely always displayed as Bbb
tempNote.tpc=harmony.rootTpc; //seems to have no effect, how to fix note position?