上一页 1 ··· 23 24 25 26 27 28 29 30 31 ··· 52 下一页
摘要: 一、常用API QLineEdit.text():返回输入框的当前文本。 QLineEdit.addAction(Action,QLineEdit.ActionPosition):添加动作到文本输入栏,上面已经举过例子了。 QLineEdit.setAlignment(Qt.Alignment fl 阅读全文
posted @ 2020-05-19 09:20 样子2018 阅读(12915) 评论(0) 推荐(0)
摘要: 一、使用 文档:https://msurguy.github.io/background-blur/ <script src="jquery.min.js"></script> <script src="background-blur.min.js"></script> <div id='some- 阅读全文
posted @ 2020-05-18 09:34 样子2018 阅读(1273) 评论(0) 推荐(0)
摘要: 一、常用API setChecked() 设置复选框的状态,设置为True表示选中,False表示取消选中的复选框setText() 设置复选框的显示文本text() 返回复选框的显示文本isChecked() 检查复选框是否被选中setTriState() 设置复选框为一个三态复选框setChec 阅读全文
posted @ 2020-05-16 14:33 样子2018 阅读(3305) 评论(0) 推荐(0)
摘要: QButtonGroup 继承自 QObject,不是一个可视类,它主要是对按键进行分组,便于按键管理。 一、案例 from PyQt5.Qt import * import sys class Window(QWidget): def __init__(self): super().__init_ 阅读全文
posted @ 2020-05-16 14:13 样子2018 阅读(1675) 评论(0) 推荐(0)
摘要: 一、案例 from PyQt5.Qt import * import sys class Window(QWidget): def __init__(self): super().__init__() self.setWindowTitle('QRadioButton-使用') self.resiz 阅读全文
posted @ 2020-05-15 14:53 样子2018 阅读(2041) 评论(0) 推荐(0)
摘要: 具按钮,一般在工具栏中显示,工具栏中的工具按钮一般只显示图标,供用户快捷的使用一些功能,它继承自QAbstractButton。 一、常用API 1、setToolButtonStyle(Qt.ToolButtonTextBesideIcon):工具按钮样式 Qt.ToolButtonIconOnl 阅读全文
posted @ 2020-05-15 14:44 样子2018 阅读(3092) 评论(0) 推荐(0)
摘要: QCommandLinkButton 继承自 QPushButton ,是Vista 引入的新控件。 一、案例 from PyQt5.Qt import * import sys class Window(QWidget): def __init__(self): super().__init__( 阅读全文
posted @ 2020-05-15 14:04 样子2018 阅读(580) 评论(0) 推荐(0)
摘要: 一、常用API 1、创建按钮控件 QPushButton():创建一个无父控件的按钮控件 QPushButton(parent):创建控件的同时, 设置父控件 QPushButton(text, parent):创建控件的同时, 设置提示文本和父控件 QPushButton(icon, text, 阅读全文
posted @ 2020-05-15 13:54 样子2018 阅读(4322) 评论(1) 推荐(0)
摘要: 一、描述 所有按钮控件的基类,并且提供按钮的通用功能。 二、常用API 1、提示文本 setText(str):设置按钮提示文本 text():获取按钮提示文本 2、图标相关 setIcon(QIcon("resource/h1.png")):设置图标 setIconSize(QSize(w, h) 阅读全文
posted @ 2020-05-15 10:36 样子2018 阅读(1327) 评论(0) 推荐(0)
摘要: 一、常用API 1、大小与位置: x():相对于父控件的位置,顶层控件(没有父控件)则相对于桌面的x位置 y():相对于父控件的y位置,顶层控件(没有父控件)则相对于桌面的y位置 pos():x和y的组合 QPoint(x, y) width():控件的宽度,不包含任何窗口框架 height():控 阅读全文
posted @ 2020-05-15 09:13 样子2018 阅读(3336) 评论(0) 推荐(0)
上一页 1 ··· 23 24 25 26 27 28 29 30 31 ··· 52 下一页