示例#1
0
 def paint(self, painter, option, widget=None):
     paint_option = option
     paint_option.state &= ~QStyle.State_Selected
     if self.isSelected():
         self.setBrush(self.select_brush)
     elif self.hovering:
         self.setBrush(self.hover_brush)
     else:
         self.setBrush(self.orig_brush)
     QGraphicsRectItem.paint(self, painter, paint_option, widget)
示例#2
0
 def paint(self, painter, option, widget=None):
     paint_option = option
     paint_option.state &= ~QStyle.State_Selected
     QGraphicsRectItem.paint(self, painter, paint_option, widget)
示例#3
0
 def paint(self, painter, option, widget=None):
     paint_option = option
     paint_option.state &= ~QStyle.State_Selected
     QGraphicsRectItem.paint(self, painter, paint_option, widget)