Commit c47b5842 authored by Fred Drake's avatar Fred Drake

Be more XHTML-friendly.

parent 3f089a78
...@@ -229,9 +229,9 @@ def structure(list): ...@@ -229,9 +229,9 @@ def structure(list):
class Table: class Table:
CELL=' <TD ALIGN=CENTER COLSPAN=%i>%s</TD>\n' CELL=' <td align="center" colspan="%i">%s</td>\n'
ROW=' <TR>\n%s </TR>\n' ROW=' <tr>\n%s </tr>\n'
TABLE='\n<TABLE BORDER=1 CELLPADDING=2>\n%s</TABLE>' TABLE='\n<table border="1" cellpadding="2">\n%s</table>'
def create(self,aPar, def create(self,aPar,
td_reg=re.compile(r'[ \t\n]*\|\|([^\0|]*)') td_reg=re.compile(r'[ \t\n]*\|\|([^\0|]*)')
): ):
...@@ -399,10 +399,10 @@ class HTML(StructuredText): ...@@ -399,10 +399,10 @@ class HTML(StructuredText):
if tagged: if tagged:
r='' r=''
else: else:
r='<PRE>\n' r='<pre>\n'
for s in structure: for s in structure:
r="%s%s\n\n%s" % (r,html_quote(s[0]),self.pre(s[1],1)) r="%s%s\n\n%s" % (r,html_quote(s[0]),self.pre(s[1],1))
if not tagged: r=r+'</PRE>\n' if not tagged: r=r.rstrip()+'\n</pre>\n'
return r return r
def table(self,before,table,after): def table(self,before,table,after):
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment