diff options
author | Fred Drake <fdrake@acm.org> | 1999-01-29 21:35:50 (GMT) |
---|---|---|
committer | Fred Drake <fdrake@acm.org> | 1999-01-29 21:35:50 (GMT) |
commit | 279ca75a5be39678d38bff6e2497b1f185658c0a (patch) | |
tree | b3b0a5342fe3a556f80230769c8edcb160e50e6d /Doc/tools/sgmlconv | |
parent | 3a7ff998aca0301659bb906d3631a4e02326615d (diff) | |
download | cpython-279ca75a5be39678d38bff6e2497b1f185658c0a.zip cpython-279ca75a5be39678d38bff6e2497b1f185658c0a.tar.gz cpython-279ca75a5be39678d38bff6e2497b1f185658c0a.tar.bz2 |
Be a little smarter on some attribute values, making an assumption about
the DTD.
Diffstat (limited to 'Doc/tools/sgmlconv')
-rwxr-xr-x | Doc/tools/sgmlconv/esis2sgml.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/Doc/tools/sgmlconv/esis2sgml.py b/Doc/tools/sgmlconv/esis2sgml.py index c43ddbc..762e5ff 100755 --- a/Doc/tools/sgmlconv/esis2sgml.py +++ b/Doc/tools/sgmlconv/esis2sgml.py @@ -32,7 +32,10 @@ def format_attrs(attrs, xml=0): if name == value and isnmtoken(value): s = "%s %s" % (s, value) elif istoken(value): - s = "%s %s=%s" % (s, name, value) + if value == "no" + name: + s = "%s %s" % (s, value) + else: + s = "%s %s=%s" % (s, name, value) else: s = '%s %s="%s"' % (s, name, escape(value)) return s |