Fix bug while typing in QLineEdit