From a1cd4fdc2326d4b15266b708b87a6aab9ec172ed Mon Sep 17 00:00:00 2001 From: hut Date: Sun, 21 Mar 2010 04:31:41 +0100 Subject: widgets.console: allow unicode input. (if flushinput == False) --- ranger/gui/widgets/console.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/ranger/gui/widgets/console.py b/ranger/gui/widgets/console.py index feb54a3d..20a75c4e 100644 --- a/ranger/gui/widgets/console.py +++ b/ranger/gui/widgets/console.py @@ -130,9 +130,13 @@ class Console(Widget): def press(self, key): from curses.ascii import ctrl, ESC + keytuple = self.env.keybuffer.tuple_with_numbers() try: - cmd = self.commandlist[self.env.keybuffer.tuple_with_numbers()] + cmd = self.commandlist[keytuple] except KeyError: + # An unclean hack to allow unicode input. + # This whole part should be replaced. + self.type_key(chr(keytuple[0])) self.env.key_clear() return -- cgit 1.4.1-2-gfad0