With some help flupke on, #qtI came up with:
for i in range(0, child_layout.count()):
child_layout.itemAt(i).widget().hide()
parent_layout.removeItem(child_layout)
It is assumed that all child layouts are widgets. Is there a simpler solution?
source
share