From 9b5ae442fe161599570d734743bb8e4636226fb1 Mon Sep 17 00:00:00 2001 From: Brett Parker Date: Thu, 9 Jul 2009 15:09:24 +0100 Subject: [PATCH 1/1] Actually encode to the terminals locale, if we can. --- curses-crossword.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/curses-crossword.py b/curses-crossword.py index 19ee754..6d8791a 100644 --- a/curses-crossword.py +++ b/curses-crossword.py @@ -84,13 +84,13 @@ def parsecrossword(crossworddata): parts = line.split() question_number = int(parts[0]) clue = " ".join(parts[1:]) - crossword["across"][int(question_number)] = clue.encode('utf-8') + crossword["across"][int(question_number)] = clue.encode(code) if indown: if line != "": parts = line.split() question_number = int(parts[0]) clue = " ".join(parts[1:]) - crossword["down"][int(question_number)] = clue.encode('utf-8') + crossword["down"][int(question_number)] = clue.encode(code) num_cols = len(crossword["grid"][0]) num_rows = len(crossword["grid"]) -- 2.39.5