diff --git a/ground/openpilotgcs/src/plugins/welcome/qml/main.qml b/ground/openpilotgcs/src/plugins/welcome/qml/main.qml index 7a58a8fa3..ee70c5758 100644 --- a/ground/openpilotgcs/src/plugins/welcome/qml/main.qml +++ b/ground/openpilotgcs/src/plugins/welcome/qml/main.qml @@ -22,6 +22,19 @@ Rectangle { width: scale*sourceSize.width height: scale*sourceSize.height smooth: true + + Text { + id: textOpVersion + x: 258 + y: 668 + color: "#c4c0c0" + text: welcomePlugin.versionString + font.bold: true + styleColor: "#00000000" + anchors.horizontalCenter: parent.horizontalCenter + horizontalAlignment: Text.AlignHCenter + font.pixelSize: 14 + } } diff --git a/ground/openpilotgcs/src/plugins/welcome/welcomemode.h b/ground/openpilotgcs/src/plugins/welcome/welcomemode.h index b6e837cc9..46149486a 100644 --- a/ground/openpilotgcs/src/plugins/welcome/welcomemode.h +++ b/ground/openpilotgcs/src/plugins/welcome/welcomemode.h @@ -29,6 +29,7 @@ #ifndef WELCOMEMODE_H #define WELCOMEMODE_H +#include "version_info/version_info.h" #include "welcome_global.h" #include @@ -44,6 +45,7 @@ struct WelcomeModePrivate; class WELCOME_EXPORT WelcomeMode : public Core::IMode { Q_OBJECT + Q_PROPERTY(QString versionString READ versionString) public: WelcomeMode(); @@ -65,6 +67,10 @@ public: { m_priority = priority; } + QString versionString() const + { + return tr("OpenPilot GCS Version: %1").arg(VersionInfo::revision().left(60)); + } public slots: void openUrl(const QString &url);