Skip to content
Snippets Groups Projects
Commit 27f1461a authored by dkirov's avatar dkirov
Browse files

get timeformat in utf-8

parent aba2527b
No related branches found
No related tags found
No related merge requests found
......@@ -28,6 +28,7 @@
import pango
import gobject
import time
import sys
import tooltips
import dialogs
import locale
......@@ -607,8 +608,9 @@ def print_conversation_line(self, text, jid, kind, name, tim,
if day_str:
format += day_str + ' '
format += '%X' + after_str
tim_format = time.strftime(format, tim).decode(
locale.getpreferredencoding())
# format comes as unicode, because of day_str.
# we convert it to the encoding that we want
tim_format = time.strftime(format.encode('utf-8'), tim)
buffer.insert_with_tags_by_name(end_iter, tim_format + ' ',
*other_tags_for_time)
elif gajim.config.get('print_time') == 'sometimes':
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment