homepage

This issue tracker has been migrated to GitHub , and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author rhettinger
Recipients rhettinger
Date 2015年04月02日.07:01:49
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1427958110.33.0.788273316254.issue23847@psf.upfronthosting.co.za>
In-reply-to
Content
The xml.dom.minidom package has as a xml.toprettyxml() function that has the problem of altering the whitespace of the text of elements. The ElementTree module needs a prettify option that works better, perhaps something based of Effbot's code at:
http://effbot.org/zone/element-lib.htm#prettyprint
The lxml package also provides an API for this purpose:
 print(etree.tostring(root, pretty_print=True))
History
Date User Action Args
2015年04月02日 07:01:50rhettingersetrecipients: + rhettinger
2015年04月02日 07:01:50rhettingersetmessageid: <1427958110.33.0.788273316254.issue23847@psf.upfronthosting.co.za>
2015年04月02日 07:01:50rhettingerlinkissue23847 messages
2015年04月02日 07:01:49rhettingercreate

AltStyle によって変換されたページ (->オリジナル) /