# Contributor(s):
# mxey <mxey@ghosthacking.net>
# uzbl_config path now honors XDG_CONFIG_HOME if it exists.
+#
+# Romain Bignon <romain@peerfuse.org>
+# Fix for session restoration code.
# Configuration:
yield i
+def escape(s):
+ '''Replaces html markup in tab titles that screw around with pango.'''
+
+ for (split, glue) in [('&','&'), ('<', '<'), ('>', '>')]:
+ s = s.replace(split, glue)
+ return s
+
+
def gen_endmarker():
'''Generates a random md5 for socket message-termination endmarkers.'''
(tabc, textc) = style
if tab_titles:
- pango += tab_format % (tabc, index, textc, tabtitle)
+ pango += tab_format % (tabc, index, textc,\
+ escape(tabtitle))
else:
pango += tab_format % (tabc, textc, index)
uzbl.new_tab(line, False)
if not len(urls):
- self.new_tab()
+ uzbl.new_tab()
else:
uzbl.new_tab()