Show More
@@ -106,7 +106,7 b' class AnsiCodeProcessor(object):' | |||
|
106 | 106 | self.actions = [] |
|
107 | 107 | start = match.end() |
|
108 | 108 | |
|
109 |
groups = |
|
|
109 | groups = [g for g in match.groups() if (g is not None)] | |
|
110 | 110 | g0 = groups[0] |
|
111 | 111 | if g0 == '\a': |
|
112 | 112 | self.actions.append(BeepAction('beep')) |
@@ -129,7 +129,7 b' class AnsiCodeProcessor(object):' | |||
|
129 | 129 | if g0.startswith('['): |
|
130 | 130 | # Case 1: CSI code. |
|
131 | 131 | try: |
|
132 | params = map(int, params) | |
|
132 | params = list(map(int, params)) | |
|
133 | 133 | except ValueError: |
|
134 | 134 | # Silently discard badly formed codes. |
|
135 | 135 | pass |
@@ -21,7 +21,6 b' from IPython.config.configurable import LoggingConfigurable' | |||
|
21 | 21 | from IPython.core.inputsplitter import ESC_SEQUENCES |
|
22 | 22 | from IPython.qt.rich_text import HtmlExporter |
|
23 | 23 | from IPython.qt.util import MetaQObjectHasTraits, get_font |
|
24 | from IPython.utils.py3compat import with_metaclass | |
|
25 | 24 | from IPython.utils.text import columnize |
|
26 | 25 | from IPython.utils.traitlets import Bool, Enum, Integer, Unicode |
|
27 | 26 | from .ansi_code_processor import QtAnsiCodeProcessor |
@@ -70,7 +69,7 b' def is_letter_or_number(char):' | |||
|
70 | 69 | # Classes |
|
71 | 70 | #----------------------------------------------------------------------------- |
|
72 | 71 | |
|
73 |
class ConsoleWidget( |
|
|
72 | class ConsoleWidget(MetaQObjectHasTraits('NewBase', (LoggingConfigurable, QtGui.QWidget), {})): | |
|
74 | 73 | """ An abstract base class for console-type widgets. This class has |
|
75 | 74 | functionality for: |
|
76 | 75 | |
@@ -221,9 +220,9 b" class ConsoleWidget(with_metaclass(MetaQObjectHasTraits, type('NewBase', (Loggin" | |||
|
221 | 220 | |
|
222 | 221 | # The shortcuts defined by this widget. We need to keep track of these to |
|
223 | 222 | # support 'override_shortcuts' above. |
|
224 |
_shortcuts = set(_ctrl_down_remap.keys() |
|
|
225 |
|
|
|
226 |
QtCore.Qt.Key_V |
|
|
223 | _shortcuts = set(_ctrl_down_remap.keys()) | \ | |
|
224 | { QtCore.Qt.Key_C, QtCore.Qt.Key_G, QtCore.Qt.Key_O, | |
|
225 | QtCore.Qt.Key_V } | |
|
227 | 226 | |
|
228 | 227 | _temp_buffer_filled = False |
|
229 | 228 |
General Comments 0
You need to be logged in to leave comments.
Login now