summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorFlorent Le Coz <louiz@louiz.org>2011-11-07 19:47:16 +0100
committerFlorent Le Coz <louiz@louiz.org>2011-11-07 19:47:16 +0100
commit17e5411d8f050a3c5e5bcd010551eecac96b5911 (patch)
tree4ad779c5f3f467bea15177559efe920b56851eda /src
parent8911f85a4201b48670022226168b749dfa89fbb8 (diff)
downloadpoezio-17e5411d8f050a3c5e5bcd010551eecac96b5911.tar.gz
poezio-17e5411d8f050a3c5e5bcd010551eecac96b5911.tar.bz2
poezio-17e5411d8f050a3c5e5bcd010551eecac96b5911.tar.xz
poezio-17e5411d8f050a3c5e5bcd010551eecac96b5911.zip
use only full color mode when sending messages. Simple color mode should never
be used in any part of the code except inside the input.
Diffstat (limited to 'src')
-rw-r--r--src/tabs.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/tabs.py b/src/tabs.py
index 7a968740..cae188ae 100644
--- a/src/tabs.py
+++ b/src/tabs.py
@@ -323,7 +323,7 @@ class ChatTab(Tab):
if not self.execute_command(clean_text):
if txt.startswith('//'):
txt = txt[1:]
- self.command_say(txt)
+ self.command_say(xhtml.convert_simple_to_full_colors(txt))
self.cancel_paused_delay()
def send_chat_state(self, state, always_send=False):
@@ -601,7 +601,7 @@ class MucTab(ChatTab):
r = self.core.open_private_window(self.name, user.nick)
if r and len(args) > 1:
msg = arg[len(nick)+1:]
- self.core.current_tab().command_say(msg)
+ self.core.current_tab().command_say(xhtml.convert_simple_to_full_colors(msg))
if not r:
self.core.information(_("Cannot find user: %s" % nick), 'Error')
@@ -718,7 +718,7 @@ class MucTab(ChatTab):
if line.find('\x19') == -1:
msg['body'] = line
else:
- msg['body'] = xhtml.clean_text_simple(line)
+ msg['body'] = xhtml.clean_text(line)
msg['xhtml_im'] = xhtml.poezio_colors_to_html(line)
if config.get('send_chat_states', 'true') == 'true' and self.remote_wants_chatstates is not False:
msg['chat_state'] = needed
@@ -1211,7 +1211,7 @@ class PrivateTab(ChatTab):
if line.find('\x19') == -1:
msg['body'] = line
else:
- msg['body'] = xhtml.clean_text_simple(line)
+ msg['body'] = xhtml.clean_text(line)
msg['xhtml_im'] = xhtml.poezio_colors_to_html(line)
if config.get('send_chat_states', 'true') == 'true' and self.remote_wants_chatstates is not False:
needed = 'inactive' if self.core.status.show in ('xa', 'away') else 'active'
@@ -1875,7 +1875,7 @@ class ConversationTab(ChatTab):
if line.find('\x19') == -1:
msg['body'] = line
else:
- msg['body'] = xhtml.clean_text_simple(line)
+ msg['body'] = xhtml.clean_text(line)
msg['xhtml_im'] = xhtml.poezio_colors_to_html(line)
if config.get('send_chat_states', 'true') == 'true' and self.remote_wants_chatstates is not False:
needed = 'inactive' if self.core.status.show in ('xa', 'away') else 'active'