diff --git a/CMakeLists.txt b/CMakeLists.txt --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -60,7 +60,12 @@ qt5_wrap_ui(UI_FILES commandpanel.ui commandwidget.ui ) -qt5_add_resources(RES_FILES misc/icons.qrc) + +if (WIN32) + qt5_add_resources(RES_FILES misc/icons.qrc misc/winicons.qrc) +else (WIN32) + qt5_add_resources(RES_FILES misc/icons.qrc) +endif (WIN32) add_executable(${PROGRAM_NAME} WIN32 main.cpp diff --git a/commandpanel.cpp b/commandpanel.cpp --- a/commandpanel.cpp +++ b/commandpanel.cpp @@ -32,6 +32,10 @@ CommandPanel::CommandPanel(QSerialPort* ui->setupUi(this); ui->scrollAreaWidgetContents->setLayout(new QVBoxLayout); +#ifdef Q_OS_WIN + ui->pbNew->setIcon(QIcon(":/icons/list-add")); +#endif // Q_OS_WIN + connect(ui->pbNew, &QPushButton::clicked, this, &CommandPanel::newCommand); newCommand(); // add an empty slot by default diff --git a/commandwidget.cpp b/commandwidget.cpp --- a/commandwidget.cpp +++ b/commandwidget.cpp @@ -22,8 +22,8 @@ #include #include - #include +#include CommandWidget::CommandWidget(QWidget *parent) : QWidget(parent), @@ -31,6 +31,10 @@ CommandWidget::CommandWidget(QWidget *pa { ui->setupUi(this); +#ifdef Q_OS_WIN + ui->pbDelete->setIcon(QIcon(":/icons/list-remove")); +#endif // Q_OS_WIN + connect(ui->pbDelete, &QPushButton::clicked, this, &CommandWidget::onDeleteClicked); connect(ui->pbSend, &QPushButton::clicked, this, &CommandWidget::onSendClicked); connect(ui->pbASCII, &QPushButton::toggled, this, &CommandWidget::onASCIIToggled); diff --git a/misc/tango/license_notice b/misc/tango/license_notice new file mode 100644 --- /dev/null +++ b/misc/tango/license_notice @@ -0,0 +1,3 @@ +Icon files in this directory are taken from Tango project +(http://tango.freedesktop.org/). Please see referenced web page for +more information. \ No newline at end of file diff --git a/misc/tango/list-add.png b/misc/tango/list-add.png new file mode 100644 index 0000000000000000000000000000000000000000..2acdd8f514c199a37b7b14f53081467f88ef7bff GIT binary patch literal 601 zc$@)Q0;c_mP)i&hw@usRe0Hlp%^VXF!>2}-I+fVC+BCh2Xu(H}= zWwkR-i17&Q1@?r1slIQmGmt?bz+``iz=_N4nTEMJnWp6PdlDi4$xDysihSSRJ^#HD zfm0WkcL*Ezw|WjD;wX`Y@`OQ$i> zk~|wHA%P^W-+NY=qm+O%@!?CCIP&DpgbAGaz)s%w=F2r6?z` z-r3~+=g{XtaVheZEby-7%X^w2a;hK35HfD6NN^I8P7V;(0mQ@Z@*Wtm@8FfUzLwkFPvfh|u~3@f)V nN>6CzLo>o}j6Z`3{#X10^GpxssPJ~100000NkvXXu0mjfzW5Zm diff --git a/misc/tango/list-remove.png b/misc/tango/list-remove.png new file mode 100644 index 0000000000000000000000000000000000000000..c5524f7284e4ecb40cbee1e3d3a449bd58a0e4a8 GIT binary patch literal 317 zc$@(}0mA-?P)oXoi$Ept^qyG_6h*pUY)JY1xUgL61ap*$YU>o#o9`0ukRmwYg7fy z#q{lyri8qE6g3Y4Q)K4C3`{ULEziwO932j7CF%n2voBs=XUn#u^MV%pm5i9iZx-vp zUj3U@1pr3JL$sKN`)b!NVJ6&T + + tango/list-add.png + tango/list-remove.png + + diff --git a/serialplot.pro b/serialplot.pro --- a/serialplot.pro +++ b/serialplot.pro @@ -81,5 +81,8 @@ INCLUDEPATH += qmake/ CONFIG += c++11 -RESOURCES += \ - misc/icons.qrc +RESOURCES += misc/icons.qrc + +win32 { + RESOURCES += misc/winicons.qrc +}