Access the default note colors in qml?

• Jul 9, 2019 - 20:17

Is there a way to access the 4 default note colors (blue, green, red, violet) from within qml?
Haven't found any solution...

Thanks, Harry


So the real answer is, the default colors are not accessible, but as soon as someone changed their color, then it is.

In reply to by jeetee

yepp - apparently no clean way to access these colors...
In MS 2 you could access them via Musescore2.ini (selectColor1/2/3/4) - ugly
In MS 3/Musescore3.ini you have just score\voice1\color (2/3/4) which initially just contains black, which doesn't help

Thanks anyway

In reply to by marlovitsh

It doesn't initially contain black.
It initially doesn't exist in the ini-file, you trying to access it within the Qt.labs.settings object creates the entry. Creating an entry without arguments means creating a default object for it. As the setting is defined as a color, it creates the default color. Which is black.

If MuseScore would simply write it's default color to the file, and not only after changing it, you wouldn't have an issue.

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