def dist(a, b):
    return sum((i-j)**2 for i, j in zip(a, b))
def closeEvent(self, event: QCloseEvent):
        settings.write("{}/geometry".format(self.__class__.__name__), self.saveGeometry())
        super().closeEvent(event)