pyside2____1.安装和案列

news/2025/2/27 7:11:57

安装 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

在这里插入图片描述


http://www.niftyadmin.cn/n/4611438.html

相关文章

Could not autowire.No beans of ‘userMapper‘ type found.

这里并没有错误,但是IDEA报红 package com.example.demo.mapper;import org.junit.runner.RunWith; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.boot.test.context.SpringBootTest; import org.springframework.t…

腾讯iphone面试题(转)

1Objective-C内部的实现2CALayer和View的关系3 http协议,tcp/ip4 UITableView的那些元素是可以自定义的?5 c语言的,定义变量,比如int,在什么情况下,其最大值是不同的6 比较32位平台和64位平台不…

spring boot jwt完整过程

首先源码https://gitee.com/mobile191llx/spring-boot-jwt.git 接着项目目录结构 项目开始 1.新建项目名称为demo、选择maven什么都不要勾选 2.依赖pom.xml <?xml version"1.0" encoding"UTF-8"?> <project xmlns"http://maven.apache…

PGA结构

当客户端向服务器发送连接请求&#xff0c;服务器监听到客户端的请求&#xff0c;在专用服务器模式下&#xff0c;会在服务器端衍生一个server process来代理客户的请求&#xff0c;server process进而向实例发起连接&#xff0c;创建会话&#xff0c;而PGA就为server process所…

【干货】大数据在工业4.0演进中的价值

演讲实录&#xff1a; 今天非常高兴跟大家来分享工业4.0研究院对工业大数据的认识。具体来讲&#xff0c;我们将讨论工业4.0演进过程中&#xff0c;大数据将呈现什么价值&#xff0c;我们将从商业模式的设计来认识工业大数据的潜力。 在正式开始前&#xff0c;我先解释一下工业…

jQuery 树型菜单插件(Treeview)

jQuery Treeview 提供了一个无序灵活的可折叠的树形菜单。试用于一些菜单的导航&#xff0c;支持基于 cookie 的持久性菜单转载于:https://www.cnblogs.com/qq3111901846/p/6670036.html

vscode vue格式化不换行

一直以来VS code----vue的代码格式化都差强人意&#xff0c;html会自动展开&#xff0c;真的很难受&#xff0c;类似这样子 <template><div id"energy"><divclass"line-chart-div":style"{width: innerWidth / 4.5 px,height: inner…

安卓全屏-沉浸式

在开发时想要像游戏那样全屏怎么办&#xff1f; 只需要在onCreate方法执行下列代码即可 setContentView(R.layout.activity_main);// 隐藏状态栏和标题this.getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN,WindowManager.LayoutParams.FLAG_FULLSCREEN);//…