pyside2____1.安装和案列

安装 pip install pyside2 -i https://pypi.douban.com/simple/

代码main.py

from PySide2.QtWidgets import QApplication, QMainWindow, QPlainTextEdit, QPushButton

app = QApplication()  # 总程序
window = QMainWindow()  # 主窗口对象
window.resize(500, 400)
window.move(300, 310)
window.setWindowTitle("薪资统计")

text = QPlainTextEdit(window)
text.setPlainText("请输入薪资表")
text.move(10, 25)
text.resize(300, 350)

button = QPushButton('统计', window)
button.move(380, 80)

window.show()

app.exec_()  # 循环

运行main.py

pyside2____1.安装和案列_第1张图片

你可能感兴趣的:(pyside2,python,qt5)