fixed size validation

This commit is contained in:
iLLiCiTiT 2021-09-10 17:24:24 +02:00
parent a928664438
commit 9e34a377db

View file

@ -280,13 +280,13 @@ class NiceCheckbox(QtWidgets.QFrame):
return QtGui.QColor(red, green, blue)
def paintEvent(self, event):
if self.width() < 1 or self.height() < 1:
frame_rect = QtCore.QRect(self.rect())
if frame_rect.width() < 0 or frame_rect.height() < 0:
return
painter = QtGui.QPainter(self)
painter.setRenderHint(QtGui.QPainter.Antialiasing)
frame_rect = QtCore.QRect(self.rect())
# Draw inner background
if self._current_step == self._steps: