Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
k54kdk
PyQt Fluent Widgets
提交
ccbe53e6
P
PyQt Fluent Widgets
项目概览
k54kdk
/
PyQt Fluent Widgets
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
P
PyQt Fluent Widgets
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
提交
ccbe53e6
编写于
4月 03, 2023
作者:
之一Yo
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
添加多行编辑框
上级
0d738670
变更
8
展开全部
隐藏空白更改
内联
并排
Showing
8 changed file
with
48620 addition
and
48595 deletion
+48620
-48595
qfluentwidgets/__init__.py
qfluentwidgets/__init__.py
+1
-1
qfluentwidgets/_rc/qss/dark/line_edit.qss
qfluentwidgets/_rc/qss/dark/line_edit.qss
+6
-6
qfluentwidgets/_rc/qss/light/line_edit.qss
qfluentwidgets/_rc/qss/light/line_edit.qss
+9
-6
qfluentwidgets/_rc/resource.py
qfluentwidgets/_rc/resource.py
+48581
-48578
qfluentwidgets/components/widgets/__init__.py
qfluentwidgets/components/widgets/__init__.py
+1
-1
qfluentwidgets/components/widgets/line_edit.py
qfluentwidgets/components/widgets/line_edit.py
+21
-1
qfluentwidgets/components/widgets/menu.py
qfluentwidgets/components/widgets/menu.py
+0
-1
setup.py
setup.py
+1
-1
未找到文件。
qfluentwidgets/__init__.py
浏览文件 @
ccbe53e6
...
...
@@ -12,7 +12,7 @@ Examples are available at https://github.com/zhiyiYo/PyQt-Fluent-Widgets/tree/ma
:license: GPLv3, see LICENSE for more details.
"""
__version__
=
"0.5.
5
"
__version__
=
"0.5.
6
"
from
.components
import
*
from
.common
import
*
...
...
qfluentwidgets/_rc/qss/dark/line_edit.qss
浏览文件 @
ccbe53e6
LineEdit, TextEdit {
LineEdit, TextEdit
, PlainTextEdit
{
background-color: rgb(55, 55, 55);
border: 1px solid rgb(58, 58, 58);
border-bottom: 1px solid rgb(159, 159, 159);
...
...
@@ -10,25 +10,25 @@ LineEdit, TextEdit {
selection-color: black;
}
TextEdit {
TextEdit
, PlainTextEdit
{
padding: 0px 0px 0px 10px;
}
LineEdit:hover, TextEdit:hover {
LineEdit:hover, TextEdit:hover
, PlainTextEdit:hover
{
background-color: rgb(60, 60, 60);
}
LineEdit:!focus, TextEdit:!focus {
LineEdit:!focus, TextEdit:!focus
, PlainTextEdit:!focus
{
background-color: rgb(55, 55, 55);
border-bottom: 1px solid rgb(159, 159, 159);
}
LineEdit:focus, TextEdit:focus {
LineEdit:focus, TextEdit:focus
, PlainTextEdit:focus
{
border-bottom: 1px solid --ThemeColorPrimary;
background-color: rgb(34, 34, 34);
}
LineEdit:disabled, TextEdit:disabled {
LineEdit:disabled, TextEdit:disabled
, PlainTextEdit:disabled
{
color: rgba(255, 255, 255, 150);
background-color: rgb(59, 59, 59);
border: 1px solid rgb(73, 73, 73);
...
...
qfluentwidgets/_rc/qss/light/line_edit.qss
浏览文件 @
ccbe53e6
LineEdit, TextEdit {
LineEdit, TextEdit
, PlainTextEdit
{
color: black;
background-color: white;
border: 1px solid rgba(0, 0, 0, 13);
...
...
@@ -9,27 +9,30 @@ LineEdit, TextEdit {
selection-background-color: --ThemeColorLight1;
}
TextEdit {
TextEdit,
PlainTextEdit {
padding: 0px 0px 0px 10px;
}
LineEdit:hover, TextEdit:hover {
LineEdit:hover, TextEdit:hover
, PlainTextEdit:hover
{
background-color: rgb(252, 252, 252);
border: 1px solid rgba(0, 0, 0, 13);
border-bottom: 1px solid rgba(0, 0, 0, 100);
}
LineEdit:!focus, TextEdit:!focus {
LineEdit:!focus, TextEdit:!focus
, PlainTextEdit:!focus
{
background-color: white;
border-bottom: 1px solid rgba(0, 0, 0, 100);
}
LineEdit:focus, TextEdit:focus {
LineEdit:focus, TextEdit:focus,
PlainTextEdit:focus {
border-bottom: 1px solid --ThemeColorPrimary;
background-color: white;
}
LineEdit:disabled, TextEdit:disabled {
LineEdit:disabled, TextEdit:disabled,
PlainTextEdit:disabled {
color: rgba(0, 0, 0, 150);
background-color: rgb(252, 252, 252);
border: 1px solid rgb(237, 237, 237);
...
...
qfluentwidgets/_rc/resource.py
浏览文件 @
ccbe53e6
此差异已折叠。
点击以展开。
qfluentwidgets/components/widgets/__init__.py
浏览文件 @
ccbe53e6
from
.button
import
PrimaryPushButton
,
PushButton
,
RadioButton
,
HyperlinkButton
,
ToolButton
from
.check_box
import
CheckBox
from
.combo_box
import
ComboBox
from
.line_edit
import
LineEdit
,
TextEdit
from
.line_edit
import
LineEdit
,
TextEdit
,
PlainTextEdit
from
.icon_widget
import
IconWidget
from
.label
import
PixmapLabel
from
.menu
import
DWMMenu
,
LineEditMenu
,
RoundMenu
...
...
qfluentwidgets/components/widgets/line_edit.py
浏览文件 @
ccbe53e6
# coding: utf-8
from
PyQt5.QtCore
import
QSize
,
Qt
,
QRectF
,
QEvent
from
PyQt5.QtGui
import
QPainter
,
QPainterPath
from
PyQt5.QtWidgets
import
QLineEdit
,
QToolButton
,
QTextEdit
from
PyQt5.QtWidgets
import
QLineEdit
,
QToolButton
,
QTextEdit
,
QPlainTextEdit
from
...common.style_sheet
import
setStyleSheet
,
themeColor
from
...common.icon
import
writeSvg
,
isDarkTheme
,
drawSvgIcon
...
...
@@ -118,3 +118,23 @@ class TextEdit(QTextEdit):
else
:
self
.
horizonSmoothScroll
.
wheelEvent
(
e
)
class
PlainTextEdit
(
QPlainTextEdit
):
""" Plain text edit """
def
__init__
(
self
,
parent
=
None
):
super
().
__init__
(
parent
=
parent
)
self
.
verticalSmoothScroll
=
SmoothScroll
(
self
,
Qt
.
Vertical
)
self
.
horizonSmoothScroll
=
SmoothScroll
(
self
,
Qt
.
Horizontal
)
setStyleSheet
(
self
,
'line_edit'
)
def
contextMenuEvent
(
self
,
e
):
menu
=
TextEditMenu
(
self
)
menu
.
exec_
(
e
.
globalPos
())
def
wheelEvent
(
self
,
e
):
if
e
.
modifiers
()
==
Qt
.
NoModifier
:
self
.
verticalSmoothScroll
.
wheelEvent
(
e
)
else
:
self
.
horizonSmoothScroll
.
wheelEvent
(
e
)
qfluentwidgets/components/widgets/menu.py
浏览文件 @
ccbe53e6
...
...
@@ -721,7 +721,6 @@ class TextEditMenu(EditMenu):
def
_parentSelectedText
(
self
):
return
self
.
parent
().
textCursor
().
selectedText
()
def
_onItemClicked
(
self
,
item
):
if
self
.
selectionStart
>=
0
:
cursor
=
self
.
parent
().
textCursor
()
...
...
setup.py
浏览文件 @
ccbe53e6
...
...
@@ -6,7 +6,7 @@ with open('README.md', encoding='utf-8') as f:
setuptools
.
setup
(
name
=
"PyQt-Fluent-Widgets"
,
version
=
"0.5.
5
"
,
version
=
"0.5.
6
"
,
keywords
=
"pyqt fluent widgets"
,
author
=
"zhiyiYo"
,
author_email
=
"shokokawaii@outlook.com"
,
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录