From 39f07414eecd6a2a20ea92416a78df23b574e325 Mon Sep 17 00:00:00 2001 From: Phil Taylor Date: Fri, 19 Nov 2021 17:52:18 +0000 Subject: [PATCH] Add --version command line argument and WFVIEW_VERSION #define --- aboutbox.cpp | 2 +- main.cpp | 13 +++++++++++-- wfview.pro | 2 ++ 3 files changed, 14 insertions(+), 3 deletions(-) diff --git a/aboutbox.cpp b/aboutbox.cpp index a9222b0..dadd943 100644 --- a/aboutbox.cpp +++ b/aboutbox.cpp @@ -12,7 +12,7 @@ aboutbox::aboutbox(QWidget *parent) : ui->logoBtn->setIcon(QIcon(":resources/wfview.png")); ui->logoBtn->setStyleSheet("Text-align:left"); - ui->topText->setText("wfview version 1.2d"); + ui->topText->setText("wfview version " + QString(WFVIEW_VERSION)); QString head = QString(""); QString copyright = QString("Copyright 2017-2021 Elliott H. Liggett, W6EL. All rights reserved. wfview source code is licensed under the GNU GPLv3."); diff --git a/main.cpp b/main.cpp index f98d414..63ffde4 100644 --- a/main.cpp +++ b/main.cpp @@ -37,7 +37,7 @@ int main(int argc, char *argv[]) QString currentArg; - const QString helpText = QString("\nUsage: -p --port /dev/port, -h --host remotehostname, -c --civ 0xAddr, -l --logfile filename.log, -s --settings filename.ini, -d --debug\n"); // TODO... + const QString helpText = QString("\nUsage: -p --port /dev/port, -h --host remotehostname, -c --civ 0xAddr, -l --logfile filename.log, -s --settings filename.ini, -d --debug, -v --version\n"); // TODO... for(int c=1; c