Porting plugins to MuseScore 4.4
How to check for museScore version in 4.4?
In the updated CourtesyAccidentals plugins in
https://github.com/musescore/MuseScore/commits/7fe32bacbc9287b716d40462…
i see that this check has been disabled.
*if (mscoreMajorVersion == 3 && mscoreMinorVersion == 0
&& mscoreUpdateVersion < 5) {
versionError.open();
}*
Is this because this does not work anymore?
Comments
No, that check just isn't needed on Mu4, as that condition will never be met
In reply to No, that check just isn't… by Jojo-Schmitz
Ok. Sorry.
The checks still work e.g.
if ((mscoreMajorVersion == 4 && mscoreMinorVersion < 4 ))
But if there exists this code in the plugin (Walkingbass)
MessageDialog
{
id: versionError
visible: false
title: qsTr("Unsupported MuseScore Version")
text: qsTr("This plugin needs MuseScore 3.3 or later")
onAccepted: {
(typeof(quit) === 'undefined' ? Qt.quit : quit)()
}
}
then the title on the plugin in the menu and in the plugin manager becomes "Unsupported MuseScore Version".
Hence the confusion.
The solution is to comment out the title line in that block of code.
// title: qsTr("Unsupported MuseScore Version")
(and also title: "Numeric input error" in the same plugin)
Porting to 4.4 will not be as easy as it was from 3x to 4x.