code: def parent_widget(self):
          
          parent = self.parent()
          if parent is not None and isinstance(parent, QtGraphicsItem):
              return parent.widget
docs: Reimplemented to only return GraphicsItems