# HG changeset patch # User Aurelien Campeas # Date 1271333267 -7200 # Node ID f912e40324c4f5e13ef6e4bc6f85bad6a25558c3 # Parent 92b827b3830efda4c412c076791830883d62bc7d# Parent 32fbb13c06d31b028f7bbea5eb43dc56e735b6b5 merge diff -r 32fbb13c06d3 -r f912e40324c4 devtools/htmlparser.py --- a/devtools/htmlparser.py Thu Apr 15 14:01:29 2010 +0200 +++ b/devtools/htmlparser.py Thu Apr 15 14:07:47 2010 +0200 @@ -74,6 +74,21 @@ Validator.__init__(self) self.parser = etree.XMLParser() +class XMLDemotingValidator(SaxOnlyValidator): + """ some views produce html instead of xhtml, using demote_to_html + + this is typically related to the use of external dependencies + which do not produce valid xhtml (google maps, ...) + """ + + def preprocess_data(self, data): + if data.startswith(' + transform="matrix(1,0,0,1.0373644,0,-72.039777)" + inkscape:export-filename="/home/auc/src/fcw/cubicweb/doc/book/en/images/primaryview_template.png" + inkscape:export-xdpi="60.912449" + inkscape:export-ydpi="60.912449"> + y="86.559296" + inkscape:export-filename="/home/auc/src/fcw/cubicweb/doc/book/en/images/primaryview_template.png" + inkscape:export-xdpi="60.912449" + inkscape:export-ydpi="60.912449" /> + y="172.90417" + inkscape:export-filename="/home/auc/src/fcw/cubicweb/doc/book/en/images/primaryview_template.png" + inkscape:export-xdpi="60.912449" + inkscape:export-ydpi="60.912449" /> + y="391.32156" + inkscape:export-filename="/home/auc/src/fcw/cubicweb/doc/book/en/images/primaryview_template.png" + inkscape:export-xdpi="60.912449" + inkscape:export-ydpi="60.912449" /> + y="84.64225" + inkscape:export-filename="/home/auc/src/fcw/cubicweb/doc/book/en/images/primaryview_template.png" + inkscape:export-xdpi="60.912449" + inkscape:export-ydpi="60.912449" /> render_side_boxes() + y="642.0293" + inkscape:export-filename="/home/auc/src/fcw/cubicweb/doc/book/en/images/primaryview_template.png" + inkscape:export-xdpi="60.912449" + inkscape:export-ydpi="60.912449" /> + y="-31.574066" + inkscape:export-filename="/home/auc/src/fcw/cubicweb/doc/book/en/images/primaryview_template.png" + inkscape:export-xdpi="60.912449" + inkscape:export-ydpi="60.912449" /> + y="19.723684" + inkscape:export-filename="/home/auc/src/fcw/cubicweb/doc/book/en/images/primaryview_template.png" + inkscape:export-xdpi="60.912449" + inkscape:export-ydpi="60.912449" />