Branch_dyx
duyuxing 1 year ago
parent ff3b50a0d4
commit 4d42577dfd

@ -5,47 +5,66 @@
#-------------------------------------------------
QT += core gui
# 指定项目需要使用的Qt模块这里添加了core核心模块和gui图形用户界面模块
QT += network
# 添加了network模块用于网络功能
CONFIG += c++11
# 配置项目以使用C++11标准
greaterThan(QT_MAJOR_VERSION, 4): QT += widgets
# 如果Qt版本大于4则添加widgets模块这是为了兼容旧版本的Qt
TARGET = Demo2
# 指定项目的输出目标可执行文件名称为Demo2
TEMPLATE = app
# 指定项目的模板类型为应用程序app
# The following define makes your compiler emit warnings if you use
# any feature of Qt which as 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
# 如果使用被标记为弃用deprecated的Qt特性则编译器会发出警告
# 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
# 如果使用了在Qt 6.0.0之前被弃用的API则代码将无法编译这行被注释掉了,需要时可以取消注释
SOURCES += main.cpp\
quiwidget.cpp \
supermarket.cpp
# 指定项目的源文件这里是main.cpp和其他两个.cpp文件
HEADERS += \
quiwidget.h \
head.h \
supermarket.h
# 指定项目的头文件
FORMS += \
supermarket.ui
# 指定项目的UI文件这里是使用Qt Designer设计的界面文件
RESOURCES += \
main.qrc \
qss.qrc \
demo.qrc \
image.qrc
# 指定项目的资源文件,这些文件包含了图标样式表等资源
DISTFILES += \
Demo2.pro.user \
main.ico \
image/Font Awesome Cheatsheet.png
QT += network
# 指定项目分发时需要包含的额外文件
QT += network
# 再次添加network模块可能是为了强调或重复添加
RC_FILE=icon.rc
# 指定Windows资源文件通常用于版本信息和图标等
Loading…
Cancel
Save