##// END OF EJS Templates
Work around Qt bug where input method is disabled sometimes in QPlainTextEdit....
epatters -
Show More
@@ -849,6 +849,7 b' class ConsoleWidget(Configurable, QtGui.QWidget):'
849 layout.documentSizeChanged.connect(self._adjust_scrollbars)
849 layout.documentSizeChanged.connect(self._adjust_scrollbars)
850
850
851 # Configure the control.
851 # Configure the control.
852 control.setAttribute(QtCore.Qt.WA_InputMethodEnabled, True)
852 control.setContextMenuPolicy(QtCore.Qt.CustomContextMenu)
853 control.setContextMenuPolicy(QtCore.Qt.CustomContextMenu)
853 control.setReadOnly(True)
854 control.setReadOnly(True)
854 control.setUndoRedoEnabled(False)
855 control.setUndoRedoEnabled(False)
@@ -1557,7 +1558,11 b' class ConsoleWidget(Configurable, QtGui.QWidget):'
1557 self._control.document().setMaximumBlockCount(0)
1558 self._control.document().setMaximumBlockCount(0)
1558 self._control.setUndoRedoEnabled(True)
1559 self._control.setUndoRedoEnabled(True)
1559
1560
1561 # Work around bug in QPlainTextEdit: input method is not re-enabled
1562 # when read-only is disabled.
1560 self._control.setReadOnly(False)
1563 self._control.setReadOnly(False)
1564 self._control.setAttribute(QtCore.Qt.WA_InputMethodEnabled, True)
1565
1561 self._control.moveCursor(QtGui.QTextCursor.End)
1566 self._control.moveCursor(QtGui.QTextCursor.End)
1562 self._executing = False
1567 self._executing = False
1563 self._prompt_started_hook()
1568 self._prompt_started_hook()
General Comments 0
You need to be logged in to leave comments. Login now