diff options
Diffstat (limited to 'examples/widgets/itemviews/stardelegate/stareditor.py')
-rw-r--r-- | examples/widgets/itemviews/stardelegate/stareditor.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/examples/widgets/itemviews/stardelegate/stareditor.py b/examples/widgets/itemviews/stardelegate/stareditor.py index 8431f4a38..9e3a5f4df 100644 --- a/examples/widgets/itemviews/stardelegate/stareditor.py +++ b/examples/widgets/itemviews/stardelegate/stareditor.py @@ -72,6 +72,8 @@ class StarEditor(QWidget): """ Paint the editor, offloading the work to the StarRating class. """ painter = QPainter(self) self.star_rating.paint(painter, self.rect(), self.palette(), isEditable=True) + # QPainter needs an explicit end() in PyPy. This will become a context manager in 6.3. + painter.end() def mouseMoveEvent(self, event): """ As the mouse moves inside the editor, track the position and |