pyqt lepaskan widget

widget.setParent(None)
Andreas