Display the note names only the selected notes ?
I'm trying to make the plugin that display the note names only the selected notes.
After making 'blue rectangles' select "Note Names-Selection" menu, but only one note displays at the begining of the blue rectangle.
noteNamesSelection.js
function init(){}
function run(){
var cursor = new Cursor(curScore);
cursor.goToSelectionEnd();
var endStaff = cursor.staff; // Value of endStaff is always zero.
cursor.goToSelectionStart();
var startStaff = cursor.staff;
for(var i=startStaff;i
References are
http://musescore.org/en/plugin-development/how-plugin-development
http://musescore.org/en/plugin-development/cursor-object
Attachment | Size |
---|---|
noteNamesSelection.js_.zip | 1.66 KB |
Comments
Look at the note names plugin from the repository, I'm pretty sure it does what you're trying to achieve (and more).
Also the how-plugin-development doc shows a working example
In reply to Look at the note names plugin by Jojo-Schmitz
Thank you.
I carefully looked at those sources.
But "cursor.goTo SelectionEnd()" does not work well yet.
In reply to Thank you. I carefully looked by tcbnhrs
The problem of the selected area has fixed.
I learned from the Cue Notes plugin.
http://musescore.org/en/project/cue
Summary
var currentCursor = new Cursor(curScore);
var selectionEnd = new Cursor(curScore);
while (currentCursor.tick() < selectionEnd.tick()) {
currentCursor.next();
}
Modification of the Plugin is now complete.
Start the "Shakuhachi Notation" from Plugins menu, and you can select the Shakuhachi length, fonts, font size and font position.
Fingering of only the selected area can be displayed.
Also support the chord.
Thank you.