Closed 1197730656 closed 8 months ago
改背景色会有点难看,所以我没去加这个功能
将table_view.qss中的
QTableView::item { background: transparent; border: 0px; padding-left: 16px; padding-right: 16px; height: 35px; }
改为
QTableView::item { /background: transparent; / /border: 0px; / padding-left: 16px; padding-right: 16px; height: 35px; } 可以解决这个问题 且不影响原有样式
似乎是 qtablewidgetitem 的样式如果设置 background或者border就无法设置背景色
我取消注释之后好像也没起作用
我取消注释之后好像也没起作用
需要重新将 resource.qrc 转换为 resource.py
编译了,但是也没起作用。可以截个有背景色的效果图吗
哦不对,起作用了
但是这个看起来就很奇葩,因为其他地方都是圆角的,同时左侧有留白
其实不改样式表也行,我只要改下源代码就好
通过更改样式表来设置圆角和背景色,显示的背景色也不是圆角的。
PyQt5 分支已经修复了这个问题
What happened?
可更改单元格的前景色 无法更改背景色
Operation System
win10
Python Version
py3.7
PyQt/PySide Version
PyQt5.15.2
PyQt/PySide-Fluent-Widgets Version
v1.5.0
How to Reproduce?
Minimum code