One checkbox for every staff in score?

• Jul 9, 2016 - 13:05

Hi,

I am trying to write a plugin which should batch export several staffs of a score to their own mp3 as well as create an mp3 which combines all staffs.

I would like to add one checkbox for every staff, so the user can select which staffs should be exported to mp3.

However, this requires a variable number of checkboxes. I don't think it 's possible to have this backed by eg. a ListModel, like you would do with a combobox?

Does anyone have an idea how this can be done, or is there a way other than using checkboxes?

Thank you very much in advance!


Comments

I created two little demo plugins:

The first one uses a ListModel (CheckBoxListDemo.qml)
That's probably easier than using the dynamic object creation, although that's possible as well (DynamicCheckBoxDemo.qml)

CheckBoxListDemo allows to dynamically add checked or unchecked checkboxes and to list the state of all created checkboxes on the console. You can run it from inside the Plugin Editor.

DynamicCheckBoxDemo only adds checkboxes and prints a message on the console if a checkbox is clicked. Also to be run from inside the Plugin Editor.

Attachment Size
CheckBoxListDemo.qml 2.65 KB
DynamicCheckboxDemo.qml 2.49 KB

A plugin will save a couple of clicks but what about creating parts for every combination possible you want, possibly using "New All", and then export the parts to MP3 using File > Export parts? not sure if a plugin can make this easier.

Do you still have an unanswered question? Please log in first to post your question.