feat:煤流检测平台页面搭建

This commit is contained in:
徐超 2024-10-31 17:47:16 +08:00
commit 3a0d6a188e
68 changed files with 3152 additions and 0 deletions

46
HX_CoalFlowDetect.pro Normal file
View File

@ -0,0 +1,46 @@
#-------------------------------------------------
#
# Project created by QtCreator 2024-10-30T15:56:33
#
#-------------------------------------------------
QT += core gui
greaterThan(QT_MAJOR_VERSION, 4): QT += widgets
TARGET = HX_CoalFlowDetect
TEMPLATE = app
# The following define makes your compiler emit warnings if you use
# any feature of Qt which has been marked as deprecated (the exact warnings
# depend on your compiler). Please consult the documentation of the
# deprecated API in order to know how to port your code away from it.
DEFINES += QT_DEPRECATED_WARNINGS
# You can also make your code fail to compile if you use deprecated APIs.
# In order to do so, uncomment the following line.
# You can also select to disable deprecated APIs only up to a certain version of Qt.
#DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0x060000 # disables all the APIs deprecated before Qt 6.0.0
CONFIG += c++11
SOURCES += \
main.cpp \
mainwindow.cpp
HEADERS += \
mainwindow.h
FORMS += \
mainwindow.ui
# Default rules for deployment.
qnx: target.path = /tmp/$${TARGET}/bin
else: unix:!android: target.path = /opt/$${TARGET}/bin
!isEmpty(target.path): INSTALLS += target
RESOURCES += \
resource.qrc
RC_ICONS = logo.ico

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 524 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1016 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 909 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

BIN
Resource/image/bukekong.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 331 B

BIN
Resource/image/close.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

BIN
Resource/image/dianji.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 237 B

BIN
Resource/image/electric.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 198 B

BIN
Resource/image/icon1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

BIN
Resource/image/icon2.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

BIN
Resource/image/icon3.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

BIN
Resource/image/icon4.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

BIN
Resource/image/icon5.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

BIN
Resource/image/icon6.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

BIN
Resource/image/jianxiu.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 215 B

BIN
Resource/image/jikong.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 226 B

BIN
Resource/image/jiudi.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 181 B

BIN
Resource/image/kekong.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 471 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 558 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 201 B

BIN
Resource/image/logo.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 719 B

BIN
Resource/image/max.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 320 B

BIN
Resource/image/maxHover.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 311 B

BIN
Resource/image/maxPress.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 337 B

BIN
Resource/image/min.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 183 B

BIN
Resource/image/minHover.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 182 B

BIN
Resource/image/minPress.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 190 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.5 KiB

BIN
Resource/image/pdj.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

BIN
Resource/image/pdqd.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

BIN
Resource/image/pdsd.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

BIN
Resource/image/shoudong.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 464 B

BIN
Resource/image/speed.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 241 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

BIN
Resource/image/start.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

BIN
Resource/image/stop.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 418 B

BIN
Resource/image/title.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 58 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

BIN
Resource/image/wind.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 194 B

BIN
Resource/image/zidong.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 224 B

BIN
logo.ico Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.2 KiB

11
main.cpp Normal file
View File

@ -0,0 +1,11 @@
#include "mainwindow.h"
#include <QApplication>
int main(int argc, char* argv[])
{
QApplication a(argc, argv);
MainWindow w;
w.showMaximized();
return a.exec();
}

52
mainwindow.cpp Normal file
View File

@ -0,0 +1,52 @@
#include "mainwindow.h"
#include "ui_mainwindow.h"
#include <QDateTime>
#include <QTimer>
MainWindow::MainWindow(QWidget* parent)
: QMainWindow(parent)
, ui(new Ui::MainWindow)
{
ui->setupUi(this);
this->setWindowFlag(Qt::FramelessWindowHint);
this->setWindowFlags(windowFlags() | Qt::WindowMaximizeButtonHint | Qt::WindowMinimizeButtonHint);
calendarLoopPlay();
}
MainWindow::~MainWindow()
{
delete ui;
}
void MainWindow::on_pushButton_close_clicked()
{
this->close();
}
void MainWindow::on_pushButton_max_clicked()
{
if (isFullScreen()) {
this->showMaximized();
} else {
this->showFullScreen();
}
}
void MainWindow::on_pushButton_min_clicked()
{
this->showMinimized();
}
void MainWindow::calendarLoopPlay()
{
ui->label_calendar->clear();
QTimer* timer_calendar = new QTimer(this);
connect(timer_calendar, &QTimer::timeout, this, [this]() {
QDateTime time = QDateTime::currentDateTime();
QString str = time.toString("yyyy-MM-dd hh:mm:ss dddd");
ui->label_calendar->setText(str);
});
timer_calendar->start(1000); //每一秒溢出一次进入槽函数
}

34
mainwindow.h Normal file
View File

@ -0,0 +1,34 @@
#ifndef MAINWINDOW_H
#define MAINWINDOW_H
#include <QMainWindow>
namespace Ui {
class MainWindow;
}
class MainWindow : public QMainWindow {
Q_OBJECT
public:
explicit MainWindow(QWidget* parent = nullptr);
~MainWindow();
private slots:
void on_pushButton_close_clicked();
void on_pushButton_max_clicked();
void on_pushButton_min_clicked();
private:
/**
* @brief calendarLoopPlay
*/
void calendarLoopPlay();
private:
Ui::MainWindow* ui;
};
#endif // MAINWINDOW_H

2947
mainwindow.ui Normal file

File diff suppressed because it is too large Load Diff

62
resource.qrc Normal file
View File

@ -0,0 +1,62 @@
<RCC>
<qresource prefix="/">
<file>Resource/image/background.png</file>
<file>Resource/image/title.png</file>
<file>Resource/image/logo.png</file>
<file>Resource/image/beltOperate.png</file>
<file>Resource/image/speedModel.png</file>
<file>Resource/image/beltCamera_select.png</file>
<file>Resource/image/beltCamera_unselect.png</file>
<file>Resource/image/beltCamerabg.png</file>
<file>Resource/image/beltCameraDemo.png</file>
<file>Resource/image/coalDistributbg.png</file>
<file>Resource/image/coalStatisbg.png</file>
<file>Resource/image/dianji.png</file>
<file>Resource/image/electric.png</file>
<file>Resource/image/icon1.png</file>
<file>Resource/image/icon2.png</file>
<file>Resource/image/icon3.png</file>
<file>Resource/image/icon4.png</file>
<file>Resource/image/icon5.png</file>
<file>Resource/image/icon6.png</file>
<file>Resource/image/jianxiu.png</file>
<file>Resource/image/jikong.png</file>
<file>Resource/image/jiudi.png</file>
<file>Resource/image/labelSelect.png</file>
<file>Resource/image/labelunSelect.png</file>
<file>Resource/image/oneClickStart.png</file>
<file>Resource/image/oneClickStop.png</file>
<file>Resource/image/speed.png</file>
<file>Resource/image/start.png</file>
<file>Resource/image/stop.png</file>
<file>Resource/image/temperature.png</file>
<file>Resource/image/beltCloseState.png</file>
<file>Resource/image/labelhover.png</file>
<file>Resource/image/warningInfobg.png</file>
<file>Resource/image/closePress.png</file>
<file>Resource/image/max.png</file>
<file>Resource/image/min.png</file>
<file>Resource/image/beltInfobg.png</file>
<file>Resource/image/wind.png</file>
<file>Resource/image/beltOffline.png</file>
<file>Resource/image/beltOnline.png</file>
<file>Resource/image/close.png</file>
<file>Resource/image/closeHover.png</file>
<file>Resource/image/maxHover.png</file>
<file>Resource/image/maxPress.png</file>
<file>Resource/image/minHover.png</file>
<file>Resource/image/minPress.png</file>
<file>Resource/image/bukekong.png</file>
<file>Resource/image/kekong.png</file>
<file>Resource/image/shoudong.png</file>
<file>Resource/image/zidong.png</file>
<file>Resource/image/oneClickStartHover.png</file>
<file>Resource/image/oneClickStartPress.png</file>
<file>Resource/image/oneClickStopHover.png</file>
<file>Resource/image/oneClickStopPress.png</file>
<file>Resource/image/startHover.png</file>
<file>Resource/image/startPress.png</file>
<file>Resource/image/stopHover.png</file>
<file>Resource/image/stopPress.png</file>
</qresource>
</RCC>