diff --git a/qtconsole/history_console_widget.py b/qtconsole/history_console_widget.py index 12125f8d..15d5caca 100644 --- a/qtconsole/history_console_widget.py +++ b/qtconsole/history_console_widget.py @@ -187,7 +187,7 @@ def _show_history_droplist(self): items = self._history items.reverse() if (self._history_prefix): - items = [item for item in items if item.startswith(self._history_prefix)] + items = [item[len(self._history_prefix):] for item in items if item.startswith(self._history_prefix)] cursor = self._get_cursor() pos = len(self._history_prefix)