2 Feb 2004 04:28
docutils/docutils/writers html4css1.py,1.96,1.97
David Goodger <goodger <at> projects.sourceforge.net>
2004-02-02 03:28:32 GMT
2004-02-02 03:28:32 GMT
Update of /cvsroot/docutils/docutils/docutils/writers
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv10084
Modified Files:
html4css1.py
Log Message:
add "<title />" for untitled docs, for XHTML conformance; thanks to Darek Suchojad
Index: html4css1.py
===================================================================
RCS file: /cvsroot/docutils/docutils/docutils/writers/html4css1.py,v
retrieving revision 1.96
retrieving revision 1.97
diff -u -d -r1.96 -r1.97
--- html4css1.py 12 Jan 2004 16:27:24 -0000 1.96
+++ html4css1.py 2 Feb 2004 03:28:29 -0000 1.97
<at> <at> -547,6 +547,10 <at> <at>
def visit_document(self, node):
self.body.append(self.starttag(node, 'div', CLASS='document'))
+ # empty or untitled document?
+ if not len(node) or not isinstance(node[0], nodes.title):
+ # for XHTML conformance:
+ self.head.insert(0, '<title />\n')
def depart_document(self, node):
self.body.append('</div>\n')
-------------------------------------------------------
The SF.Net email is sponsored by EclipseCon 2004
(Continue reading)
RSS Feed