For PyQt5 (not using PySide)
fillPixmap uses a QRect object as an argument to painter.setClipRegion for the StyledBackground case but it should be a QRegion object (line 392).
if widget.testAttribute(Qt.WA_StyledBackground): painter.setClipRegion(rect)
which can be fixed by importing QRegion from QtGUI and then creating that object inline.
if widget.testAttribute(Qt.WA_StyledBackground): painter.setClipRegion(QRegion(rect))
For PyQt5 (not using PySide) fillPixmap uses a QRect object as an argument to painter.setClipRegion for the StyledBackground case but it should be a QRegion object (line 392).
if widget.testAttribute(Qt.WA_StyledBackground): painter.setClipRegion(rect)
which can be fixed by importing QRegion from QtGUI and then creating that object inline.if widget.testAttribute(Qt.WA_StyledBackground): painter.setClipRegion(QRegion(rect))