I have this:
Qt Code:
  1. class MainWidget(QWidget):
  2. def __init__(self):
  3. self.tree = TreeArea(self)
  4. self.display = DisplayArea(self)
  5.  
  6. gridLayout = QGridLayout()
  7. gridLayout.addWidget(self.tree, 0, 0)
  8. gridLayout.addWidget(self.display, 0, 1)
To copy to clipboard, switch view to plain text mode 

where TreeArea is:
Qt Code:
  1. class TreeArea(QTreeWidget):
  2. def __init__(self, parent):
  3. QTreeWidget.__init__(self, parent)
To copy to clipboard, switch view to plain text mode 
and DisplayArea is:
Qt Code:
  1. class DisplayArea(QGraphicsScene):
  2. def __init__(self, parent):
  3. QGraphicsScene.__init__(self, parent)
To copy to clipboard, switch view to plain text mode 
Qt doesn't like it when I do gridLayout.addWidget(self.display, 0, 1) since self.display does not inherit QWidget. So how do I add a QGraphicsScene to a layout?