eric6/Graphics/ClassItem.py

changeset 7254
f00d825fbdb3
parent 7229
53054eb5b15a
child 7360
9190402e4505
equal deleted inserted replaced
7253:50dbe65a1334 7254:f00d825fbdb3
184 @param painter reference to the painter object (QPainter) 184 @param painter reference to the painter object (QPainter)
185 @param option style options (QStyleOptionGraphicsItem) 185 @param option style options (QStyleOptionGraphicsItem)
186 @param widget optional reference to the widget painted on (QWidget) 186 @param widget optional reference to the widget painted on (QWidget)
187 """ 187 """
188 pen = self.pen() 188 pen = self.pen()
189 if (option.state & QStyle.State_Selected) == \ 189 if (
190 QStyle.State(QStyle.State_Selected): 190 (option.state & QStyle.State_Selected) ==
191 QStyle.State(QStyle.State_Selected)
192 ):
191 pen.setWidth(2) 193 pen.setWidth(2)
192 else: 194 else:
193 pen.setWidth(1) 195 pen.setWidth(1)
194 196
195 painter.setPen(pen) 197 painter.setPen(pen)

eric ide

mercurial