diff options
author | Gonzalo Odiard <godiard@gmail.com> | 2012-03-07 16:30:46 (GMT) |
---|---|---|
committer | Gonzalo Odiard <godiard@gmail.com> | 2012-03-07 16:30:46 (GMT) |
commit | 19313bce7e51a0443adc908e706013f9334e7e23 (patch) | |
tree | 30fad9085ef27962900b048cefe3166959ce1e1c /epubadapter.py | |
parent | aaad25feac3830ffee561078daac93fe71e1d998 (diff) |
Fix utf-8 code management in the text to speech in epub backend
Signed-off-by: Gonzalo Odiard <gonzalo@laptop.org>
Diffstat (limited to 'epubadapter.py')
-rw-r--r-- | epubadapter.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/epubadapter.py b/epubadapter.py index 0503311..a5e1ffd 100644 --- a/epubadapter.py +++ b/epubadapter.py @@ -71,7 +71,8 @@ class EpubViewer(epubview.EpubView): if end_range > len(self.word_tuples): end_range = len(self.word_tuples) for word_tuple in self.word_tuples[self.current_word:end_range]: - file_str.write('<mark name="' + str(i) + '"/>' + word_tuple[2]) + file_str.write('<mark name="' + str(i) + '"/>' + \ + word_tuple[2].encode('utf-8')) i = i + 1 self.current_word = i file_str.write('</speak>') |