From 72cdb702966c12857619397460bad3a9cf97d03a Mon Sep 17 00:00:00 2001 From: "Andrew M. Kuchling" Date: Fri, 29 Aug 2003 18:40:03 +0000 Subject: [Bug #790356] unctrl() doesn't work for full printable charset. Fix by Dave Cinege. --- Lib/curses/ascii.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Lib/curses/ascii.py b/Lib/curses/ascii.py index b8ae6f3..08b5b79 100644 --- a/Lib/curses/ascii.py +++ b/Lib/curses/ascii.py @@ -87,6 +87,8 @@ def alt(c): return _ctoi(c) | 0x80 def unctrl(c): + if isprint(c): + return chr(_ctoi(c)) bits = _ctoi(c) if bits == 0x7f: rep = "^?" -- cgit v0.12