|
|
@ -29,9 +29,10 @@ import re |
|
|
|
import urllib2 |
|
|
|
import urllib2 |
|
|
|
import webbrowser |
|
|
|
import webbrowser |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
from cgi import escape as html_escape |
|
|
|
|
|
|
|
|
|
|
|
from mitterlib.ui.helpers.image_helpers import find_image |
|
|
|
from mitterlib.ui.helpers.image_helpers import find_image |
|
|
|
from mitterlib import htmlize |
|
|
|
from mitterlib import htmlize |
|
|
|
|
|
|
|
|
|
|
|
from mitterlib.constants import gpl_3, version |
|
|
|
from mitterlib.constants import gpl_3, version |
|
|
|
from mitterlib.ui.helpers import timesince |
|
|
|
from mitterlib.ui.helpers import timesince |
|
|
|
|
|
|
|
|
|
|
@ -578,9 +579,7 @@ class Interface(object): |
|
|
|
time = timesince.timesince(data.message_time) |
|
|
|
time = timesince.timesince(data.message_time) |
|
|
|
|
|
|
|
|
|
|
|
# unescape escaped entities that pango is not okay with |
|
|
|
# unescape escaped entities that pango is not okay with |
|
|
|
message = re.sub(r'&', r'&', message) |
|
|
|
message = html_escape(message) |
|
|
|
message = re.sub(r'<', r'<', message) |
|
|
|
|
|
|
|
message = re.sub(r'>', r'>', message) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# highlight URLs |
|
|
|
# highlight URLs |
|
|
|
mask = r'<span foreground="%s">\1</span>' % ( |
|
|
|
mask = r'<span foreground="%s">\1</span>' % ( |
|
|
|