PyQt5中如何实现指示灯点亮和指示灯熄灭功能

一般上位机界面都会涉及指示灯点亮和指示灯熄灭功能,从网上下载该功能的上位机界面,学习如何使用PyQt5搭建具备指示灯点亮和指示灯熄灭效果的界面。

1. 上位机界面的效果展示

使用PyQt5实现以下界面,界面效果如下,界面图片是从网上搜索得到的:

在这里插入图片描述

使用过PyQt5实际完成效果如下:

(1)界面初始化刚打开时的效果:

在这里插入图片描述

(2)点击“建立连接”按钮,界面效果如下:

在这里插入图片描述

(3)点击“断开连接”按钮,界面上的灯都熄灭了,界面效果如下:

在这里插入图片描述

2. 如何创建指示灯增加亮灯和灭灯效果

第一种方法:通过改变标签控件的背景颜色和形状,创建一个指示灯
参考以下文章的方法:PyQt5入门:利用标签控件创建一个指示灯

第二种方法:在label控件上添加图片表示指示灯点亮和熄灭

阿里巴巴矢量图标库下载指示灯亮灯和灭灯的图片

关键代码:

# 创建一个 QLabel 实例
self.label = QLabel(self)# 设置 QLabel 显示的图片
self.label.setPixmap(QPixmap('path_to_your_image.jpg'))

设置label上显示图片的大小,python示例代码如下:

import sys
from PyQt5.QtWidgets import QApplication, QWidget, QLabel, QVBoxLayout
from PyQt5.QtGui import QPixmap
from PyQt5.QtCore import Qtclass ExampleApp(QWidget):def __init__(self):super().__init__()self.initUI()def initUI(self):# 创建一个QLabel实例label = QLabel(self)# 将图片文件路径设置到QLabel上label.setPixmap(QPixmap('path_to_your_image.jpg'))# 设置图片的大小,可以使用setFixedSize,或者调整QLabel的大小# label.setFixedSize(200, 200)  # 设置图片显示的大小为200x200# 或者使用resize方法来调整QLabel的大小label.resize(200, 200)  # 将QLabel的大小设置为200x200# 设置label的尺寸策略,使得图片能够在QLabel中适当缩放label.setScaledContents(True)# 创建一个垂直布局layout = QVBoxLayout()layout.addWidget(label)# 设置窗口的布局self.setLayout(layout)# 设置窗口的标题self.setWindowTitle('Display Image')# 设置窗口的尺寸self.setGeometry(300, 300, 300, 300)# 显示窗口self.show()if __name__ == '__main__':app = QApplication(sys.argv)ex = ExampleApp()sys.exit(app.exec_())

3. 如何在按钮控件上增加图片和文字

python代码示例如下:


import sys
from PyQt5.QtWidgets import QApplication, QPushButton, QWidget, QVBoxLayout, QMainWindow
from PyQt5.QtGui import QIconclass MainWindow(QMainWindow):def __init__(self):super().__init__()self.setWindowTitle("Button Example")self.button = QPushButton("Click Me")self.button.setIcon(QIcon('your_image.png'))  # 替换为您的图片路径self.button.setIconSize(self.button.iconSize())self.setCentralWidget(self.button)def main():app = QApplication(sys.argv)mainWin = MainWindow()mainWin.show()sys.exit(app.exec_())if __name__ == '__main__':main()

4. 如何在label上显示图片和文字

参考文章链接:qlabel显示背景图片加文字

python代码示例如下:

from PyQt5.QtWidgets import QApplication, QLabel, QVBoxLayout, QWidget
app = QApplication([])
# 创建一个窗口和布局
window = QWidget()
layout = QVBoxLayout(window)
# 创建一个QLabel控件
label = QLabel()
# 设置样式表,包括背景图片和文字样式
label.setStyleSheet('''QLabel {background-image: url("background.jpg");background-repeat: no-repeat;background-position: center;color: white;font-size: 24px;}
''')
# 设置标签的文本内容
label.setText('Hello World!')
# 将标签添加到布局中
layout.addWidget(label)
window.show()
app.exec_()

5. 设置QlineEdit控件大小

查找界面上所有的QlineEdit控件,关键代码如下:

# 找到所有的QLineEdit控件
line_edit_obj = self.findChildren(QLineEdit)
for line_edit in line_edit_obj:line_edit.setFixedSize(100, 40)

使用Qt Designer工具添加QlineEdit控件,sizePolicy的水平策略和垂直策略都设置的“Fixed”固定值,所以设置QlineEdit控件大小使用setFixedSize()函数。

在这里插入图片描述

6. 代码实现

main.py代码如下:

#!/usr/bin/env python
# -*- coding: utf-8 -*-
# @Author : Logintern09import sys
from PyQt5.QtWidgets import QApplication, QMainWindow, QLineEdit, QWidget
from PyQt5.QtGui import QPixmap, QIcon
from led import Ui_MainWindowclass mainWindow(QMainWindow, Ui_MainWindow):def __init__(self):super(mainWindow, self).__init__()self.setupUi(self)  # 初始化窗口# 设置窗口图标self.setWindowIcon(QIcon('./icon/污染检测系统.png'))self.comboBox.setFixedSize(120, 30)self.pushButton.setIcon(QIcon('./icon/开机按钮.png'))  # 替换为您的图片路径self.pushButton.setIconSize(self.pushButton.iconSize())self.pushButton_9.setIcon(QIcon('./icon/关机按钮.png'))  # 替换为您的图片路径self.pushButton_9.setIconSize(self.pushButton_9.iconSize())# 找到所有的QLineEdit控件line_edit_obj = self.findChildren(QLineEdit)for line_edit in line_edit_obj:line_edit.setFixedSize(100, 40)# 设置label的尺寸策略,使得图片能够在QLabel中适当缩放self.label_2.setScaledContents(True)# 设置图片的大小,可以使用setFixedSize,或者使用resize调整QLabel的大小self.label_2.setFixedSize(80, 80)  # 设置图片显示的大小为200x200# 设置 QLabel 显示的图片self.label_2.setPixmap(QPixmap('./icon/灭灯.png'))textlabel_list = self.alarm_light_label()for label in textlabel_list:# 设置label的尺寸策略,使得图片能够在QLabel中适当缩放label.setScaledContents(True)# 设置图片的大小,可以使用setFixedSize,或者使用resize调整QLabel的大小label.setFixedSize(80, 80)  # 设置图片显示的大小为200x200self.close_light()self.pushButton.clicked.connect(self.open_light)  # 按钮1连接到函数 open_light()self.pushButton_9.clicked.connect(self.close_light)  # 按钮2连接到函数 close_light()def alarm_light_label(self):textlabel_list = [self.label_12, self.label_13, self.label_14, self.label_15,self.label_16, self.label_17]return textlabel_listdef open_light(self):self.label_2.setPixmap(QPixmap('./icon/亮灯.png'))textlabel_list = self.alarm_light_label()for label in textlabel_list:label.setPixmap(QPixmap('./icon/亮灯.png'))def close_light(self):self.label_2.setPixmap(QPixmap('./icon/灭灯.png'))textlabel_list = self.alarm_light_label()for label in textlabel_list:label.setPixmap(QPixmap('./icon/灭灯.png'))if __name__ == "__main__":app = QApplication(sys.argv)ui = mainWindow()ui.show()sys.exit(app.exec_())

Qt Designer工具生成的.ui转成的python代码:

# -*- coding: utf-8 -*-# Form implementation generated from reading ui file 'led.ui'
#
# Created by: PyQt5 UI code generator 5.15.4
#
# WARNING: Any manual changes made to this file will be lost when pyuic5 is
# run again.  Do not edit this file unless you know what you are doing.from PyQt5 import QtCore, QtGui, QtWidgetsclass Ui_MainWindow(object):def setupUi(self, MainWindow):MainWindow.setObjectName("MainWindow")MainWindow.resize(1305, 859)self.centralwidget = QtWidgets.QWidget(MainWindow)self.centralwidget.setObjectName("centralwidget")self.gridLayout_2 = QtWidgets.QGridLayout(self.centralwidget)self.gridLayout_2.setObjectName("gridLayout_2")self.frame = QtWidgets.QFrame(self.centralwidget)self.frame.setFocusPolicy(QtCore.Qt.NoFocus)self.frame.setToolTip("")self.frame.setStatusTip("")self.frame.setWhatsThis("")self.frame.setAccessibleName("")self.frame.setAccessibleDescription("")self.frame.setFrameShape(QtWidgets.QFrame.Box)self.frame.setFrameShadow(QtWidgets.QFrame.Sunken)self.frame.setLineWidth(2)self.frame.setObjectName("frame")self.gridLayout_6 = QtWidgets.QGridLayout(self.frame)self.gridLayout_6.setObjectName("gridLayout_6")self.groupBox = QtWidgets.QGroupBox(self.frame)self.groupBox.setObjectName("groupBox")self.gridLayout_4 = QtWidgets.QGridLayout(self.groupBox)self.gridLayout_4.setObjectName("gridLayout_4")self.horizontalLayout = QtWidgets.QHBoxLayout()self.horizontalLayout.setSpacing(200)self.horizontalLayout.setObjectName("horizontalLayout")self.label = QtWidgets.QLabel(self.groupBox)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Preferred)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.label.sizePolicy().hasHeightForWidth())self.label.setSizePolicy(sizePolicy)self.label.setObjectName("label")self.horizontalLayout.addWidget(self.label)self.comboBox = QtWidgets.QComboBox(self.groupBox)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.comboBox.sizePolicy().hasHeightForWidth())self.comboBox.setSizePolicy(sizePolicy)self.comboBox.setObjectName("comboBox")self.comboBox.addItem("")self.comboBox.setItemText(0, "")self.comboBox.addItem("")self.comboBox.addItem("")self.comboBox.addItem("")self.comboBox.addItem("")self.comboBox.addItem("")self.comboBox.addItem("")self.horizontalLayout.addWidget(self.comboBox)self.pushButton = QtWidgets.QPushButton(self.groupBox)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.pushButton.sizePolicy().hasHeightForWidth())self.pushButton.setSizePolicy(sizePolicy)self.pushButton.setObjectName("pushButton")self.horizontalLayout.addWidget(self.pushButton)self.pushButton_9 = QtWidgets.QPushButton(self.groupBox)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.pushButton_9.sizePolicy().hasHeightForWidth())self.pushButton_9.setSizePolicy(sizePolicy)self.pushButton_9.setObjectName("pushButton_9")self.horizontalLayout.addWidget(self.pushButton_9)self.label_2 = QtWidgets.QLabel(self.groupBox)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Preferred)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.label_2.sizePolicy().hasHeightForWidth())self.label_2.setSizePolicy(sizePolicy)self.label_2.setObjectName("label_2")self.horizontalLayout.addWidget(self.label_2)self.gridLayout_4.addLayout(self.horizontalLayout, 0, 0, 1, 1)self.gridLayout_6.addWidget(self.groupBox, 0, 0, 1, 1)self.gridLayout_2.addWidget(self.frame, 0, 0, 1, 1)self.frame_2 = QtWidgets.QFrame(self.centralwidget)self.frame_2.setFrameShape(QtWidgets.QFrame.Box)self.frame_2.setFrameShadow(QtWidgets.QFrame.Sunken)self.frame_2.setLineWidth(2)self.frame_2.setObjectName("frame_2")self.gridLayout_3 = QtWidgets.QGridLayout(self.frame_2)self.gridLayout_3.setObjectName("gridLayout_3")self.groupBox_2 = QtWidgets.QGroupBox(self.frame_2)self.groupBox_2.setObjectName("groupBox_2")self.gridLayout_5 = QtWidgets.QGridLayout(self.groupBox_2)self.gridLayout_5.setObjectName("gridLayout_5")self.gridLayout = QtWidgets.QGridLayout()self.gridLayout.setSizeConstraint(QtWidgets.QLayout.SetNoConstraint)self.gridLayout.setHorizontalSpacing(100)self.gridLayout.setVerticalSpacing(30)self.gridLayout.setObjectName("gridLayout")self.label_9 = QtWidgets.QLabel(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Preferred)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.label_9.sizePolicy().hasHeightForWidth())self.label_9.setSizePolicy(sizePolicy)self.label_9.setAlignment(QtCore.Qt.AlignCenter)self.label_9.setObjectName("label_9")self.gridLayout.addWidget(self.label_9, 2, 0, 1, 1)self.lineEdit_8 = QtWidgets.QLineEdit(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.lineEdit_8.sizePolicy().hasHeightForWidth())self.lineEdit_8.setSizePolicy(sizePolicy)self.lineEdit_8.setObjectName("lineEdit_8")self.gridLayout.addWidget(self.lineEdit_8, 1, 3, 1, 1)self.lineEdit_4 = QtWidgets.QLineEdit(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.lineEdit_4.sizePolicy().hasHeightForWidth())self.lineEdit_4.setSizePolicy(sizePolicy)self.lineEdit_4.setObjectName("lineEdit_4")self.gridLayout.addWidget(self.lineEdit_4, 2, 1, 1, 1)self.lineEdit_20 = QtWidgets.QLineEdit(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.lineEdit_20.sizePolicy().hasHeightForWidth())self.lineEdit_20.setSizePolicy(sizePolicy)self.lineEdit_20.setObjectName("lineEdit_20")self.gridLayout.addWidget(self.lineEdit_20, 6, 4, 1, 1)self.label_15 = QtWidgets.QLabel(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Preferred)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.label_15.sizePolicy().hasHeightForWidth())self.label_15.setSizePolicy(sizePolicy)self.label_15.setObjectName("label_15")self.gridLayout.addWidget(self.label_15, 4, 2, 1, 1)self.lineEdit_18 = QtWidgets.QLineEdit(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.lineEdit_18.sizePolicy().hasHeightForWidth())self.lineEdit_18.setSizePolicy(sizePolicy)self.lineEdit_18.setObjectName("lineEdit_18")self.gridLayout.addWidget(self.lineEdit_18, 4, 4, 1, 1)self.label_14 = QtWidgets.QLabel(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Preferred)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.label_14.sizePolicy().hasHeightForWidth())self.label_14.setSizePolicy(sizePolicy)self.label_14.setObjectName("label_14")self.gridLayout.addWidget(self.label_14, 3, 2, 1, 1)self.label_4 = QtWidgets.QLabel(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Preferred)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.label_4.sizePolicy().hasHeightForWidth())self.label_4.setSizePolicy(sizePolicy)self.label_4.setAlignment(QtCore.Qt.AlignCenter)self.label_4.setObjectName("label_4")self.gridLayout.addWidget(self.label_4, 0, 0, 1, 1)self.label_7 = QtWidgets.QLabel(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Preferred)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.label_7.sizePolicy().hasHeightForWidth())self.label_7.setSizePolicy(sizePolicy)self.label_7.setAlignment(QtCore.Qt.AlignCenter)self.label_7.setObjectName("label_7")self.gridLayout.addWidget(self.label_7, 5, 0, 1, 1)self.lineEdit_12 = QtWidgets.QLineEdit(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.lineEdit_12.sizePolicy().hasHeightForWidth())self.lineEdit_12.setSizePolicy(sizePolicy)self.lineEdit_12.setObjectName("lineEdit_12")self.gridLayout.addWidget(self.lineEdit_12, 5, 3, 1, 1)self.label_11 = QtWidgets.QLabel(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Preferred)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.label_11.sizePolicy().hasHeightForWidth())self.label_11.setSizePolicy(sizePolicy)self.label_11.setAlignment(QtCore.Qt.AlignCenter)self.label_11.setObjectName("label_11")self.gridLayout.addWidget(self.label_11, 0, 2, 1, 1)self.lineEdit_2 = QtWidgets.QLineEdit(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.lineEdit_2.sizePolicy().hasHeightForWidth())self.lineEdit_2.setSizePolicy(sizePolicy)self.lineEdit_2.setObjectName("lineEdit_2")self.gridLayout.addWidget(self.lineEdit_2, 3, 1, 1, 1)self.label_10 = QtWidgets.QLabel(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Preferred)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.label_10.sizePolicy().hasHeightForWidth())self.label_10.setSizePolicy(sizePolicy)self.label_10.setAlignment(QtCore.Qt.AlignCenter)self.label_10.setObjectName("label_10")self.gridLayout.addWidget(self.label_10, 0, 1, 1, 1)self.label_21 = QtWidgets.QLabel(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Preferred)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.label_21.sizePolicy().hasHeightForWidth())self.label_21.setSizePolicy(sizePolicy)self.label_21.setAlignment(QtCore.Qt.AlignCenter)self.label_21.setObjectName("label_21")self.gridLayout.addWidget(self.label_21, 0, 5, 1, 1)self.lineEdit_15 = QtWidgets.QLineEdit(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.lineEdit_15.sizePolicy().hasHeightForWidth())self.lineEdit_15.setSizePolicy(sizePolicy)self.lineEdit_15.setObjectName("lineEdit_15")self.gridLayout.addWidget(self.lineEdit_15, 1, 4, 1, 1)self.label_6 = QtWidgets.QLabel(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Preferred)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.label_6.sizePolicy().hasHeightForWidth())self.label_6.setSizePolicy(sizePolicy)self.label_6.setAlignment(QtCore.Qt.AlignCenter)self.label_6.setObjectName("label_6")self.gridLayout.addWidget(self.label_6, 4, 0, 1, 1)self.lineEdit_17 = QtWidgets.QLineEdit(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.lineEdit_17.sizePolicy().hasHeightForWidth())self.lineEdit_17.setSizePolicy(sizePolicy)self.lineEdit_17.setObjectName("lineEdit_17")self.gridLayout.addWidget(self.lineEdit_17, 3, 4, 1, 1)self.lineEdit_19 = QtWidgets.QLineEdit(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.lineEdit_19.sizePolicy().hasHeightForWidth())self.lineEdit_19.setSizePolicy(sizePolicy)self.lineEdit_19.setObjectName("lineEdit_19")self.gridLayout.addWidget(self.lineEdit_19, 5, 4, 1, 1)self.label_20 = QtWidgets.QLabel(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Preferred)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.label_20.sizePolicy().hasHeightForWidth())self.label_20.setSizePolicy(sizePolicy)self.label_20.setAlignment(QtCore.Qt.AlignCenter)self.label_20.setObjectName("label_20")self.gridLayout.addWidget(self.label_20, 0, 4, 1, 1)self.label_12 = QtWidgets.QLabel(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Preferred)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.label_12.sizePolicy().hasHeightForWidth())self.label_12.setSizePolicy(sizePolicy)self.label_12.setAlignment(QtCore.Qt.AlignCenter)self.label_12.setObjectName("label_12")self.gridLayout.addWidget(self.label_12, 1, 2, 1, 1)self.lineEdit_6 = QtWidgets.QLineEdit(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.lineEdit_6.sizePolicy().hasHeightForWidth())self.lineEdit_6.setSizePolicy(sizePolicy)self.lineEdit_6.setObjectName("lineEdit_6")self.gridLayout.addWidget(self.lineEdit_6, 6, 1, 1, 1)self.lineEdit_11 = QtWidgets.QLineEdit(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.lineEdit_11.sizePolicy().hasHeightForWidth())self.lineEdit_11.setSizePolicy(sizePolicy)self.lineEdit_11.setObjectName("lineEdit_11")self.gridLayout.addWidget(self.lineEdit_11, 4, 3, 1, 1)self.pushButton_6 = QtWidgets.QPushButton(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.pushButton_6.sizePolicy().hasHeightForWidth())self.pushButton_6.setSizePolicy(sizePolicy)self.pushButton_6.setObjectName("pushButton_6")self.gridLayout.addWidget(self.pushButton_6, 4, 5, 1, 1)self.label_16 = QtWidgets.QLabel(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Preferred)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.label_16.sizePolicy().hasHeightForWidth())self.label_16.setSizePolicy(sizePolicy)self.label_16.setObjectName("label_16")self.gridLayout.addWidget(self.label_16, 5, 2, 1, 1)self.pushButton_4 = QtWidgets.QPushButton(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.pushButton_4.sizePolicy().hasHeightForWidth())self.pushButton_4.setSizePolicy(sizePolicy)self.pushButton_4.setObjectName("pushButton_4")self.gridLayout.addWidget(self.pushButton_4, 2, 5, 1, 1)self.pushButton_5 = QtWidgets.QPushButton(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.pushButton_5.sizePolicy().hasHeightForWidth())self.pushButton_5.setSizePolicy(sizePolicy)self.pushButton_5.setObjectName("pushButton_5")self.gridLayout.addWidget(self.pushButton_5, 3, 5, 1, 1)self.lineEdit_13 = QtWidgets.QLineEdit(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.lineEdit_13.sizePolicy().hasHeightForWidth())self.lineEdit_13.setSizePolicy(sizePolicy)self.lineEdit_13.setObjectName("lineEdit_13")self.gridLayout.addWidget(self.lineEdit_13, 6, 3, 1, 1)self.lineEdit_16 = QtWidgets.QLineEdit(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.lineEdit_16.sizePolicy().hasHeightForWidth())self.lineEdit_16.setSizePolicy(sizePolicy)self.lineEdit_16.setObjectName("lineEdit_16")self.gridLayout.addWidget(self.lineEdit_16, 2, 4, 1, 1)self.lineEdit_3 = QtWidgets.QLineEdit(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.lineEdit_3.sizePolicy().hasHeightForWidth())self.lineEdit_3.setSizePolicy(sizePolicy)self.lineEdit_3.setObjectName("lineEdit_3")self.gridLayout.addWidget(self.lineEdit_3, 4, 1, 1, 1)self.label_5 = QtWidgets.QLabel(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Preferred)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.label_5.sizePolicy().hasHeightForWidth())self.label_5.setSizePolicy(sizePolicy)self.label_5.setAlignment(QtCore.Qt.AlignCenter)self.label_5.setObjectName("label_5")self.gridLayout.addWidget(self.label_5, 3, 0, 1, 1)self.lineEdit_5 = QtWidgets.QLineEdit(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.lineEdit_5.sizePolicy().hasHeightForWidth())self.lineEdit_5.setSizePolicy(sizePolicy)self.lineEdit_5.setObjectName("lineEdit_5")self.gridLayout.addWidget(self.lineEdit_5, 5, 1, 1, 1)self.pushButton_3 = QtWidgets.QPushButton(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.pushButton_3.sizePolicy().hasHeightForWidth())self.pushButton_3.setSizePolicy(sizePolicy)self.pushButton_3.setObjectName("pushButton_3")self.gridLayout.addWidget(self.pushButton_3, 1, 5, 1, 1)self.pushButton_7 = QtWidgets.QPushButton(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.pushButton_7.sizePolicy().hasHeightForWidth())self.pushButton_7.setSizePolicy(sizePolicy)self.pushButton_7.setObjectName("pushButton_7")self.gridLayout.addWidget(self.pushButton_7, 5, 5, 1, 1)self.label_13 = QtWidgets.QLabel(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Preferred)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.label_13.sizePolicy().hasHeightForWidth())self.label_13.setSizePolicy(sizePolicy)self.label_13.setObjectName("label_13")self.gridLayout.addWidget(self.label_13, 2, 2, 1, 1)self.label_17 = QtWidgets.QLabel(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Preferred)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.label_17.sizePolicy().hasHeightForWidth())self.label_17.setSizePolicy(sizePolicy)self.label_17.setObjectName("label_17")self.gridLayout.addWidget(self.label_17, 6, 2, 1, 1)self.pushButton_8 = QtWidgets.QPushButton(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.pushButton_8.sizePolicy().hasHeightForWidth())self.pushButton_8.setSizePolicy(sizePolicy)self.pushButton_8.setObjectName("pushButton_8")self.gridLayout.addWidget(self.pushButton_8, 6, 5, 1, 1)self.label_19 = QtWidgets.QLabel(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Preferred)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.label_19.sizePolicy().hasHeightForWidth())self.label_19.setSizePolicy(sizePolicy)self.label_19.setAlignment(QtCore.Qt.AlignCenter)self.label_19.setObjectName("label_19")self.gridLayout.addWidget(self.label_19, 0, 3, 1, 1)self.lineEdit = QtWidgets.QLineEdit(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.lineEdit.sizePolicy().hasHeightForWidth())self.lineEdit.setSizePolicy(sizePolicy)self.lineEdit.setAlignment(QtCore.Qt.AlignCenter)self.lineEdit.setObjectName("lineEdit")self.gridLayout.addWidget(self.lineEdit, 1, 1, 1, 1)self.lineEdit_10 = QtWidgets.QLineEdit(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.lineEdit_10.sizePolicy().hasHeightForWidth())self.lineEdit_10.setSizePolicy(sizePolicy)self.lineEdit_10.setObjectName("lineEdit_10")self.gridLayout.addWidget(self.lineEdit_10, 3, 3, 1, 1)self.label_8 = QtWidgets.QLabel(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Preferred)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.label_8.sizePolicy().hasHeightForWidth())self.label_8.setSizePolicy(sizePolicy)self.label_8.setAlignment(QtCore.Qt.AlignCenter)self.label_8.setObjectName("label_8")self.gridLayout.addWidget(self.label_8, 6, 0, 1, 1)self.lineEdit_9 = QtWidgets.QLineEdit(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.lineEdit_9.sizePolicy().hasHeightForWidth())self.lineEdit_9.setSizePolicy(sizePolicy)self.lineEdit_9.setObjectName("lineEdit_9")self.gridLayout.addWidget(self.lineEdit_9, 2, 3, 1, 1)self.label_3 = QtWidgets.QLabel(self.groupBox_2)sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Preferred)sizePolicy.setHorizontalStretch(0)sizePolicy.setVerticalStretch(0)sizePolicy.setHeightForWidth(self.label_3.sizePolicy().hasHeightForWidth())self.label_3.setSizePolicy(sizePolicy)self.label_3.setAlignment(QtCore.Qt.AlignCenter)self.label_3.setObjectName("label_3")self.gridLayout.addWidget(self.label_3, 1, 0, 1, 1)self.gridLayout_5.addLayout(self.gridLayout, 0, 0, 1, 1)self.gridLayout_3.addWidget(self.groupBox_2, 0, 0, 1, 1)self.gridLayout_2.addWidget(self.frame_2, 1, 0, 1, 1)MainWindow.setCentralWidget(self.centralwidget)self.statusbar = QtWidgets.QStatusBar(MainWindow)self.statusbar.setObjectName("statusbar")MainWindow.setStatusBar(self.statusbar)self.retranslateUi(MainWindow)QtCore.QMetaObject.connectSlotsByName(MainWindow)def retranslateUi(self, MainWindow):_translate = QtCore.QCoreApplication.translateMainWindow.setWindowTitle(_translate("MainWindow", "室内空气质量检测系统"))self.groupBox.setTitle(_translate("MainWindow", "通讯参数"))self.label.setText(_translate("MainWindow", "通讯端口:"))self.comboBox.setItemText(1, _translate("MainWindow", "100"))self.comboBox.setItemText(2, _translate("MainWindow", "101"))self.comboBox.setItemText(3, _translate("MainWindow", "102"))self.comboBox.setItemText(4, _translate("MainWindow", "103"))self.comboBox.setItemText(5, _translate("MainWindow", "104"))self.comboBox.setItemText(6, _translate("MainWindow", "105"))self.pushButton.setText(_translate("MainWindow", "建立连接"))self.pushButton_9.setText(_translate("MainWindow", "断开连接"))self.label_2.setText(_translate("MainWindow", "TextLabel"))self.groupBox_2.setTitle(_translate("MainWindow", "实时监控"))self.label_9.setText(_translate("MainWindow", "   温度:"))self.label_15.setText(_translate("MainWindow", "TextLabel"))self.label_14.setText(_translate("MainWindow", "TextLabel"))self.label_4.setText(_translate("MainWindow", "    监控参数"))self.label_7.setText(_translate("MainWindow", "   CO2:"))self.label_11.setText(_translate("MainWindow", "报警"))self.label_10.setText(_translate("MainWindow", "实际值"))self.label_21.setText(_translate("MainWindow", "操作"))self.label_6.setText(_translate("MainWindow", "     PM2.5:"))self.label_20.setText(_translate("MainWindow", "设定值"))self.label_12.setText(_translate("MainWindow", "TextLabel"))self.pushButton_6.setText(_translate("MainWindow", "设置"))self.label_16.setText(_translate("MainWindow", "TextLabel"))self.pushButton_4.setText(_translate("MainWindow", "设置"))self.pushButton_5.setText(_translate("MainWindow", "设置"))self.label_5.setText(_translate("MainWindow", "   湿度:"))self.pushButton_3.setText(_translate("MainWindow", "设置"))self.pushButton_7.setText(_translate("MainWindow", "设置"))self.label_13.setText(_translate("MainWindow", "TextLabel"))self.label_17.setText(_translate("MainWindow", "TextLabel"))self.pushButton_8.setText(_translate("MainWindow", "设置"))self.label_19.setText(_translate("MainWindow", "设定反馈"))self.label_8.setText(_translate("MainWindow", "  CO:"))self.label_3.setText(_translate("MainWindow", "     烟雾:"))

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.mzph.cn/pingmian/41802.shtml

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈email:809451989@qq.com,一经查实,立即删除!

相关文章

基于SpringBoot的招聘信息管理系统的详细设计和实现(源码+lw+部署文档+讲解等,欢迎咨询我!!)

文章目录 目录 文章目录 详细视频展示: 系统具体实现效果(看看我的实力) 技术栈(详细的描述提供给同学思路参考) 2.1 Java语言介绍 2.2 B/S架构 2.3 MySQL 数据库介绍 2.4 MySQL环境配置 2.5 SpringBoot框…

C++之static关键字

文章目录 前提正文多重定义extern关键字使用staticstatic 全局变量(在.cpp文件中定义)static变量存放在哪里static变量可不可以放在.h文件中 static 函数static局部变量static 成员变量static 成员函数 总结参考链接 前提 好吧,八股,我又回来了。这次想…

[图解]企业应用架构模式2024新译本讲解23-标识映射2

1 00:00:00,950 --> 00:00:02,890 好,我们往下走 2 00:00:04,140 --> 00:00:04,650 一样的 3 00:00:04,660 --> 00:00:07,170 这前面也见过了,定义一个对象数组 4 00:00:07,870 --> 00:00:12,820 数组的长度就是字段的数量,4个…

一.1.(3)半导体二极管基本电路的分析方法及常见应用电路

1.二极管基本电路的分析方法 先标正负极,再看是否理想二极管 将二极管视为断路,求两端电压 两端电压均大于导通电压,压差大的先导通(由于电源不是完全的阶跃,而是有一个电压爬升的过程) 2.常见应用电路 1.求…

日期选取限制日期范围antdesign vue

限制选取的日期范围 效果图 <a-date-pickerv-model"dateTime"format"YYYY-MM-DD":disabled-date"disabledDate"valueFormat"YYYY-MM-DD"placeholder"请选择日期"allowClear />methods:{//回放日期选取范围限制&…

网安小贴士(4)哈希函数

一、前言 哈希函数是密码学中的基础工具&#xff0c;哈希函数在密码学中扮演着至关重要的角色&#xff0c;广泛应用于确保数据的安全性和完整性。随着技术的发展&#xff0c;新的哈希算法和应用场景也在不断出现。 二、定义 哈希函数是一种数学函数&#xff0c;它接受一个输…

Intellj idea无法启动

个人电脑上安装的是2024.01版本的intellj idea作为开发工具&#xff0c;引入了javaagent作为工具包 但是在一次invaliad cache操作后&#xff0c;intellj idea就无法启动了&#xff0c;双击无响应。 重装了idea后也无效&#xff08;这个是有原因的&#xff0c;下面会讲&#…

springboot服务启动读取不到application.yml中的nacos.config信息

我的版本&#xff1a; 可以添加bootstrap.yml文件&#xff0c;在里面添加nacos.config的配置信息 也可以添加VM参数 -Dspring.cloud.nacos.discovery.server-addr -Dspring.cloud.nacos.config.server-addr -Dspring.cloud.nacos.config.namespace -Dspring.cloud.nacos.discov…

代码随想录——划分字母区间(Leetcode763)

题目链接 贪心 class Solution {public List<Integer> partitionLabels(String s) {int[] count new int[27];Arrays.fill(count,0);// 统计元素最后一次出现的位置for(int i 0; i < s.length(); i){count[s.charAt(i) - a] i;}List<Integer> res new Ar…

【基于R语言群体遗传学】-4-统计建模与算法(statistical tests and algorithm)

之前的三篇博客&#xff0c;我们对于哈代温伯格遗传比例有了一个全面的认识&#xff0c;没有看的朋友可以先看一下前面的博客&#xff1a; 群体遗传学_tRNA做科研的博客-CSDN博客 1.一些新名词 &#xff08;1&#xff09;Algorithm: A series of operations executed in a s…

【MySQL】锁(黑马课程)

【MySQL】锁 0. 锁的考察点1. 概述1. 锁的分类1.1 属性分类1.2 粒度分类 2. 全局锁2.1 全局锁操作2.2.1 备份问题 3. 表级锁3.1 附录 0. 锁的考察点 1. 概述 锁是计算机协调多个进程或线程并发访问某一资源的机制。在数据库中&#xff0c;除传统的计算资源(CPU、RAM、I/O)的争…

MatLab三维图形绘制基础

三维图形绘制 三维曲线 plot3 螺旋图绘制 % %三维图像:螺旋图绘制 clear; clc; t [0:0.1:10*pi];% 向量 x sin(t) t.*cos(t);%t是向量&#xff0c;用点乘 y cos(t) - t.*sin(t); z t; plot3(x,y,z); grid on;plot3 绘制同型矩阵 %% % plot3绘制同型矩阵 t [0:0.1:10*…

Python统计实战:时间序列分析之二阶曲线预测和三阶曲线预测

为了解决特定问题而进行的学习是提高效率的最佳途径。这种方法能够使我们专注于最相关的知识和技能&#xff0c;从而更快地掌握解决问题所需的能力。 &#xff08;以下练习题来源于《统计学—基于Python》。请在Q群455547227下载原始数据。&#xff09; 练习题 下表是某只股票…

每周算法:无向图的双连通分量

题目链接 冗余路径, Redundant Paths G 题目描述 为了从 F F F 个草场中的一个走到另一个&#xff0c;奶牛们有时不得不路过一些她们讨厌的可怕的树。 奶牛们已经厌倦了被迫走某一条路&#xff0c;所以她们想建一些新路&#xff0c;使每一对草场之间都会至少有两条相互分离…

vue3 + 百度地图 实现多坐标生成轨迹的两种种方式

本次依然是关于百度地图中常见的一个问题&#xff0c;此次共使用了两种方式并做了一些分析及处理&#xff0c;希望有所帮助。如有问题可以评论或私信。 一、便捷方式 优点&#xff1a;便捷&#xff0c;所用的api方法是根据坐标进行计算后绘制路线&#xff0c;所以路线相对准确…

CentOS修复OpenSSH漏洞升级到openssh 9.7 RPM更新包

在做政府和学校单位网站时&#xff0c;经常需要服务器扫描检测&#xff0c;经常被OpenSSH Server远程代码执行漏洞&#xff08;CVE-2024-6387&#xff09;安全风险通告&#xff0c;出了报告需要升级OpenSSH。 使用yum update openssh是无法更新到最新的&#xff0c;因为系统里的…

VS code修改底部的行号的状态栏颜色

VSCode截图 相信很多小伙伴被底部的蓝色状态栏困扰很久了 处理的方式有两种&#xff1a; 1、隐藏状态栏 2、修改其背景颜色 第一种方法大伙都会&#xff0c;今天就使用第二种方法。 1、点击齿轮进入setting 2、我现在用的新版本&#xff0c;设置不是以前那种json格式展示&…

17-JS封装:工具类方法

目录 一、extend方法 二、添加一些工具类方法&#xff1a;$.xxx() 实现1&#xff1a; 实现2&#xff1a; 一、extend方法 jQuery.fn.extend jQuery.extend function(...args){let target,source[];source[...args];//判断2种情况 //$.extend({}) -->给$添加属性//$.…

计算机提示由于找不到concrt140.dll怎么办,7种解决方法可以对比

在电脑中打开游戏或许软件出现找不到concrt140.dll无法继续执行代码怎么办&#xff1f;concrt140.dll是什么&#xff1f;丢失要怎么解决&#xff1f;下面给大家分析一下concrt140.dll文件是什么与concrt140.dll丢失的多种解决方法&#xff01;相信对你有帮助&#xff01; 一、c…

hdu物联网硬件实验2 GPIO亮灯

学院 班级 学号 姓名 日期 成绩 实验题目 GPIO亮灯 实验目的 点亮三个灯闪烁频率为一秒 硬件原理 无 关键代码及注释 const int ledPin1 GREEN_LED; // the number of the LED pin const int ledPin2 YELLOW_LED; const int ledPin3 RED…