Recommended QT version(s) for Musescore 2/3 plugins
Hello,
I am taking an Udemy course on QT quick and QML so I can learn how to write plugins for Musescore 2 and 3. What version of QT should I install (e.g., 5.11 or 5.12) from http://download.qt.io/official_releases/qt/
Thanks,
Sam
Comments
The QT Quick imported in the notenames.qml for Musescore 3 is 2.0? But the current version is already up to 2.5? Why does Musescore 3 use such an outdated QT Quick version, or was the plugin not completely updated to the current QT used by Musescore 3?
In reply to The QT Quick imported in the… by Sambaji
Plugins were intentionally left broke (and IMHO should have been hidden) with the expectation they would be fixed in the first couple of months after initial release of 3.0.
In reply to Plugins were intentionally… by mike320
Do you know what version of QT Quick will be available for Musescore 3 plugins?
In reply to Do you know what version of… by Sambaji
My best guess is that no one knows yet. If someone is actively working on this issue they may know the answer and respond here.
In reply to My best guess is that no one… by mike320
Basically, the one supplied by the distribution.
Currently, the lowest common denominator is Qt 5.8 (for MuseScore 3) and Qt 5.4 (for MuseScore 2) and whatever QtQuick came with that. I’d suggest sticking to that baseline because otherwise, some of your plugins won’t work for some users.
In reply to Basically, the one supplied… by mirabilos
5.9, not 5.8. The latter might work, but the former is an LTS release, so should be used, if not 5.12 (also LTS)
In reply to 5.9, not 5.8. The latter… by Jojo-Schmitz
Thanks everyone for weighing in.
Do you think by the time the plugin capacity has been re-enabled in Musescore 3 (in a month or so), that the Windows version of Musescore will be updated to QT 5.12 LTS? Interestingly, Linux and Mac versions already are (https://musescore.org/en/handbook/developers-handbook/references/versio…). Since I suspect that Musescore 3 plugins will not be backwards compatible anyway, I would like to use the newest version of QT Quick as possible.
In reply to Thanks everyone for weighing… by Sambaji
For macOS 10.10 & 10.11 it would be Qt 5.9, if and when 5.9.8 comes out.
For Windows we will go to 5.12 as soon as AppVeyor supports it, I believe the unsupported 32bit version is already.
Assuming Qt 5.9 should be a save bet.
Can you think of any advantages 5.12 brings for plugins?
In reply to For macOS 10.10 & 10.11 it… by Jojo-Schmitz
Since I am a novice, newer just seems cooler--perhaps enhanced JavaScript features?
Since 5.9, handling of JS calls has been optimized for qml, bringing large improvements especially when calling small functions, and the qml JavaScript engine now supports ECMAScript 7. I suspect these improvements have only a minor impact in developing Musescore plugins. I believe that QT 5.9 already supports ECMAScript 6, and 7 was only a minor upgrade.
I'll learn on QT 5.12 and switch to 5.9 when I develop plugins for Musescore 3, which could be awhile. Thanks for the input.
In reply to Thanks everyone for weighing… by Sambaji
No, this is wrong. On GNU/Linux, MuseScore uses whatever the surrounding distribution offers (except containerised formats like AppImage which ship Qt embedded in the container, including all of its security holes).
That is 5.8 (not 5.9 as Jojo-Schmitz said), which is the declared minimum in the
CMakeLists.txt
file.I’m the Debian packager (and taking care of *buntu as well), we have there:
So, for Debian and most common derivatives, Qt 5.9 is likely to stay the minimum you want to support for the next five to seven years or so. Other distributions may have other requirements. The Qt version is not generally changed over the lifetime of a distribution (we made an incredibly fragile hack by backporting xenial’s Qt to trusty and precise), and from what I see, multimedia distribution users are not likely to upgrade to the latest release (Debian) or LTS (*buntu) quickly (I know I’ll probably get quite some flak for not providing MuseScore 3 to xenial, but that just won’t work, and backporting Qt has too many implications).
A short survey of multimedia derivatives: AV Linux 2018.6 has Qt 5.7 (so no plugins), Apodio 11 has Qt 5.5 (so no MuseScore 3), I can’t figure out what io and iro have, and KXStudio is “currently based on Ubuntu 14.04.5 LTS”.
In reply to No, this is wrong. On GNU… by mirabilos
Qt 5.8 technically is the minimum version (if not disabling plugins and some other features), 5.9 politically is the minimum, being LTS.
In reply to No, this is wrong. On GNU… by mirabilos
Good to know about the various Linux-GNU versions. It's great Mirabilos and others are putting the work into making Musescore available on older Linux-GNU systems. With so many Linux-GNU distros moving to 64bit only, many 32bit computers will have to remain on older OSs, which I will suspect will be increasingly harder to support for future Musescore upgrades. Sticking with an older QT LTS (e.g., 5.9) for the coming years makes sense.
I am working on my first plug-in with Musescore 3. At first I was just coping from other plug-ins all of which uses QtQuick 1. I have then tried bigger and bigger import numbers till it failed. Here is what I settled on.
import MuseScore 3.0
import QtQuick 2.9
import QtQuick.Layouts 1.3
import QtQuick.Controls 1.3
import QtQuick.Dialogs 1.2
In reply to I am working on my first… by joelmoses454@g…
Using wich version of Qt?