def focusOutEvent(self, event): """Override Qt method.""" QWidget.focusOutEvent(self, event) self.setProperty('focused', False)