summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authormathieui <mathieui@mathieui.net>2013-03-13 22:49:19 +0100
committermathieui <mathieui@mathieui.net>2013-03-13 22:49:19 +0100
commit57ce4b6fdf3d5e9ac76d41f96286ebd47119232b (patch)
tree0ef5b3128ad420f69e5accadc821a5203f5c0260 /src
parentd797b1fd65ba73c48e1933cc8042db0cc548094a (diff)
downloadpoezio-57ce4b6fdf3d5e9ac76d41f96286ebd47119232b.tar.gz
poezio-57ce4b6fdf3d5e9ac76d41f96286ebd47119232b.tar.bz2
poezio-57ce4b6fdf3d5e9ac76d41f96286ebd47119232b.tar.xz
poezio-57ce4b6fdf3d5e9ac76d41f96286ebd47119232b.zip
Fix #2265
also: - fix Message.__str__/repr - fix a traceback with user gaming
Diffstat (limited to 'src')
-rw-r--r--src/text_buffer.py4
-rw-r--r--src/windows.py6
2 files changed, 5 insertions, 5 deletions
diff --git a/src/text_buffer.py b/src/text_buffer.py
index 0b9fc319..3f24760d 100644
--- a/src/text_buffer.py
+++ b/src/text_buffer.py
@@ -33,9 +33,9 @@ def other_elems(self):
def repr_message(self):
init = other_elems(self)
- acc = []
+ acc = [init]
next = self.old_message
- rev = 0
+ rev = 1
while next:
acc.append(other_elems(next))
next = next.old_message
diff --git a/src/windows.py b/src/windows.py
index 0916cadb..7480a5dc 100644
--- a/src/windows.py
+++ b/src/windows.py
@@ -982,7 +982,7 @@ class TextWin(Win):
def write_line_separator(self, y):
char = get_theme().CHAR_NEW_TEXT_SEPARATOR
self.addnstr(y, 0,
- char*(self.width//len(char)),
+ char*((self.width//len(char) - 1)),
self.width,
to_curses_attr(get_theme().COLOR_NEW_TEXT_SEPARATOR))
@@ -2036,7 +2036,7 @@ class ContactInfoWin(Win):
i += 1
if contact.tune:
- self.addstr(i, 0, 'Current Tune: %s' % common.format_tune_string(contact.tune), to_curses_attr(get_theme().COLOR_NORMAL_TEXT))
+ self.addstr(i, 0, 'Tune: %s' % common.format_tune_string(contact.tune), to_curses_attr(get_theme().COLOR_NORMAL_TEXT))
self.finish_line()
i += 1
@@ -2051,7 +2051,7 @@ class ContactInfoWin(Win):
i += 1
if contact.gaming:
- self.addstr(i, 0, 'Game: %s on %s' % (contact.gaming['name'], contact.gamin['server_address']), to_curses_attr(get_theme().COLOR_NORMAL_TEXT))
+ self.addstr(i, 0, 'Game: %s' % common.format_gaming_string(contact.gaming), to_curses_attr(get_theme().COLOR_NORMAL_TEXT))
self.finish_line()
i += 1