PyQt窗口阴影
两种方式
- 贴图片
- 代码画
贴图
这个写的挺好
PyQt制造窗口阴影,想说爱你不容易
代码画
话不多说, 直接贴代码
from PyQt5.QtGui import QFont, QPainterPath, QPainter, QColor, QBrush, QPen
# 注意不要将窗口背景设置透明
# self.setAttribute(Qt.WA_TranslucentBackground, True)
class MyWindow(object):
def __init__(self):
pass
def paintEvent(self, event)