diff -r 0572a215bd2f -r 5994b80b8760 eric6/QScintilla/MiniEditor.py --- a/eric6/QScintilla/MiniEditor.py Sun Apr 11 16:53:48 2021 +0200 +++ b/eric6/QScintilla/MiniEditor.py Sun Apr 11 18:45:10 2021 +0200 @@ -129,11 +129,13 @@ # See it is text to insert. if len(txt) and txt >= " ": - if self.hasSelectedText(): - if txt in MiniScintilla.EncloseChars: - encloseSelectedText(MiniScintilla.EncloseChars[txt]) - ev.accept() - return + if ( + self.hasSelectedText() and + txt in MiniScintilla.EncloseChars + ): + encloseSelectedText(MiniScintilla.EncloseChars[txt]) + ev.accept() + return super().keyPressEvent(ev) else: