181 @param painter reference to the painter object (QPainter) |
181 @param painter reference to the painter object (QPainter) |
182 @param option style options (QStyleOptionGraphicsItem) |
182 @param option style options (QStyleOptionGraphicsItem) |
183 @param widget optional reference to the widget painted on (QWidget) |
183 @param widget optional reference to the widget painted on (QWidget) |
184 """ |
184 """ |
185 pen = self.pen() |
185 pen = self.pen() |
186 if (option.state & QStyle.State_Selected) == QStyle.State(QStyle.State_Selected): |
186 if (option.state & QStyle.State_Selected) == \ |
|
187 QStyle.State(QStyle.State_Selected): |
187 pen.setWidth(2) |
188 pen.setWidth(2) |
188 else: |
189 else: |
189 pen.setWidth(1) |
190 pen.setWidth(1) |
190 |
191 |
191 painter.setPen(pen) |
192 painter.setPen(pen) |
220 def buildItemDataString(self): |
221 def buildItemDataString(self): |
221 """ |
222 """ |
222 Public method to build a string to persist the specific item data. |
223 Public method to build a string to persist the specific item data. |
223 |
224 |
224 This string must start with ", " and should be built like |
225 This string must start with ", " and should be built like |
225 "attribute=value" with pairs separated by ", ". value must not contain ", " |
226 "attribute=value" with pairs separated by ", ". value must not |
226 or newlines. |
227 contain ", " or newlines. |
227 |
228 |
228 @return persistence data (string) |
229 @return persistence data (string) |
229 """ |
230 """ |
230 return "" |
231 return "" |
231 |
232 |